I ran my game for the first time online and something doesn't work right.
Here's the code:
verb
Raise_PL()
set category ="Training"
pl += 10
if(pl == 1020)
verbs += /mob/proc/Ultimate_Attack
world << "[usr] now know the Ultimate Attack."
if(pl == 1100)
verbs += /mob/proc/SSJ
world << "[usr] learns about SSJ transformation."
if(pl == 1200)
verbs += /mob/proc/SSJ2
world << "[usr] learned SSJ2."
else
world << "[usr] has gained 10 pl."
Basically that raises the user's PowerLevel. Once the powerlevel is 1100 it calls the proc "SSJ". The coding for that is:
mob
proc
SSJ()
set category="Tests"
usr.icon_state = "ssjgoku"
overlays -= /obj/overlay/lightning
world << "[usr] tranforms into ssj....kinda...."
That should transform the user. But the problem is that when I play online the only person that gets the "SSJ" proc is the first person to get to 1100PL. I want it so EVERYONE who gets to 1100PL gets this new verb.
ID:176464
![]() Jan 11 2003, 1:20 pm
|
|
![]() Jan 11 2003, 1:33 pm
|
|
Uhhh, I dont understand why your adding a proc to the src's verbs....?
|
Jotdaniel wrote:
Uhhh, I dont understand why your adding a proc to the src's verbs....?Ok, I have a verb, Raise PL, and it raises the PL of the user. Once your PL reaches 1100 it should add the verb SSJ. Am I adding it wrong? How should I add it? |
one i think you should put
verb |
Well, I did all you guys mentioned.
- Made the statements else if() like koolguy said. - I used src. now. - I changed the pl to src.pl And it still doesn't work online. It only allows me to transform because I'm the first one to it. |
Garthor wrote:
Because verbs are procs that are in the datum.verbs list and nothing more.I really have no idea what that means. Could you tell me what I should DO? |
Garthor wrote:
Yes. Tell us what the verb belongs to.What do you mean? The verb Raise_PL() belongs to the user's mob. The verb SSJ and those other procs belong to just some new mob I created....The coding is: mob proc Ultimate_Attack() set category ="Attacks" world<< "[usr] uses the ultimate attack." proc SSJ() set category="Tests" src.icon_state = "ssjgoku" overlays -= /obj/overlay/lightning world << "[usr] tranforms into ssj....kinda...." proc SSJ2() set category="Tests" src.icon_state = "ssjgoku" overlays += /obj/overlay/lightning world << "[usr] tranforms into ssj2....yaaaay...." |