PHP Code:
if (created) {
this.events = {"test","race","idle"};
}
if (playerchats && startswith(:select,#c)) {
tokenize #c;
if (lindexof(#t(1),#s(this.events)) == -1) {
setplayerprop #c,Error: Event not found!;
} else {
setplayerprop #c,Event chosen!;
}
}
Possibly replace
lindexof(#t(1),#s(this.events)) with
lindexof(#t(1),this.events).
