ok im trying to make an attak called bladesofblood but i have no idea where to start i typed in projectile in the resources box but no good examples... i want to make it where when u shoot it it hits the person and takes away health and i want the damage to be based of of how high the user str is if someone could help me with that i would appreciate it
and before you go saying that i ripped a game or something here is the link it is up now so you can feel free to walk around also im letting u get on this becuase i dont want you to say im a help vampire...or what ever you want to call it but yeh check it out and i need help with the attack thing http://www.byond.com/games/SesshomaruXX/InuyashaBloodShed
ID:272350
Jun 12 2008, 10:03 am
|
|
In response to GhostAnime
|
|
proc/Projectile(mob/M,obj/O,distance,dmg,delay,Homing,Area,mob/H,duration,radious) |
In response to Sesshomaru XX
|
|
Where do you define the str var for each mob?
When you do so, that can be added/multiplied to the base damage (10 as you used here) to increase it. |
Projectiles are movable atoms (/atom/movable, though most people use /obj, which is a branch in that path, for projectiles). When created, where New() is called, most people make it start walk()ing. When the projectile hits something, it calls Bump() on itself (not on the object it hit) - which almost always have a 'del src' at the end, as it is no longer needed.
For Bump(argument), the argument is what was src (the projectile) bumped into. Note that you need to check the argument for what you want. If you put (mob/M) in the parenthesis, it will NOT filter the object (meaning it will not check if it is a /mob) so you need to use procedures such as ismob() and istype() before doing the intended action(s).
So now you know that, use your head. I gave you a couple of hints:
- The type of path you should place your projectile under
- What procedures to use and
- What you must need, at the very least, in the said proecures.