OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: THobson on 19 Aug 2004, 19:54:24

Title: Ground Fog (2)
Post by: THobson on 19 Aug 2004, 19:54:24
Re:
http://www.ofpec.com/yabbse/index.php?board=6;action=display;threadid=19216 (http://www.ofpec.com/yabbse/index.php?board=6;action=display;threadid=19216)

I was really interested in using this, but when I place a Game Logic I get no options for any different types.  The only unit available is â€ËœGame Logic'.  Do I need an add-on?  I have an un-added-on 1.96 installation.
Title: Re:Ground Fog (2)
Post by: Rapter on 19 Aug 2004, 20:03:39
I think it requires the Tonal addon, don't know where it can be downloaded from though
Title: Re:Ground Fog (2)
Post by: THobson on 19 Aug 2004, 22:26:06
Pity.  Thanks
Title: Re:Ground Fog (2)
Post by: m21man on 20 Aug 2004, 01:09:23
Here :) :

Code: [Select]
_object = _this select 0
_amount = _this select 1
_size = _this select 2
_life = _this select 3
_startalt = _this select 4
_velocity = _this select 5
_zvelocity = _this select 6
_mercytimer = _this select 7

#Adv_Params
_delay = 0.01
fogoff = 0

#loop
_count = 0

#Begin
?(fogoff == 1): goto "exit"
_dir = random 360
_vx = _velocity * sin _dir
_vy = _velocity * cos _dir
_sizerand = _size + 1

#Mist
drop ["cl_basic", "", "Billboard", 1, _life, [0,0,_startalt], [_vx,_vy,_zvelocity], 1, 1.275, 1, 0, [_size + _sizerand], [[2,2,2,0.1]], [0], 0, 0, "", "",_object ]

#Counter
_count = _count +1
?(_count == _amount): goto "timer"
~_delay
goto "Begin"

#timer
~_mercytimer
goto "loop"

#Exit
exit

_object : Name of the game logic that the fog originates from
_amount : Amount of particles created per cycle
_size : Size of each particle
_life : Life (Seconds) of each particle
_startalt : Starting height of each particle
_velocity : Horizontal speed of each particle
_zvelocity : Upwards velocity of each particle
_mercytimer : Time between particle creation cycles
Title: Re:Ground Fog (2)
Post by: THobson on 20 Aug 2004, 07:48:06
You wonderful person!  Thank you.  You have quite restored my faith in people.
Title: Re:Ground Fog (2)
Post by: Wadmann on 20 Aug 2004, 18:11:55
@ m21man

Could you give an example of the correct parameters to use your script? Are some of the values whole or fractional values? Are we talking single digits or double digits or even triple digits? I am looking forward to trying this out but I do not want to spend hours getting it to look just right. Thanks!

                                                                   Wadmann
Title: Re:Ground Fog (2)
Post by: m21man on 21 Aug 2004, 01:46:44
Here is a quick test mission to try out in the editor. Just take a look and customize away!