So i finally figure how to trigger serverside! Its opened a lot more options to me with GS2. Anyway, heres what i came up with. Hope you like it. Its only very simple but to me, its a huge step!
PHP Code:
//Scripted by Emera. Chat Customizer!
function ActionServerSide() {
if ( params[0] == "chat" ) {
player.chat(params[1]);
}
}
//#CLIENTSIDE
function onPlayerChats() {
if (player.chat == player.chat) {
player.chat = "Emera: "@player.chat;
}
}
for ( temp.p : allplayers ) {
with (temp.p) {
triggerServer( "gui", this.name, "chat", message );
}
}
It starts of the players chat with the message in the script. You can change it from "Emera: " by typing other messages in. There is no on / off yet because i haven't got to that stuff yet. Thanks guys.