View Full Version : Ganiscript parameters?

02-24-2008, 06:18 PM

how can i read the params passed to a gani with the script inside the gani?
i tried PARAM1, params array, attr array :/

or how can i pass params to a showani gani script?

02-24-2008, 06:39 PM
There are two ways:
- if you use GS1-style (if (playerenters)...) then you can access the parameters at any time by params[]
- if you use GS2 then you get the parameters on the first call to onPlayerEnters(), but you need to check if the parameters actually exist because onPlayerEnters() is also called when you enter other levels:

function onPlayerEnters() {
if (params.size()>0)
echo("first parameter: " @ params[0]);