![]() |
New Scripters: Read!
If you're new to scripting, there is one major thing you need to keep in mind. It is better to use variables instead of definitive values. Let me explain:
NPC Code: take THAT where you are setting it to a certain value, which makes editing a SUPER BISH or this: NPC Code: that makes it so that you have a LOT less coding, and can change things. I put that if the tsring is equal to OR GREAT THAN for a reason. If by some MISHAP or something you end up with 6 or something, then it wouldn't work. I try and build in 'extra protection' so incase something crazy happens and you have a glitch, it still works :D And when you're doing things, and the same actions will be repeated by more than one event, I find it best to use functions. If you need help with strings and/or this.vars read www.projectshifter.com more coming soon ---Shifter |
I really hate that format/style.
I knew that, but thanks anyway. |
if you wanted to be a nut about shortening, you could just do
test = (strtofloat(#s(client.string))+1)%6; setstring client.string,#v(test); |
eheheheh
|
Quote:
|
Quote:
|
Quote:
|
Quote:
Well if they understood it then they could make it themselves and that really isn't stealing is it? hmm.... Well I suppose stealing an idea for a script is possible. but I wouldnt' care as long as they were capable of doing it all on thier own. |
test = strtofloat(#s(client.string))+1;
if(test>=6) test=0; setstring client.string,#v(test); there, compromise. Modules in this case do unnessisary math. |
Heh, I get confused by my own script 90% of the time, LMAO. Like my new class selection script for my PW. It spins and you can only see one at a time, fades, all leet cool uber stuff :P Keydown, all the greats in it ;) But I just TOTALLY got confused after sleeping... if I don't do a script 90% or more in one sitting, I usually never finish it, lmao
---Shifter |
| All times are GMT +2. The time now is 05:44 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.