ID:145138
 
Code:

mob
var
heal
spell
magic
verb
Fire()
var/colour = "red"
set category="Magic"
if(spell) return //if the usr is already using a spell return
spell=1 //the usr is using a spell
var
direct=dir //makes direct equivulant to usr.dir
obj/spells/Fire/O=new(usr.loc) //creates fire where the usr stands
damage = ((usr.str / 3) + usr.str) //the damage that the fire will cause
location //varible defined later...
spawn(30) //do the following in 3 seconds
spell=0 //the usr is not using a spell
if(O) //if O still exists
del(O) //delete the fireball
while(O) //while O exists
location=O.loc //location is the fireballs location
sleep(2) //the speed of the fireball
step(O,direct) //fireball moves in "direct" direction
if(location==O.loc) //if location is still equal to the fireballs loc after the step proc, then delete it.
del(O)
for(var/mob/M in view(0,O))
if(M==usr) //if M is usr
continue //restart the for proc
if(M.density) //if the mob has density
M.hp-=damage-M.def //add damage and spawn the death proc
spawn()
s_damage(M,damage,colour)
spawn()
M.DeathCheck()
del(O) //delete the fireball and return
return
for(var/obj/o in view(0,O))
if(o.density) //if o has a density delete the fireball and return
del(O)
return
for(var/turf/t in view(0,O))
if(t.density) //if t has a density delete the fireball and return
del(O)
return
continue
Problem description:

MagicMan (/mob/character): Fire()
runtime error: Cannot read null.loc
proc name: Blizzard (/mob/magic/verb/Blizzard)
usr: MagicMan (/mob/character)
src: MagicMan (/mob/character)
call stack:
Where is your blizzard proc?
In response to Tazor07
Don't copy/paste random demos here and expect us to fix them..
And use the <dm> tags. (Yey, remembered 'm!)
In response to Tazor07
mysame wth are you talking about, and taz the blizzard code is just like the fire just diff icons.
In response to MagicBLC13
Well if the problem description says its in the blizzard proc. It's sort of hard to fix it if you show a fire proc.
In response to MagicBLC13
What he's saying is that if you put code in the DM tags, it's easier to read.

mob/verb/say(t as text)
world << t
mob/verb/say(t as text)
world << t