mob/proc/Vega(var/IS,var/damage) //the arguments inside the () allow us to easily customize the proc
//The Icon States for this proc are Kept in Projectiles.dmi
//Simply add a new icon state and name it to match the skill and youre good to go!
var/obj/Supplemental/Projectile/P=new() //first we'll make a new projectile
P.icon_state=IS //this sets the icon state to whatever we need
P.damage=damage //this will set up the damage that we passed in through the arguments
P.Owner=src //set its owner to the person that shot it
P.dir=src.dir //make it face the same direction as the attacker
P.loc=src.loc //locate it on the player
walk(P,src.dir) //this will get P moving in the direction u shot it
spawn(5) del P
for(var/turf/X in range(1,P))
spawn(9)
X.overlays += /obj/Explosion
for(var/mob/M in range(1,P))
M.HP-=src.Str*3
spawn(12)
X.overlays.Cut()
obj
Explosion
icon = 'Projectiles.dmi'
icon_state = "explode"
Problem description:
Well, I am using Projectiles as skills in my game and I thought about adding explosion effect(area damage) to a certain skill. but somehow it wouldn't affect any monster it targets not even and for some reason it would only lower my own HP.
That would show you...
Are
There
You
I hope this helps!