Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting > New Scripting Engine (GS2)
FAQ Members List Calendar Today's Posts

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #38  
Old 03-22-2014, 12:55 AM
iDigzy iDigzy is offline
Registered User
Join Date: Apr 2013
Posts: 44
iDigzy is on a distinguished road
I am working on making a custom chat system, and I wanted to have a gui to display previous chat from the player and other players. I managed to get most of it to work, but I am stuck on getting it to send to other players gui and have it display others text. Can someone explain what is wrong and possibly if there is a better way to find the players than by if they are in the same level?

trigger:
PHP Code:
function onPlayerChats() {
 
triggerserver("gui"this.name"sendchat"player.accountplayer.chatplayer.account);

serverside:
PHP Code:
function onActionServerSide() {
  if (
params[0] == "sendchat") {
    for (
pl allplayers) {
      if (
pl.level == findplayer(params[3]).level) {
        
triggerclient("gui"this.name"displaychat"params[1], params[2]);
       }
    }
  }

the clientside that is retrieved if play is in same area:
http://pastebin.com/ts8SGipV (forum kept giving me a denial message, so I posted it there)


entire script if it helps to get an idea of what i'm doing:
http://pastebin.com/Fm0CMqGb
__________________
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 04:45 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.