Waving Flag?


(TFate) #1

I’d like to make a flag with a nice little waving effect… not the kind that you can capture, just a flag for eye candy. How do you get the waving effect in Radiant?


(MadMaximus) #2

hmmmmzz… i did get the flag to work before with a test map… but it’s on a differet drive thats not installed… you could do it with a props_decoration, key/values would be

model2 models/mapobjects/flag/flag_fg.md3
spawnflags 100 ( animate, looping and starton set )
loop 1
frames 190
angle ( pick one like setting a model direction, try 190 )
noise ( the sound u want to use, it will loop also )

the flag sound in sound/world is nice, has that clinking sound in it besides the flapping sound, but there is another in there
i didnt try… er… flap.wav i think, so you would set the sound for the flag as,

noise sound/world/flag.wav

but there is a way to do it without the props decoration of course, using the misc_gamemodel with similar key/values set, thats how i did it before.


(HairyPlums) #3

I’m pretty sure you could do it with a deformVertexes shader script…


(TFate) #4

Oops, didn’t realize there were flags in misc_gamemodel… thanks!


(MadMaximus) #5

Yeah, the flag model used in railgun is there in your models/mapobjects/flag folder. when i did it before using the misc_gamemodel, i think i had to define the skin also… but im not to shure about that, i seem to remember geting the ‘shader not found’ on the flag ingame.

i was checking my def file and that props_decoration was not in there, turns out it was in a seperate def file called p_diddy.def, i dunno how i got it, but when i map at night, i usually have a few rye and cokes, and just download stuff at random, so im guessing i got it that way. :smiley:

the waving flag in railgun was made using that props_decoration, if you don’t have it in your def file you can just cut and paste this into a txt file and save to your scripts folder as decoration.def or whatever.

/*QUAKED props_decoration (.6 .7 .7) (-8 -8 0) (8 8 16) STARTINVIS DEBRIS ANIMATE KEEPBLOCK TOUCHACTIVATE LOOPING STARTON
-------- KEYS --------
"model2" will specify the model to load
"noise"  the looping sound entity is to make
"type" type of debris ("glass", "wood", "metal", "rubble") default is "wood"
"count" how much debris ei. default 4 pieces
you will need to specify the bounding box for the entity
"high"  default is 4
"wide"	default is 4
"frames"	how many frames of animation to play
"loop" when the animation is done start again on this frame
"startonframe" on what frame do you want to start the animation
-------- SPAWNFLAGS --------
STARTINVIS
DEBRIS
ANIMATE
KEEPBLOCK
TOUCHACTIVATE
LOOPING
STARTON
*/

and i’d recommend on whatever method you use to make your flag, and you want to add sound, use the ingame speaker editor, as you have more control over the sound effect.