Code:
The verbs:
mob/Trainer/verb New_Send_Out() set category = "PokeCommands" var/mob/Pokemon/P=input(usr,"Select a Pokemon to send out","Select") in usr.pokemonlist if(P.returned==1&&!usr.client.cont) P.loc=locate(usr.x,usr.y,usr.z) usr.PkmInInven-=1 P.returned=0 client.cont=P client.eye=P client.perspective=EYE_PERSPECTIVE P.client.contd=0 else usr << "[P] isnt in its pokeball!" return
Return() set category = "PokeCommands" var/mob/Pokemon/P=input(usr,"Select a Pokemon to return","Select") in usr.pokemonlist if(P.owner==usr&&P.returned==1) usr<<"They are already in your bag!" return if(usr.PkmInInven==6) usr << "You cant hold anymore pokemon in your pockets!" return else walk(P,0) P.loc=usr P.returned=1 P.following=0 P.wandering=0 P.Training=0 client.cont.client.contd=1 usr.client.cont=null client.eye=usr view(12) << "[P] Return!" usr.PkmInInven+=1 return
|
The vars:
client var/mob/cont var/tmp/contd=1
|
Problem description:
Well, I got those two runtime errors here:
runtime error: Cannot modify null.contd.
proc name: New Send Out (/mob/Trainer/verb/New_Send_Out)
source file: pokemon tab.dm,37
usr: SilverShine (/mob/male1)
src: SilverShine (/mob/male1)
call stack:
SilverShine (/mob/male1): New Send Out()
runtime error: Cannot modify null.contd.
proc name: Return (/mob/Trainer/verb/Return)
source file: pokemon tab.dm,58
usr: SilverShine (/mob/male1)
src: SilverShine (/mob/male1)
call stack:
SilverShine (/mob/male1): Return()
I can't seem to fix them myself. Anyone who is helping me out, thanks in advance.
Your error is caused by the game looking for a client in a mob that doesn't have a client.