Blockland Forums > Suggestions & Requests

Event- All players touching

Pages: << < (4/6) > >>

K9 Kid:


--- Quote from: Ducky duck on March 13, 2014, 04:40:12 PM ---Input*

--- End quote ---
Thank you very much, edited OP
everybody feel free to read the OP again to see if theres any other spelling errors
/sarcasm

Ducky duck:


--- Quote from: K9 Kid on March 13, 2014, 05:55:47 PM ---/sarcasm

--- End quote ---


It was just a joke because I always get flamed by people for spelling errors.

K9 Kid:

About the eventing

Is there a variable that can be checked to determine if a player is spectating?
I was talking to a friend of mine who's played blockland for a total of like 3 hours about the events needed to work this brick
He said i should find some way to do

On playerleaveminigame> Vce ifvariable> player is spectator
on false> playing> decriment 1

I'm not aware of any variable specifically for whether or not a player is spectating, but I'm going to try
onplayerleaveminigame> ifvariable player datablock = no-jet player
on true> decriment 1
and
onplayerleaveminigame> ifvariable player health > 1
on true> decriment 1

to see if this will prevent spectating players from subtracting an additional point by disconnecting.

Edit: (upon referring to http://scatteredspace.com/forum/index.php?topic=346.0 to help me event this, I learned that variables arent what I thought. I thought values were things players couldnt change, such as player count and server time, but I learned it included health and points and everything else. forgive me for referring to everything as a variable.)

K9 Kid:

Alright, so I took the time to open a passworded server and try to test out the events.

First of all, where do you get this "on minigame spawn" event? I only have death, join, kill, leave, and reset

Anyway, when I tested the events, the output was only triggered when I did it!
I had
OnMinigameDeath > ifvalue > <var:cl:lastmsg> = Hi
Onactivate > ifvalue > <var:cl:lastmsg> = Hi
Ontrue > set color > green
Onfalse > set color > red
I painted it black again after each test

To test it out, I said HI, clicked it, it turned green. I said No, clicked it, it turned red. worked the same way when i tried it with my alt talking and clicking.
The i joined my server with my alt and joined my own minigame.
the problem is that when my alt said "Hi" and Self Deleted, the brick remained black. when I said "Hi" and Self Deleted, the brick turned green.
painted it black again, said "No" with my alt and Self Deleted, the brick remained black. when I said "No" and Self Deleted, the brick turned red.

Tested it with the first event at onminigamekill, and it only changed color when I killed myself with my alt. not when the alt was killed.
If I changed the target of the first event to "client" and said HI and Self Deleted, it'd turn red. when i clicked the brick, it'd turn green. odd. (still didnt change when alt Self Deleted)
Changing the target to "minigame" produced the same result as "client"

Made another brick with onminigamedeath>client>centerprint>"toast"
When i Self Deleted, I saw "toast"
when my alt Self Deleted, there was no text.
Changed it to onminigamedeath>self>setcolor>blue
when i Self Deleted, it turned blue.
when my alt Self Deleted, it stayed black.
-an interesting note is that when the brick was onminigamedeath, it did not change when i was killed by my alt, nor when I killed my alt.
When I was killed by a zombie, the brick turned blue, and when my alt was killed by a zombie, the brick did not change color.

Conclusion: we can throw the idea of using player's deaths to lower the variables out the window.

yankee903:

Function gameconnection::onClientEnterGame(%client)
{
   $aliveplayerlist[%client.bl_id] = true;
   Parent::onClientEnterGame(%client);
}
Function gameconnection::onDeath(%client);
{
    $aliveplayerlist[%client.bl_id] = false;
    Parent::onDeath(%client);
}

Function gameconnection::spawnPlayer(%client);
{
    $aliveplayerlist[%client.bl_id] = true;
    Parent::spawnPlayer(%client);
}


General idea type up on my iPod :/ alot of errors in this, but it's the basic idea of how to start this idea of using only live and in mini people, I could make this Tom probably

Pages: << < (4/6) > >>

Go to full version