NPC Code:
if (created) {
setimg light2.png;
dontblock;
timeout = 0.1;
}
if (timeout) {
//#CLIENTSIDE
if (startswith(setred,#c)) {
tokenize #c;
if (tokenscount==5 && strequals(#t(0),setred)) {
setplayerprop #c,Red was set to #t(1).;
SetRed();
} elsif (tokenscount!=5) {
say2 Incorrect syntax...;
}
}
timeout=.1;
}
function SetRed() {
setcoloreffect #t(1),#t(2),#t(3),#t(4);
drawaslight;
}