Paused Animated Texture

Discussion in 'Mapping Questions & Discussion' started by VenomAK, Aug 29, 2011.

  1. VenomAK

    VenomAK L1: Registered

    Messages:
    4
    Positive Ratings:
    0
    Hello again, I've recently made an animated texture, and I've got everything working for it. The only problem is I don't want it to automatically play itself, meaning, I only want it to change to a specific frame when I want it to. Is there any VMT handler (I don't know what they're called) to make it NOT automatically play itself?

    This is what my VMT looks like, yes I know the basetexture is wrong, I changed it on purpose.

    Code:
    "LightmappedGeneric"
    {
       "$basetexture" "*TEXTURENAME*"
    	"startframe" "1"
    	"endframe" "2"
    	
       "Proxies"
       {
          "AnimatedTexture"
          {
             "animatedtexturevar" "$basetexture"
             "animatedtextureframenumvar" "$frame"
             "animatedtextureframerate" "1"
          }
       }
    }
    
     
  2. Seba

    aa Seba DR. BIG FUCKER, PHD

    Messages:
    2,363
    Positive Ratings:
    2,365
    I don't think there is; afaik textures can't be controlled from in-game. You can enable/disable func_brushes with two different textures on them though.

    This is where Snark comes in, shits on my post, and says that what I said is wrong and he knows of a better way of doing it.
     
  3. VenomAK

    VenomAK L1: Registered

    Messages:
    4
    Positive Ratings:
    0
    Textures can be controlled in-game with an env_texturetoggle, it only needs an animated texture which is what I have. The only problem is I don't want mine to animate on it's own, I only want it to animate when I use the SetTextureIndex output on it.
     
  4. A Boojum Snark

    aa A Boojum Snark Toraipoddodezain Mazahabado

    Messages:
    4,769
    Positive Ratings:
    5,527
    Don't mind if I do! :O


    Drop the animated texture proxy, that is only for automated animation. Put in a MaterialModify proxy instead (empty, nothing between the brackets).
    Then set up a material_modify_control entity in your map. Set the material to whatever yours is named and set the variable to modify to $frame.
    Then when you want it to change send the MMC a SetMaterialVar input with the frame number you want shown.

    edit: You might be able to get away with env_texturetoggle too, now that I think about it. Just drop the animation proxy, since like I said that is for automation.
     
    • Thanks Thanks x 1
    Last edited: Aug 29, 2011