Graal Forums  

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

Reply
 
Thread Tools Search this Thread Display Modes
  #16  
Old 07-23-2010, 06:02 PM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
freezeplayer(1);
__________________
Quote:
Reply With Quote
  #17  
Old 07-23-2010, 06:52 PM
xMane xMane is offline
NPC-Server (Server)
xMane's Avatar
Join Date: May 2010
Posts: 59
xMane is on a distinguished road
oh ok. also i wantd to make a script that only people in serveroptions stafflist can summon. wat would be the string for that?
if(player.communityname in "?")
Reply With Quote
  #18  
Old 07-23-2010, 07:12 PM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
You can access the flags/variables in server options on the serverside with the serveroptions. variable prefix.

PHP Code:
temp.staffaccounts serveroptions.staff.tokenize(",");
if (
player.account in temp.staffaccounts) {
  echo(
player.account SPC "is staff!");

I've had issues with just using (player.account in serveroptions.staff) before so that's why I use the tokenize to split it up based on commas.

I personally just have a check in the onActionPlayerOnline, and set client.isStaff true of false depending on the outcome.
__________________
Quote:
Reply With Quote
  #19  
Old 07-23-2010, 11:19 PM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
You should really be doing random checks and tile checks serverside, anyone with Cheat Engine and a little know-how could get past those.
__________________
Reply With Quote
  #20  
Old 07-23-2010, 11:33 PM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
Quote:
Originally Posted by cbk1994 View Post
You should really be doing random checks and tile checks serverside, anyone with Cheat Engine and a little know-how could get past those.
The whole script is just setup to spam triggers anyway, there should be checks on both.
__________________
Quote:
Reply With Quote
  #21  
Old 07-23-2010, 11:53 PM
xXziroXx xXziroXx is offline
Master of Puppets
xXziroXx's Avatar
Join Date: May 2004
Location: Sweden
Posts: 5,288
xXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant future
Send a message via AIM to xXziroXx Send a message via MSN to xXziroXx
Quote:
Originally Posted by fowlplay4 View Post
Well that's some fail triggering right there, why are you doing things that should be done on the clientside on the serverside?
I'd say it's equally fail to check everything on clientside.
__________________

"A delayed game is eventually good, but a rushed game is forever bad." - Shigeru Miyamoto
Reply With Quote
  #22  
Old 07-23-2010, 11:57 PM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
Quote:
Originally Posted by xXziroXx View Post
I'd say it's equally fail to check everything on clientside.
Why, I don't see why the server should be bothered with a trigger and a tile check if it doesn't need to be, I admit the random check isn't a good idea though but..

This script is garbage anyway, the treasure found should be dealt by the 'hole' class npc when it's created as well as a bunch of things a lot of us would see fit in the script as well.
__________________
Quote:

Last edited by fowlplay4; 07-24-2010 at 12:07 AM..
Reply With Quote
  #23  
Old 07-24-2010, 02:52 AM
xMane xMane is offline
NPC-Server (Server)
xMane's Avatar
Join Date: May 2010
Posts: 59
xMane is on a distinguished road
xD you guys are meanies. cant you see im a nooblet at scripting?
also um that serveroptions check doesnt work.
Reply With Quote
  #24  
Old 07-24-2010, 03:49 AM
xXziroXx xXziroXx is offline
Master of Puppets
xXziroXx's Avatar
Join Date: May 2004
Location: Sweden
Posts: 5,288
xXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant future
Send a message via AIM to xXziroXx Send a message via MSN to xXziroXx
Quote:
Originally Posted by fowlplay4 View Post
Why, I don't see why the server should be bothered with a trigger and a tile check if it doesn't need to be, I admit the random check isn't a good idea though but..

This script is garbage anyway, the treasure found should be dealt by the 'hole' class npc when it's created as well as a bunch of things a lot of us would see fit in the script as well.
I just don't like doing anything that can benefit the player clientsided.
__________________

"A delayed game is eventually good, but a rushed game is forever bad." - Shigeru Miyamoto
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 12:11 PM.


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