i used the fighting verb from ZBT and it doesn't work.
mob
proc
DeathCheck()
if(src.health<=0)
world << "[src] gets knocked out!"
src.loc=locate(1,2,2)
src.health=src.maxhealth
verb
attack(mob/M as mob in oview(1))
usr << "You attack [M]!"
oview() << "[usr] attacks [M]!"
var/damage = usr.power
world << "[damage] damage!"
M.health -= damage
1
2
ID:266500
Mar 24 2002, 8:31 am
|
|
In response to Kappa the Imp
|
|
it doesn't send that person to that spot
|
mob/proc/DeathCheck()
if(src.health<=0) world << "[src] gets knocked out!" src.loc=locate(1,2,2) src.health=src.maxhealth mob/verb/attack(mob/M in oview(1)) usr << "You attack [M]!" oview() << "[usr] attacks [M]!" var/damage = usr.power world << "[damage] damage!" M.health -= damage Deathcheck(M) Try That |
Knuckles skater wrote:
i used the fighting verb from ZBT and it doesn't work. This is something you forgot to do in your attack verb after M.health -= damage put this in the next line DeathCheck() Like this: verb<font color = red> DeathCheck() |
In response to Knuckles skater
|
|
put DeathCheck() in the attack verb
|
Try this:
mob -Kappa the Imp |
In response to Kappa the Imp
|
|
That Wont Help Him
|
In response to Strange Kidd
|
|
Strange Kidd wrote:
That Wont Help Him Yes it will. |
In response to Kappa the Imp
|
|
it didn't
|
In response to Kappa the Imp
|
|
No it wont b/c he dosnt have Deathcheck()
|
In response to Strange Kidd
|
|
mob/verb/Attack(mob/m in oview (1))
set category="Attacks" var/damage=usr.str-m.def+1 m.HP-=damage usr<<"You Hit [m] and did [damage] damage!" usr.MaxPl+=5 Deathcheck(m) mob/proc/Deathcheck(mob/M) if(M.HP<=0) if(M.ispbag==1) del(M) else M.loc=locate(1,1,1) Anger(M) usr.isdead=1 this is my exact Code and it works fine try it |
In response to Knuckles skater
|
|
Knuckles skater wrote:
it didn't put M.Deathcheck() in the attack verb. -Kappa the Imp |
In response to Kappa the Imp
|
|
no Deathcheck(M)
|
In response to Strange Kidd
|
|
No M.Deathcheck().
|
In response to Kappa the Imp
|
|
OK Me and Kappa can't decide whos right
mob/proc/Deathcheck(mob/M) all stuff here blah! mob/verb/Attack(mob/M) rest stuff for attack....... Deathcheck(M) or M.Deathcheck() |
In response to Strange Kidd
|
|
Strange Kidd wrote:
mob/verb/Attack(mob/m in oview (1)) Thats a lie.Its not if(M.ispbag==1) its if(istype(src,mob/pbag)).And after mob/verb/Attack(mob/M in oview(1)) you put set src in oview(1). -Kappa the Imp |
In response to Strange Kidd
|
|
ok got it thanks to all of you.
|
In response to Knuckles skater
|
|
ok what was it Deathcheck(M) or M.Deathcheck()
|
1
2
-KTI