SphereCommunity
make NPC pet? - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: Script Help (/Forum-Script-Help)
+--- Thread: make NPC pet? (/Thread-make-NPC-pet)



make NPC pet? - x77x - 05-04-2016 12:28 AM

how do i make an NPC become your pet by speech?

Code:
[SPEECH s_army_commands_new]
ON=*attention soldier*
    IF (<SRC.TAG.ARMYNUMBER>==<TAG.ARMYNUMBER>) && (<LEVEL> < <SRC.LEVEL>)
        SAY Command me sir!    
        //???
    ELSE
        SAY I do not take orders from you!
    ENDIF

thx


RE: make NPC pet? - n1ghtwish - 05-08-2016 12:23 PM

Take a look in sphere_general_functions.scp for f_MakePetOf

Should help Smile


RE: make NPC pet? - x77x - 05-09-2016 06:00 AM

no such file in the nightly from a few weeks ago


RE: make NPC pet? - Criminal - 05-09-2016 06:30 AM

Code:
// <pet uid>.f_MakePetOf <owner uid>
[function f_MakePetOf]
serv.newitem i_memory
new.color = memory_ipet
new.more1 = 04
new.more2 = <serv.time>
new.morep = <p>
new.link = <args>
new.cont = <uid>



RE: make NPC pet? - Coruja - 05-09-2016 08:57 AM

I posted this function some weeks ago, but I can't remember where

EDIT: found it http://forum.spherecommunity.net/Thread-Makemypet?pid=23314#pid23314