ID:143560
 
Code:


Problem description:


iv been trying to get my techniques to work and its realy starrting to innoy me...i got most of it done and stuff like the actual techs but like the part where u have too add damage its really innoying me...can someone plz help me make it better so it will hit the person depending on how much power u have and it will take it from there hp thanks heres the code


obj/projectile
icon = 'projectiles.dmi'
density = 1
var
delay = 2

length=20
dmg=2
splash
mob/owner
New(_loc,mob/_owner)

if(_owner)
src.dir = _owner.dir
if(!src.loc) src.loc = get_step(_owner,_owner.dir)
src.owner = _owner
Move()
src.length--
if(!src.length) del src
return ..()



Deadly
icon_state = "soren sokatsui"
delay = 1
dmg=100


Kurosaki_power
icon_state = "zan"
delay = 1
dmg=1









Final_Strike
icon_state = "bigbang"
delay = 3
dmg=500
splash=5
beam
var
list/trails = new
max_trails = 0

New()
..()
src.icon_state = "[src.icon_state]head"

Del()
for(var/A in src.trails) del A
..()
Move()
var/turf/old_loc = src.loc
. = ..()
if(!.) return

var/obj/O = new(old_loc)
O.name = "trail"
O.dir = src.dir
O.icon = icon(src.icon,"[initial(src.icon_state)]trail")
src.trails += O
if(src.max_trails && src.trails.len > src.max_trails)
var/a = src.trails[1]
src.trails -= a
del a



Rawr
icon_state = "Raikoho_"
dmg=3
splash=2


Blue_Blast
icon_state = "ka_"
dmg=1
splash=2
EnergyBeam
icon_state = "energybeam_"
max_trails = 5
Blue_Blast1
icon_state = "poo"
dmg=1
splash=2



Bump(mob/M)
var/damage = src.power
M:Hp -= damage
M:DeathCheck()
verb
Kurosaki_power()
set category = "Shoot"
var/obj/projectile/Kurosaki_power/P = new(null,usr)
walk(P,P.dir,P.delay)
Final_Strike()
set category = "Shoot"
var/obj/projectile/Final_Strike/P = new(null,usr)
walk(P,P.dir,P.delay)
Blue_Blast()
set category = "Shoot"
var/obj/projectile/beam/Blue_Blast/P = new(null,usr)
walk(P,P.dir,P.delay)
EnergyBeam()
set category = "Shoot"
var/obj/projectile/beam/EnergyBeam/P = new(null,usr)
walk(P,P.dir,P.delay)
Deadly()
set category = "Shoot"
var/obj/projectile/Deadly/P = new(null,usr)
walk(P,P.dir,P.delay)
Kaaaaa()
set category = "Shoot"
var/obj/projectile/beam/Rawr/P = new(null,usr)
walk(P,P.dir,P.delay)





mob
var/Str = 5
var/Def = 5
var/maxHp = 100
var/Endurance = 5
var/Hp= 100
var/wealth=100
var/maxStr=5
var/power=10
var/Level=1
var/Rank="Starter"
var/inventory[0]



obj/var/Str=0
obj/var/Hp=100


mob
proc
DeathCheck()
if (src.Hp <= 0)
world << "[src] dies at the hands of [usr]!"
del(src) //delete whatever just died
src.Hp = 30
src.loc= locate(1,1,2)