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
  #1  
Old 07-30-2007, 10:49 PM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
clientr arrays

My post is attached, sorry for the inconvenience, the forums keep giving me errors when I try to post stuff.
Attached Files
File Type: txt post1.txt (1.5 KB, 175 views)
Reply With Quote
  #2  
Old 07-31-2007, 02:15 AM
Horrified Horrified is offline
Rediculously inactive
Join Date: Jul 2007
Posts: 961
Horrified is on a distinguished road
Send a message via ICQ to Horrified Send a message via AIM to Horrified Send a message via MSN to Horrified Send a message via Yahoo to Horrified
player.chat=params is wrong i believe. try params=player.chat
Reply With Quote
  #3  
Old 07-31-2007, 02:27 AM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
That's just a debug line, so I could see what was being passed.
Anyways, I got it fixed, though I think it's a bug. I could not directly edit the clientr.items array, I had to make a temp.array to hold it, then edit it, and plug the info back into the clientr.items.
PHP Code:
  if (params[0]=="addquantity") {
    for (
i=0;i<clientr.items.size();i++) {
      if (
clientr.items[i][0]==params[1]) temp.itemindex=i;
    }
    
temp.items=clientr.items;
    
temp.items[temp.itemindex][1]=params[2];
    
clientr.items=temp.items;
  } 
Reply With Quote
  #4  
Old 07-31-2007, 03:14 AM
killerogue killerogue is offline
Registered Omega
killerogue's Avatar
Join Date: Apr 2006
Location: United States
Posts: 1,920
killerogue is on a distinguished road
Send a message via AIM to killerogue Send a message via MSN to killerogue
Quote:
Originally Posted by Horrified View Post
player.chat=params is wrong i believe. try params=player.chat
I just couldn't believe my eyes.
__________________


REMEMBER, IF YOU REP ME, LEAVE A NAME!

Quote:
Originally Posted by haunter View Post
Graal admins don't die. They go to hell and regroup.
Quote:
Originally Posted by Inverness View Post
Without scripters, your graphics and levels wouldn't do anything but sit there and look pretty.
Reply With Quote
  #5  
Old 07-31-2007, 04:18 AM
Horrified Horrified is offline
Rediculously inactive
Join Date: Jul 2007
Posts: 961
Horrified is on a distinguished road
Send a message via ICQ to Horrified Send a message via AIM to Horrified Send a message via MSN to Horrified Send a message via Yahoo to Horrified
Quote:
Originally Posted by killerogue View Post
I just couldn't believe my eyes.
Can you guys honestly stop being smartasses for 2 seconds to actually explain why it's not/is whatever is wrong? or must you act as if you know what you're doing, even though all of us already know?

And i guess my advice was wrong, then?
Reply With Quote
  #6  
Old 07-31-2007, 04:21 AM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
I explained it already. That line was simply for debugging, I used it to set my player's chat as the parameters being passed so I could know what information was being sent serverside. I don't see how I was anywhere near being a smartass, but meh.
Reply With Quote
  #7  
Old 07-31-2007, 04:27 AM
Horrified Horrified is offline
Rediculously inactive
Join Date: Jul 2007
Posts: 961
Horrified is on a distinguished road
Send a message via ICQ to Horrified Send a message via AIM to Horrified Send a message via MSN to Horrified Send a message via Yahoo to Horrified
Quote:
Originally Posted by DustyPorViva View Post
I explained it already. That line was simply for debugging, I used it to set my player's chat as the parameters being passed so I could know what information was being sent serverside. I don't see how I was anywhere near being a smartass, but meh.
Not you, people like killerogue who go and say "OH I CANT BELIEVE MY EYES" and leave it at that and do nothing but have it as a derogatory statement...
Reply With Quote
  #8  
Old 08-01-2007, 01:06 AM
Codein Codein is offline
jwd
Codein's Avatar
Join Date: Oct 2005
Location: Greater Manchester
Posts: 2,423
Codein has a spectacular aura aboutCodein has a spectacular aura about
Send a message via AIM to Codein Send a message via MSN to Codein
Do you know how to script, Horrified?
Reply With Quote
  #9  
Old 08-01-2007, 01:08 AM
Crow Crow is offline
ǝɔɐɹq ʎןɹnɔ
Crow's Avatar
Join Date: Dec 2006
Location: Germany
Posts: 5,153
Crow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond repute
Quote:
Originally Posted by Codein View Post
Do you know how to script, Horrified?
That's the point, kinda.
I don't want to sound rude, but if you don't know how to script, dont post here :/
__________________
Reply With Quote
  #10  
Old 08-01-2007, 02:38 AM
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
Quote:
Originally Posted by killerogue View Post
I just couldn't believe my eyes.
pwnt
__________________
Reply With Quote
  #11  
Old 08-01-2007, 04:12 AM
killerogue killerogue is offline
Registered Omega
killerogue's Avatar
Join Date: Apr 2006
Location: United States
Posts: 1,920
killerogue is on a distinguished road
Send a message via AIM to killerogue Send a message via MSN to killerogue
I wasn't trying to be a smartass. If Dusty needs my help he usually AIMs me anyhow. As he wasn't on AIM at the time (I don't thinl ) couldn't really give close up advice.

And yeah, you shouldn't give advice if you don't know what you're talking about.
__________________


REMEMBER, IF YOU REP ME, LEAVE A NAME!

Quote:
Originally Posted by haunter View Post
Graal admins don't die. They go to hell and regroup.
Quote:
Originally Posted by Inverness View Post
Without scripters, your graphics and levels wouldn't do anything but sit there and look pretty.
Reply With Quote
  #12  
Old 08-05-2007, 11:22 AM
zokemon zokemon is offline
That one guy...
zokemon's Avatar
Join Date: Mar 2001
Location: Sonoma County, California
Posts: 2,925
zokemon is a jewel in the roughzokemon is a jewel in the rough
Send a message via ICQ to zokemon Send a message via AIM to zokemon Send a message via MSN to zokemon Send a message via Yahoo to zokemon
Yeah, if you don't know what every line in a script is doing, you should be prepared for people making such states towards you if you try to explain what's wrong. Not trying to persuade you from giving advice but rather you should learn more about GS2 first .
__________________
Do it with a DON!
Reply With Quote
  #13  
Old 08-12-2007, 08:57 PM
Inverness Inverness is offline
Incubator
Inverness's Avatar
Join Date: Aug 2004
Location: Houston, Texas
Posts: 3,613
Inverness is a jewel in the roughInverness is a jewel in the rough
Quote:
Originally Posted by zokemon View Post
Yeah, if you don't know what every line in a script is doing, you should be prepared for people making such states towards you if you try to explain what's wrong. Not trying to persuade you from giving advice but rather you should learn more about GS2 first .
QUOTED FOR TRUTH

It was so extremely irritating to have the GST tell me how my script was wrong when they didn't understand jack-**** about what it was doing.

http://forums.graalonline.com/forums...t=73340&page=2

Anyhow...
PHP Code:
  if (params[0] == "addquantity") {
    for (
temp.0clientr.items.size(); ++) {
      if (
clientr.items[i][0] == params[1]) {
        
clientr.items[i][1] += params[2];
        break;
      }
    }
  } 
You shouldn't be using client flags for long strings of data unless you plan to never use the /open command on RC.
__________________
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:40 PM.


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