SphereCommunity
Talents problem - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: Script Help (/Forum-Script-Help)
+--- Thread: Talents problem (/Thread-Talents-problem)

Pages: 1 2 3 4


RE: Talents problem - XuN - 11-19-2014 07:30 PM

I found this script so weird, in your loops you use for i 1 3, but inside you use local.bla = local.i-1, same for for a 1 5, using sometimes <local.a> in tag's checks and <local.a>-1 for def's checks, which result in confusion reading the script, why don't use the same syntax for everything? I don't know your script or what is it supossed to do (same as everyone else) and things like that makes us to have to spend much more time (which sometimes we don't have) to help you.

Maybe you can take a look on what has been said until now (getting rid of 'was working before', 'was working on linux', etc) and make a update on your first post so we can follow new changes and we advance with them instead of stuck on old code Smile


RE: Talents problem - Runcuks - 11-19-2014 08:05 PM

This script is supossed to upgrade your skills. When you gen level up, you get 1 talent point. and so on 1 point for every level up.
Then, you can upgrade stats with these points. Like, strenght, dex, int, etc. natural resisstance etc.
i think these differrent loops is because of difereent functions in script. i don't know for sure..


RE: Talents problem - darksun84 - 11-19-2014 09:22 PM

That's why it's important to use comments on the script Big Grin


RE: Talents problem - Extreme - 11-20-2014 12:07 AM

First lesson: you don't eval strings. You CAN'T use <dlocal.id> because its = _something.
Or you store only numbers and use eval or you store the _thing without eval.


RE: Talents problem - Runcuks - 11-20-2014 12:39 AM

I can't store only numbers, because i have these wos_t_1_m1_name
and <local.id> stores this one (talents.scp,775) DEBUG# : _1_m0 but can't understand why its showing me _1_m0 if these skills to upgrade there is starting from _1_m1 ...

and for this one <tag0.t_<dlocal.tnum>_<dlocal.knum>> it supposed to store the position from top to buttom, like first , second, third skill to upgrade. but in console test. its allways showing me 0 ..
0.o


RE: Talents problem - Extreme - 11-20-2014 02:58 AM

Okay, where this ' _1_m0 ' is created?
Why it is 0 ? What gives this number?


RE: Talents problem - Runcuks - 11-20-2014 03:08 AM

(11-20-2014 02:58 AM)Extreme Wrote:  Okay, where this ' _1_m0 ' is created?
Why it is 0 ? What gives this number?

_1_m0 is created at <local.id>

Code:
local.d  =<streat <explode <dlocal.act>,<argn>>>
if (<local.tree>==1)//all talents
   local.id=_<dstreat <local.d>>
else
   local.class=<get_talents_class>
   local.id=_<eval <local.tree>-1>_<local.class><dstreat <local.d>>
endif

hmm and why it is 0 i think there is something with these <dstreat or <explode ..


P.S Question about sphere versions. Could it be that from 0.56a to 0.56b is some differences for these lines? Because im using 0.56b for now..


RE: Talents problem - Extreme - 11-20-2014 03:13 AM

Maybe..

But try debug these lines too...
The explode, the streat..


RE: Talents problem - Runcuks - 11-20-2014 03:38 AM

<dstreat <local.d>> _4_m0 but on <dstrarg <local.d>> was _4_m5 but still no reaction. talent is maxed..
Code:
local.act=<strsub 1,1,<argn>>
local.d  =<streat <explode <dlocal.act>,<argn>>>
serv.log <streat <explode <dlocal.act>,<argn>>>
local.tree = <strarg <local.d>>
local.tnum  = <strarg <local.d>>-1
serv.log <eval <local.tnum>>
local.knum  = <streat <local.d>>
serv.log <eval <local.knum>>

19:37:(wos_talents.scp,747)2
19:37:(wos_talents.scp,750)1
19:37:(wos_talents.scp,752)0


RE: Talents problem - Extreme - 11-20-2014 04:20 AM

try...
serv.log <local.id> <streat <local.d>>

You should enter on irc chat.
http://forum.spherecommunity.net/irc.php