-
Posts
200 -
Joined
-
Last visited
Everything posted by Cassandra
-
I see. Will something like this work? function infectantsSpawnerStart(player) SpawnTime = math.random(5000, 10000) SpawnTimer = setTimer(infectantSpawnTimer, SpawnTime, 0, player) end function infectantSpawnTimer(player) killTimer(SpawnTimer) outputChatBox("An infectant should spawn now", player) if(isElement(player)) then infectantsSpawn(player) SpawnTime = math.random(5000, 10000) SpawnTimer = setTimer(infectantSpawnTimer, SpawnTime, 0, player) end end
-
Sorry for bothering but I've another question. How to change a timer's interval?
-
Thanks, seem to work fine.
-
I tried finding it on the getPedMoveState but it's not there. Can someone point me in the right direction to do so?
-
I did checked the distance. I only need to check the rotation if the ped facing the other ped.
-
Yeah, I thought about that. But, there's no function to complete the logic behind it.
-
I got the seeing part but not the rotation part. For example if the ped crouch sideways but still behind another ped, the ped sees it. Edit: IsElementOnScreen doesn't work for peds only players.
-
How can I make use of isElementInPhotograph to check if the ped is facing and can see the other ped?
-
You can but the rotation has to be accurate in that case it's very unlikely the ped will see the other ped script-wise.
-
How can you tell if a ped is facing another ped and that ped can see the other ped?
-
Don't use normal variables for player variables, use element data with the example I showed you. Another example: setElementData(player, "tempokit2", true) local istrue = getElementData(player, "tempokit2")
-
Fixed. It was a problem with the check.
-
Could be. How can I set a delay inside a timer?
-
Using setElementData and getElementData to get the variable value later on. This is an example. setElementData(playerpointer, "variablename", true/false) local toggle = getElementData(playerpointer, "variablename")
-
Too much variable declaration on a block I would guess. Without the code it would be hard to assume.
-
I got it already, it's fine.
-
Thank you!
-
That will be the same as you have to check the other team members.
-
Hello Guys/Gals, Is there a way to make this function dynamic? By dynamic, I mean that it will automatically get the lowest members a team has and return it without providing the names and members of all the teams. local Clans = { { "Sanity", { 0, 0, 255 }, {150, 250, 14} }, { "Blodz", { 255, 0, 0 }, {50, 300, 15} }, { "Gringo", { 0, 255, 0 }, {350, 10, 16} } } function clanForMember() local clancount = {} clancount[1] = clanCountMembers("Sanity") clancount[2] = clanCountMembers("Blodz") clancount[3] = clanCountMembers("Gringo") if(clancount[1] < clancount[2] and clancount[3]) then return clanGet("Sanity") elseif(clancount[2] < clancount[1] and clancount[3]) then return clanGet("Blodz") elseif(clancount[3] < clancount[1] and clancount[2]) then return clanGet("Gringo") else local clanrnd = math.random(1, 3) return clanGet(Clans[clanrnd][1]) end end
-
I think he mean't the sound when a bullet shell hits the ground.
-
Can you be more specific because I've fixed some syntax highlighting issues in the next release (NOT 0.3.4804). Thanks. Aaaah that might be the problem.
-
I don't think you are really serious at all. Post some more info on what you want from the scripter or what is needed to be done.
-
Syntax highlighting doesn't works for me,
-
There was a suggestion for onServerTick which get's called every frame but sadly it hasn't been implemented yet.