mob/proc
parsespell(msg)
for(var/mob/M in world)
if(findtext(msg,"Magic forces black and white to reach out though space and light, be he far or be he near, bring us the demon [M.name] here"))
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(M.RolePlaying==0)
spellwords=null
return
if(M.Demon==1)
if(usr.Intelligence <= M.Intelligence)
usr<<"Your spell isnt strong enough"
spellwords=null
return
if(usr.death==1)
usr<<"You are death"
spellwords=null
return
if(M.death==1)
usr<<"[M] is death"
spellwords=null
return
if(M.erased==1)
usr<<"Who the hell you trying to summon?"
spellwords=null
return
M.loc=locate(x,y-1,z)
M<<"<i>You were summoned out of hell by a spell..."
else
usr<<"You cannot use spells"
spellwords=null
if(findtext(msg,"In this tween time, this darkest hour I call upon the sacred power. I myself stand alone command [M.name] to be shown."))
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(M.RolePlaying==0)
spellwords=null
return
if(usr.Intelligence <= M.Intelligence)
usr<<"Your spell isnt strong enough"
spellwords=null
return
if(M.Selforb == 1)
M.density = 1
M.Selforb = 0
M.icon = new /mob/goodwitch()
view(9)<<"[M] becomes visable"
spellwords=null
else
usr<<"You cannot use spells"
spellwords=null
if(findtext(msg,"Ixo Mende Layto Sempar [M.name]"))
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(M.RolePlaying==0)
spellwords=null
return
if(usr.Intelligence <= M.Intelligence)
usr<<"Your spell isnt strong enough"
spellwords=null
return
if(M.Darklighter==1)
if(usr.death==1)
usr<<"You are death"
spellwords=null
return
if(M.death==1)
usr<<"[M] is death"
spellwords=null
return
if(M.erased==1)
usr<<"Who the hell you trying to summon?"
spellwords=null
return
M.loc=locate(x,y-1,z)
M<<"<i>You were summoned by a spell..."
spellwords=null
else
usr<<"You cannot use spells"
spellwords=null
if(findtext(msg,"With my power that it be I summon the one that brings destiny to my feet now he fall come to me Angel of Destiny now thee I call"))
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(M.RolePlaying==0)
spellwords=null
return
if(usr.Intelligence <= M.Intelligence)
usr<<"Your spell isnt strong enough"
spellwords=null
return
if(M.rank=="Angel of Destiny")
if(usr.death==1)
usr<<"You are death"
spellwords=null
return
if(M.death==1)
usr<<"[M] is death"
spellwords=null
return
if(M.erased==1)
usr<<"Who the hell you trying to summon?"
spellwords=null
return
M.loc=locate(x,y-1,z)
M<<"<i>You were summoned by a spell..."
spellwords=null
else
usr<<"You cannot use spells"
spellwords=null
if(findtext(msg,"Spirits of air, forest and sea, set us of this demon free, beasts of hoof and beasts of shell, drive this [M.name] back to hell"))
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(M.RolePlaying==0)
spellwords=null
return
if(usr.Intelligence <= M.Intelligence)
usr<<"Your spell isnt strong enough"
spellwords=null
return
if(M.Demon==1)
M.loc=locate(/turf/Area/Hell)
M<<"You were sent to hell by an evil spell..."
spellwords=null
if(M.Demon==1&&M.power>=usr.power)
usr<<"[M] seems to be to strong to return with a spell"
spellwords=null
else
usr<<"You cannot use spells"
spellwords=null
if(findtext(msg,"Hellspawn demon, Creature of death, Fire shall take [M.name] very last breath"))
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(M.RolePlaying==0)
spellwords=null
return
if(usr.Intelligence <= M.Intelligence)
usr<<"Your spell isnt strong enough"
spellwords=null
return
if(M.Demon==1)
if(M in view(20))
M.health = 0
usr.deathcheck(M)
spellwords=null
else
usr<<"[M] isnt near you"
spellwords=null
else
usr<<"You cannot use spells"
spellwords=null
if(findtext(msg,"Knowledge and reverence"))
if(usr.RolePlaying==0)
return
src.said_forcefield=1
var/said=0
for(var/mob/M in view(3))
if(M.said_forcefield==1)said+=1
if(said>=2)
for(var/mob/M in view(10))
if(M.said_forcefield==1)
var/westn=0
var/eastn=0
var/northn=0
var/southn=0
for(var/mob/Q in get_step(M,WEST))if(Q.said_forcefield==1)westn=1
for(var/mob/Q in get_step(M,EAST))if(Q.said_forcefield==1)eastn=1
for(var/mob/Q in get_step(M,NORTH))if(Q.said_forcefield==1)northn=1
for(var/mob/Q in get_step(M,SOUTH))if(Q.said_forcefield==1)southn=1
if(!westn)
var/obj/forcefield/W=new(M.loc)
step(W,WEST)
W.owner=key
W.density=1
var/obj/forcefield/NW=new(M.loc)
step(NW,NORTHWEST)
NW.owner=key
NW.density=1
var/obj/forcefield/SW=new(M.loc)
step(SW,SOUTHWEST)
SW.owner=key
SW.density=1
if(!eastn)
var/obj/forcefield/E=new(M.loc)
step(E,EAST)
E.owner=key
E.density=1
var/obj/forcefield/NE=new(M.loc)
step(NE,NORTHWEST)
NE.owner=key
NE.density=1
var/obj/forcefield/SE=new(M.loc)
step(SE,SOUTHWEST)
SE.owner=key
SE.density=1
if(!northn)
var/obj/forcefield/N=new(M.loc)
step(N,NORTH)
N.owner=key
N.density=1
var/obj/forcefield/NWW=new(M.loc)
step(NWW,NORTHWEST)
NWW.owner=key
NWW.density=1
var/obj/forcefield/NEE=new(M.loc)
step(NEE,NORTHEAST)
NEE.owner=key
NEE.density=1
if(!southn)
var/obj/forcefield/S=new(M.loc)
step(S,SOUTH)
S.owner=key
S.density=1
var/obj/forcefield/SWW=new(M.loc)
step(SWW,SOUTHWEST)
SWW.owner=key
SWW.density=1
var/obj/forcefield/SEE=new(M.loc)
step(SEE,SOUTHEAST)
SEE.owner=key
SEE.density=1
spawn(rand(100,300))
for(var/obj/forcefield/O in view(3))if(O.owner==key)del(O)
spawn(100)said_forcefield=0
spellwords=null
if(findtext(msg,"Let the piercing cry that feeds on pain, and leaves more sorrow then it gains. Shall now be heard by one who seeks, to stop the havoc that it wreaks"))
for(var/mob/Q in view(100))
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(Q.RolePlaying==0)
spellwords=null
return
if(usr.Intelligence <= Q.Intelligence)
usr<<"Your spell isnt strong enough"
spellwords=null
return
if(Q.Demon==1)
if(Q in view(10))src<<"<i>You sense [Q.name]. [Q.name] seems to be very close to you."
else if(Q in view(20))src<<"<i>You sense [Q.name]. [Q.name] seems to be close to you."
else if(Q in view(30))src<<"<i>You sense [Q.name]. [Q.name] seems to be far from you."
else src<<"<i>You sense an evil presence, but it is too far for you to sense who it is..."
spellwords=null
else
usr<<"You cannot use spells"
spellwords=null
if(findtext(msg,"As the flame lights shadows, and truth ends fear, open lost thoughts, to my willing ear"))
for(var/mob/M in view(100))if(M.client)
var/txt="<i>"
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(M.RolePlaying==0)
spellwords=null
return
if(M in view(15))
txt+="You sense [M.name]. \He feels close to your location. "
txt+="You sense the blood of a [lowertext(M.race)] burning inside of \him."
if(M.good)txt+="You sense that [M.name] is good in nature. "
else txt+="You sense that [M.name] is evil in nature. "
if(M.maxhealth>=M.maxhealth)
txt+="You also sense that [M.name] is in a good condition. "
else if(M.health<M.maxhealth&&M.health>=M.maxhealth/3)txt+="You also sense that [M.name] is in a average condition. "
else if(M.health<M.maxhealth/3&&M.health>=M.maxhealth/2)txt+="You also sense that [M.name] is in a weakened condition. "
else if(M.health<M.maxhealth/2&&M.health>=10)txt+="You also sense that [M.name] is in a sub-critical condition. "
else txt+="You also sense that [M.name] is in a critical condition. "
if(M.power>=src.power)txt+="You sense that [M.name] is stronger than you."
else if(M.power==src.power)txt+="You sense that [M.name] is equal than you."
else txt+="You sense that [M.name] is weaker than you."
spellwords=null
else if(M in view(30))
txt+="You sense [M.name]. \He feels further away from your location. "
txt+="You sense the blood of a [lowertext(M.race)] burning inside of \him."
if(M.good)txt+="You sense that [M.name] is good in nature. "
else txt+="You sense that [M.name] is evil in nature. "
if(rand(1,2))
if(M.maxhealth>=M.maxhealth)
txt+="You also sense that [M.name] is in a good condition. "
else if(M.health<M.maxhealth&&M.health>=M.maxhealth/3)txt+="You also sense that [M.name] is in a average condition. "
else if(M.health<M.maxhealth/3&&M.health>=M.maxhealth/2)txt+="You also sense that [M.name] is in a weakened condition. "
else if(M.health<M.maxhealth/2&&M.health>=10)txt+="You also sense that [M.name] is in a sub-critical condition. "
else txt+="You also sense that [M.name] is in a critical condition. "
else if(rand(1,2))
if(M.power>=src.power)txt+="You sense that [M.name] is stronger than you."
else if(M.power==src.power)txt+="You sense that [M.name] is equal than you."
else txt+="You sense that [M.name] is weaker than you."
spellwords=null
else if(M in view(50))
txt+="You sense [M.name]. \He feels far away from your location. "
if(M.good)txt+="You sense that [M.name] is good in nature. "
else txt+="You sense that [M.name] is evil in nature. "
if(M.power>=src.power)txt+="You sense that [M.name] is stronger than you."
else if(M.power==src.power)if(rand(1,2))txt+="You sense that [M.name] is equal than you."
spellwords=null
else
txt+="You sense someone. He or she feels extremely far away from your location. "
if(M.good)txt+="You sense that [M.name] is good in nature. "
else txt+="You sense that [M.name] is evil in nature. "
if(M.power>=src.power)txt+="You sense that [M.name] is stronger than you."
spellwords=null
src<<txt
else
usr<<"You cannot use spells"
spellwords=null
if(findtext(msg,"Yam is ado, Heek is ado, Malo cot bonus, Moss in con sesis, Super deeco nos"))
for(var/mob/M in range(9))
if(usr.Witch==1||usr.Warlock==1||usr.HalfWhitelighter==1||usr.Demon==1)
if(M.RolePlaying==0)
usr<<"[M] isnt in the Role Play"
spellwords=null
return
if(usr.Intelligence <= M.Intelligence)
usr<<"Your spell isnt strong enough"
spellwords=null
return
if(M.containhollow == 1)
M.containhollow = 0
M.race = M.choosenrace
spellwords=null
view(9) << "The hollow has been sent back to the box by a spell"
else
usr<<"You cannot use spells"
spellwords=null
how can i make it clickable?