obj
dodgeball
icon = 'dodgeball.dmi'
density = 1
Bump(mob/M)
if(ismob(M))
M.loc = locate(38,43,2)
del(src)
verb
Pick_Up()
set category = "Dodgeball"
set src in oview(1)
if(usr.holding==0)
usr.overlays+='dodgeball.dmi'
usr.overlays+= usr.ball
usr.holding+=1
src.Move(usr)
Throw_Ball()
set category = "Dodgeball"
if(usr.holding==1)
usr.overlays-='dodgeball.dmi'
usr.overlays-= usr.ball
usr.holding=0
src.loc = usr.loc
walk(src,usr.dir,2)
mob/var/holding=0
mob/var/ball
Problem description:
You can throw the ball, and when It hits a mob, the mob teleports to the "Jail" outside of the game. But when you try to pick up the ball again, the ball becomes unthrowable and duplicates itself, leaving the copy on the ground, under the player.
And yes, I know I spaced everything too much.
you might wanna change that to: