Blockland Forums > Suggestions & Requests
[EVENT] setEventEnabled but better
SWAT One:
300 total. I have one system with >800 events which ran much like a script might for managing slayer teams, where a team leader could have team membership and manage it accordingly. Granted, a script would be more efficient at doing that, but I know what I know and can event it with much more ease.
Jam_Jar:
--- Quote from: PhantOS on May 19, 2019, 05:06:27 PM ---Right now we got
Ontouch > player > kill
Ontouch > client > centerprint stuff
Ontouch > self > fakekill
And you have to loving enable or deenable each line.
When you could do this
Ontouchtest : ontouch {
Player.kill
Client.centerprint
Self.fakekill
}
--- End quote ---
There is a style of eventing that somewhat accommodates this method. I almost exclusively event in this way for maximum flexibility. You can use VCE's retroCheck as a kind of pointer to trigger specific lines or batches of lines.
To recreate your example:
--- Code: ---0 [x][0] onActivate -> Self -> VCE_retroCheck("ifBrickName", "!=", "TRIGGER", "1 3")
1 [x][0] onVariableTrue -> Player -> Kill
2 [x][0] onVariableTrue -> Client -> CenterPrint("stuff", 3)
3 [x][0] onVariableTrue -> Self -> fakeKillBrick("0 0 0", 5)
--- End code ---
Obviously, your input for line 0 could be anything you wanted or needed it to be. Then it allows you to just disable/enable that 1 specific line, but disable the subsequent lines.
Monoblaster4:
You can use any VCE logic event instead of retrocheck too
--- Code: ---0 [x][0] onActivate -> Self -> VCE_ifValue("functionName", "!=", "", "1 3")
--- End code ---
jes00:
What's the point of the checkbox though? There's no point in having an event line in both fields. If you want it enabled, have it in the first only, if you want it disabled, have it in the second only.
phflack:
having the line in both should be either undefined, or default to the second box, which is disabled
just like current events having an enabling line and then disabling line