ID:178921
 
I can't find out why making a mobs (src.hp) status go down by a variable (usr.strength) by another variable
usr.hp -= src.strength
gets messed up by the '-' in the -=
I can take out the '-' and it works right but not the way I want it.
It seems like it is wanting to change the mobs type to /mob/monster/gremlin/Click
instead of its type
mob/monster/gremlin

I also can't find out why it makes the player
mob/player/Login

when I put
mob/player
login()
..()
world<<"[usr] joins the game"
make a var within the code
mob
verb
Hit()
set src in oview(1)
var/damage=usr.Strenght
src.Hp-=damage
that would make the src's Hp go down how ever much strength the usr has
Hope that helped



~Richter
In response to Richter
Richter wrote:
make a var within the code
mob
verb
Hit()
set src in oview(1)
var/damage=usr.Strenght
src.Hp-=damage
that would make the src's Hp go down how ever much strength the usr has
Hope that helped



~Richter

There is nothing wrong with using src.HP -= usr.Strength.

I'm guessing there was more than that wrong with the original problem, but he didn't really post the code.