Thread: Trade System
View Single Post
  #8  
Old 11-08-2009, 09:10 PM
Switch Switch is offline
o.o
Switch's Avatar
Join Date: Jan 2007
Location: Philadelphia
Posts: 3,038
Switch has a spectacular aura about
Send a message via MSN to Switch
Quote:
Originally Posted by cbk1994 View Post
  • You're doing stuff like for (i=0; i<p1.size(); i++), where you can just do for (temp.i : p1) {
  • Stuff like {"no", "no"} can be {false, false}, which is probably easier to read, but I guess that's just personal style
For some reason, doing things like for (temp.pie : this.allpies) give me problems in some cases (I can't list one off the top of my head), so I tend not to do that if it's not for allplayers or players, since it's always worked for those.
I changed it to use booleans in my last edit. I had it using them before but I was having trouble getting the function checkBothAccept to work so I was trying a bunch of different things, and I forgot to change it back.

Quote:
Originally Posted by Tigairius View Post
Thank you, I was just about to post that.

This script is not safe and is not safe for server use.
I think I've ironed out most of it in my last edit besides making sure everything on both sides of the trade are the same. The original wasn't meant to prevent memory editing.
__________________
Oh squiggly line in my eye fluid. I see you lurking there on the peripheral of my vision.
But when I try to look at you, you scurry away.
Are you shy, squiggly line?
Why only when I ignore you, do you return to the center of my eye?
Oh, squiggly line, it's alright, you are forgiven.
Reply With Quote