Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Pet attachments,making them hover on command

PhoenixRene Ashbourne
Script Novice
Join date: 19 Feb 2008
Posts: 9
08-07-2008 15:51
Sorry about being so needy, but I've been messing with these scripts for a while now. I've managed to get most of my scripting problems fixed on my own, but these have been tough for me. I got close on them, or at least I hope so, but I can't quite get them fully functional.

For the Pet attachment scripts, I was considering the following problem.
I am able to rez a pet and have it follow me, or hover near me, but I want to be able to attach the pet to my shoulder, then on command from a HUD, the pet would start hovering near me, then on command again, it would go back to my shoulder. I thought about using several scripts in combination, such as a HUD button that will speak a command, causing the pet to appear and disappear (such as when it is beginning to hover it disappears or going back to my shoulder it reappears, as with sheath and draw commands for swords. I could have another pet continually hovering around me, with opposite commands. When the shoulder pet disappears, the hovering pet appears, and when the shoulder pet appears, the hovering pet disappears. However, is there an easier way, one where the pet would actually look like it is going to the attachment point, and not just disappear from mid air and appear on the shoulder? Any suggestions would be appreciated. :-)
Crunch Underwood
Mr. Grown up, Go away sir
Join date: 25 Sep 2007
Posts: 624
08-07-2008 16:22
i'm a totally useless scripter but perhaps useing a normal pet follower type script where the object is rezzed and then follows you.

you could attach said pet to your shoulder and issue a drop command via your HUD or chat command. this would then drop the attachment and it would act then as a follower.

another press of the button/chat command should then be able to re-attach to your shoulder (or last point of attachment)

-Crunch
_____________________
----------------------------------------------

So your final Nimbus Score is 8.15, a quite remarkable achievement for a biped. Congratulations Crunch, you should be very proud. :-)
Derek Tafler
Registered User
Join date: 24 May 2008
Posts: 140
09-01-2008 06:55
I am looking to develop a script to do the same as the OP ... ie have a pet leave my shoulder, hover or fly within a local distance, then return and land back on my shoulder. In my mind, I envisage this happening when I am engaged in a physical activity, eg walking or flying, or dancing (I already know that dancing is not seen as movement).

I am totally new to the topic of scripting, but hope that with tenacity, I can piece together enough code to be able to achieve this. If successful, then I can adapt the code to actually make my pet's wings fly ...

Bold dreams, since I am at the 'hello Avatar' stage ... :)
Ruthven Willenov
Darkness in your light
Join date: 16 Jan 2008
Posts: 965
09-01-2008 10:06
if you've seen the pet bats from blood designs, the "flying" ones aren't actualy hover pets, they're also attached and depending on the said commands, they fly in circles around you, follow behind you, or sleep on your shoulders and back. each command makes the desired ones appear, while turning the others fully aplha. it would need a listen in at least one of the prims that would listen for the command from the hud and then send the specified commands to the link set as a link message. optionally, i've seen scripts that show/hide other prims in the set depending on their name, which i suppose could make it easier as well instead of needing a link message receiver for each prim. going that route, i would probably make the root prim always invisible so that it doesn't need to be named according to the script commands
Ruthven Willenov
Darkness in your light
Join date: 16 Jan 2008
Posts: 965
09-01-2008 10:11
additionally, you could also look into using the Puppeteer scripts for the movement. haven't really messed with it too much so i'm not sure how you would go about using it with more than a couple commands. any products i've bought that uses it, is either always looping, or triggered on click. not sure if it has a listen feature as a command as well
ArchTx Edo
Mystic/Artist/Architect
Join date: 13 Feb 2005
Posts: 1,993
09-01-2008 12:17
Another way to do this is to have the attached pet turn invisible on command and at the same time rezz a follower copy of it self that hoovers around you. When you issue the command for the follower to disappear, the attached pet reappears.
_____________________

VRchitecture Model Homes at http://slurl.com/secondlife/Shona/60/220/30
http://www.slexchange.com/modules.php?name=Marketplace&MerchantID=2240
http://shop.onrez.com/Archtx_Edo
Ruthven Willenov
Darkness in your light
Join date: 16 Jan 2008
Posts: 965
09-01-2008 21:38
From: ArchTx Edo
Another way to do this is to have the attached pet turn invisible on command and at the same time rezz a follower copy of it self that hoovers around you. When you issue the command for the follower to disappear, the attached pet reappears.


right, but the reason i said for the "follower" remain attached, is for no-build areas. i've seen alot more of them lately it seems, and if it's not no-build, the return time is annoyingly low. maybe i'm just visiting the wrong places lol.

but yes, that is another great method. the mean kitty shoulder pet rezzes a copy of itself scratching the face of whoever touches it
Derek Tafler
Registered User
Join date: 24 May 2008
Posts: 140
09-02-2008 01:24
I have just looked at Puppeteer via Google (at work grrr !) and it looks a fun way to achieve the effect I am after, not sure of the loading I will bring into a sim though. However, it should take me forward, I will have a play this evening.

From what I have seen, there are a range of animation triggers, click, chat, rez, walk, fly etc.

Thinking through my case, I will perhaps start with simple head moving of my pet ... or a similar simple activity before launching into a full flight pattern.
Ruthven Willenov
Darkness in your light
Join date: 16 Jan 2008
Posts: 965
09-02-2008 06:41
From: Derek Tafler
I have just looked at Puppeteer via Google (at work grrr !) and it looks a fun way to achieve the effect I am after, not sure of the loading I will bring into a sim though. However, it should take me forward, I will have a play this evening.


great, and in case you didn't see, there is a free test version on slx. you can use it as many times as you want for personal items, but it is no transfer
ArchTx Edo
Mystic/Artist/Architect
Join date: 13 Feb 2005
Posts: 1,993
09-02-2008 08:00
From: Derek Tafler
I have just looked at Puppeteer via Google (at work grrr !) and it looks a fun way to achieve the effect I am after, not sure of the loading I will bring into a sim though. However, it should take me forward, I will have a play this evening.

From what I have seen, there are a range of animation triggers, click, chat, rez, walk, fly etc.

Thinking through my case, I will perhaps start with simple head moving of my pet ... or a similar simple activity before launching into a full flight pattern.


The creator of the Puppeteer scripts also makes an Evil Kitten shoulder pet that behaves somewhat like what you have described. When touched it leaps off your shoulder and scratches the face of anyone who touched it. Pretty cute. Check it out at his store.
_____________________

VRchitecture Model Homes at http://slurl.com/secondlife/Shona/60/220/30
http://www.slexchange.com/modules.php?name=Marketplace&MerchantID=2240
http://shop.onrez.com/Archtx_Edo
Ruthven Willenov
Darkness in your light
Join date: 16 Jan 2008
Posts: 965
09-02-2008 19:41
From: ArchTx Edo
The creator of the Puppeteer scripts also makes an Evil Kitten shoulder pet that behaves somewhat like what you have described. When touched it leaps off your shoulder and scratches the face of anyone who touched it. Pretty cute. Check it out at his store.


that's probably the one i was talking about lol. i haven't actually been in world for nearly a week
Derek Tafler
Registered User
Join date: 24 May 2008
Posts: 140
09-03-2008 01:03
Had a very quick play with the puppeteer last night. Went to a sandbox first, made a backup copy of my pet, then started looking in detail.

I encountered problems straight away, as the root prim (which the animation works from), is not in the 'core' of the pet, its actually one wing, so I would not be able to get my pet to flap its wings ... This also explains why my hover and follow script was making my pet hover sideways, rather than face towards me. This is challenging my extremely limited knowledge of inworld skills, because of course I have only tried oddments of most things (don't we all). One solution I am considering, is to unlink and rebuild my pet, since there appear to be some duplicate and redundant prims inside anyway. It was a freebie with modify rights, so I am using it as an exercise to educate myself. I keep myself going by reminding myself that less than a week ago, I had not even editted an object (or done any building for that matter).
Ruthven Willenov
Darkness in your light
Join date: 16 Jan 2008
Posts: 965
09-03-2008 12:12
From: Derek Tafler
Had a very quick play with the puppeteer last night. Went to a sandbox first, made a backup copy of my pet, then started looking in detail.

I encountered problems straight away, as the root prim (which the animation works from), is not in the 'core' of the pet, its actually one wing, so I would not be able to get my pet to flap its wings ... This also explains why my hover and follow script was making my pet hover sideways, rather than face towards me. This is challenging my extremely limited knowledge of inworld skills, because of course I have only tried oddments of most things (don't we all). One solution I am considering, is to unlink and rebuild my pet, since there appear to be some duplicate and redundant prims inside anyway. It was a freebie with modify rights, so I am using it as an exercise to educate myself. I keep myself going by reminding myself that less than a week ago, I had not even editted an object (or done any building for that matter).


with puppeteer, you cannot animate the root prim, as the child prims animate around it. unless you can somehow fit it into the design as a stationary prim, it's best to have the root completely transparent, and animate all the other prims in the set. as for your wing problem, the solution is simple. create a transparent prim as described above, select the wings, then select the trans prim, and link. the root prim is always the last prim selected when linking prims