Animals
NPC_Type="Animal"
var
Random_Walker=0
Random_Direction=0
Fear_Level=2
Speaks//Sound File
Second_Icon
AgeEvo_Second
Third_Icon
AgeEvo_Third
Aggression=0
Bump(mob/M)
..()
if(istype(M,/mob/))
if(M==Owner||src.Aggression==0)
return
else
var/Swiftt=0
if(src.Owner)
var/mob/A=src.Owner
Swiftt=A.Pet_Swift
if(src.AttackDelay)
return
src.AttackDelay=1
flick("Attack",usr)
src.Attacking(M,"Hands")
sleep(11-Swiftt)
src.AttackDelay=0
return
New()
..()
var/obj/Ax=new();Ax.icon='ShadowX3.dmi';Ax.pixel_y-=1;src.underlays+=Ax
src.Commence_AI()
mob/var/tmp/PetOut=0
mob/var
//Pet System
Pet_Owner=0
Pet_Name=""
Pet_Species=""
Pet_Age=0
Pet_Age_EXP=0
Pet_Icon=null
Pet_Vitality=0
Pet_Max_Vitality=0
Pet_Stamina=0
Pet_Max_Stamina=0
mob/proc
Tame(mob/NPC/Animals/M)
if(M.Owner)
src<<"You can't tame someone else's pet.";return
else
switch(input(usr,"Are you sure you'd like to Tame [M.name]? You can not have any other Pets, and this is permanent for the rest of your life.", "") in list ("Yes","No","Cancel"))
if("Yes")
usr.Pet_Name=input(usr,"Please select a name for your new [M.Species].") as text
usr.Pet_Owner=1
src.Pet_Species=M.Species
src.Pet_Age=M.Age
src.Pet_Icon=M.icon
src.Give_Skillcard("Drop_Pet")
src.Give_Skillcard("Pickup_Pet")
src.Pet_Vitality=M.Max_Vitality
src.Pet_Max_Vitality=M.Max_Vitality
src.Pet_Stamina=M.Max_Stamina
src.Pet_Max_Stamina=M.Max_Stamina
M.Owner=src
Drop_Pet()
if(usr.inso)
usr<<"You're currently fused with your pet.";return
if(usr.PetOut==1)
usr<<"Your pet is already out.";return
if(usr.UsingDomu)
return
if(usr.Pet_Vitality<=0)
usr<<"Your pet is knocked out!";return
else if(usr.Pet_Owner==1)
usr<<"You drop [src.Pet_Name]."
var/mob/NPC/Animals/P=new()
usr.PetOut=1
if(P)
P.name=src.Pet_Name
P.icon=src.Pet_Icon
P.loc = locate(usr.x+1, usr.y, usr.z)
P.Owner=usr
P.Species=src.Pet_Species
P.Max_Stamina=src.Pet_Max_Stamina
P.Max_Vitality=src.Pet_Max_Vitality
P.Stamina=src.Pet_Stamina
P.Vitality=src.Pet_Vitality
P.Chakra=src.Pet_Chakra
Pickup_Pet()
for(var/mob/NPC/Animals/P in oview(1))
if(P.Owner==usr)
usr.PetOut=0
src.Pet_Stamina=P.Stamina
src.Pet_Vitality=P.Vitality
del(P)
else
usr<<"This is not your pet."
Problem description: Taming the creature/pet seems to work, but when I try to drop the pet, all I get is a spam of 'You drop [petname]' and the pet doesn't come out.