Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   weird this var bug (https://forums.graalonline.com/forums/showthread.php?t=24568)

AvPPoW 02-25-2002 01:39 PM

weird this var bug
 
hello, while working on jobs for dd I have recently encountered bugs that involve this.vars, refresh my memory, this var's keep track of vars for the local npc right? Well anyways let me give you an example. In my mining script I use this vars to keep track of a rock/gem's life. If one player starts to mine and another player hits it while he is mining it reverts to starting progress. Like if the ore was on stage 3 (6 different stages) and he hit it the ore would revert back to stage 1, and then if I hit it again it would be at stage three again and so on. how can I resolve this?

Falcor 02-26-2002 03:29 AM

Quote:

Originally posted by Kaimetsu
save[] vars.
beat me to it :( mr. monkey

Lomgren 02-26-2002 08:16 AM

OoOoOo...

*always wanted to know what save[] did...*

Ahhh..

*still doesn't really get it*

TDK_RC6 02-26-2002 08:55 AM

how come you can only save up to 220 in save variables??

TDO2000 02-27-2002 01:26 AM

Quote:

Originally posted by TDK_RC6
how come you can only save up to 220 in save variables??
hmmm save vars are something like byte-vars in other languages...

Slaktmaster 02-27-2002 01:52 AM

Some time ago I made like an exact copy of the 2001 mining script for free servers. Was never put into use.

TDO2000 02-27-2002 07:56 PM

Quote:

Originally posted by Kaimetsu


But bytes can hold 256 different values rather than 221.

save only has 221??? oh my mistake ^_^

Saga2001 02-27-2002 09:54 PM

I used save[] vars a while back for a playerhouse system, worked like a charm, I'd suggest em anyday.

neomaximus2k 02-28-2002 06:35 AM

Quote:

Originally posted by TDK_RC6
how come you can only save up to 220 in save variables??
If i can remember correctly it is due to byte size.
normally there is a 255 limit.
it is difficult to explain tho and i am very tired lol but
255 isn't a true limit due to the fact that there is not an evan amount of data in a bite (cant remember exact figure)
then again this could have been answered later on in the post :)

neomaximus2k 02-28-2002 02:21 PM

Quote:

Originally posted by Kaimetsu


No, I don't think it's anything to do with byte size. Normal bytes can store 256 different values - there are obviously some reserved states for some reason.

your correct forget that post of mine lol


All times are GMT +2. The time now is 06:01 AM.

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