mob
proc
deathcheck()
if(src.hp<=0)
src<<"You have been killed."
src.loc=locate(50,50,1)
src.burning=0
src.overlays-=/obj/fire
src.hp=src.maxhp
view()<<"<font color = red>[usr.name] kills [src.name]!"
usr.kills+=1
src.deaths+=1
if(usr.lvl>src.lvl)
usr.xp+=src.lvl+5
usr.gold+=10
usr<<"You gain 10 gold."
usr.lvlcheck()
else
if(usr.lvl<src.lvl)
usr.xp+=src.lvl+15
usr.gold+=20
usr<<"You gain 20 gold."
usr.lvlcheck()
else
usr.xp+=src.lvl+10
usr.gold+=15
usr<<"You gain 15 gold."
usr.lvlcheck()
lvlcheck()
if(src.xp>=src.maxxp)
if(src.lvl<14)
src.maxxp=src.maxxp*1.9
src.xp=0
src.lvl+=1
src<<"You've ranked up!"
src.rankcheck()
src<<"Your health has been increased by 50."
src.maxhp+=50
src.hp+=50
else
src<<"Sorry, you're exceeding the Rank limit, which is currently Rank 14."
Problem description: I'm making a PvP game for my bro, and there's only one problem: You get gold every time you hit someone, instead of every time your target dies. Can someone figure out the problem?