Is there any guide/summary on this? Anything I try with Site actors fails rather disappointingly, and I noticed one of my older implementations broke too (which was basically a blank Site actor hosted on the attachment)
My "attachment" is a ModelAddition actor created by the main unit via ActorCreation->Create"Attachment", meant to act as a surrogate for the actual unit to use the Phoenix turret rotation.
Launch Request+ fails in an "out of scope" way no matter what I try. Launch Site doesn't go out of scope, but never finds the attachment, either it evaluates the SiteOps within the main unit scope, or it gets overridden by the fallback options. I've tried Actor Find, References copied from the "tentacle" skills and even a ::global reference on ActorCreation of the attachment, to no avail.
What's really cheesing me off is that the previous working implementation was so easy, and it broke somehow (that was from before Actor Find worked properly though...)
since some hots patch site actors auto-destroy themselves if they aren't used by other actors (not referenced by other actors). So you need to get use of site actor immediately after creation, otherwise it will disappear. This is good in some way because you now don't need to manualy destroy site actors or define destruction conditions in their events. For example if beam was using 2 custom created sites as Launch and Impact Hosts, after being destroyed those site actors will disappear (if not used by other actors at the same time). I assume this is some kind of garbage collector for actors which prevents leaks. I already posted about this several times. Also this is what making this tutorial outdated http://www.sc2mapster.com/forums/resources/tutorials/9000-data-working-with-turrets-beginner-difficulty/. You can't create site actor which will be used by your action actor upon unit creation, it will just disappear immediately.
Another important caveat:
If action actor has some launch assets => creates LaunchModel actor for attacker it doesn't create LaunchSite actor, and LaunchModel gets referenced as _LaunchGuide, if there are no launch assets defined for action actor, it creates LaunchSite actor and it gets referenced as _LaunchGuide. However, this is valid mostly for missiles, in some cases action actor can skip creating BOTH of them, in this case there is a action flags "Launch Force Site" and "Impact Force Site" which forces action actor to create _LaunchGuide and _ImpactGuide actors in any case. This is realy some tricky shit and my inglisch isn't that good to describe every case, so you can POST A MAP so i will fix it in a best way possible.
There are plenty of ways realy how to adjust launch location for action actor even if LaunchRequest+ doesn't work (which is realy wierd). For example you can create custom LaunchSite or LaunchModel actor (depending on the caveat i described above) for your Action Actor and use "HostSetOffset" actor message. Open this new LaunchSite actor events and put: ActorCreation => HostSetOffset. Put in HostName "::Host" and in HostSubject reference of your attachment (may be just it's name). This works even for missile attacks (calculates pathing properly). This is realy like hammer fix, but i don't know your setup so you can just post a map.
Thanks, LaunchModel and "Force Site" seem to both work just fine. For some reason just adding the actor ID works for Launch Model: Host but not for Launch Request, oh well.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Is there any guide/summary on this? Anything I try with Site actors fails rather disappointingly, and I noticed one of my older implementations broke too (which was basically a blank Site actor hosted on the attachment)
My "attachment" is a ModelAddition actor created by the main unit via ActorCreation->Create"Attachment", meant to act as a surrogate for the actual unit to use the Phoenix turret rotation.
Launch Request+ fails in an "out of scope" way no matter what I try. Launch Site doesn't go out of scope, but never finds the attachment, either it evaluates the SiteOps within the main unit scope, or it gets overridden by the fallback options. I've tried Actor Find, References copied from the "tentacle" skills and even a ::global reference on ActorCreation of the attachment, to no avail.
What's really cheesing me off is that the previous working implementation was so easy, and it broke somehow (that was from before Actor Find worked properly though...)
since some hots patch site actors auto-destroy themselves if they aren't used by other actors (not referenced by other actors). So you need to get use of site actor immediately after creation, otherwise it will disappear. This is good in some way because you now don't need to manualy destroy site actors or define destruction conditions in their events. For example if beam was using 2 custom created sites as Launch and Impact Hosts, after being destroyed those site actors will disappear (if not used by other actors at the same time). I assume this is some kind of garbage collector for actors which prevents leaks. I already posted about this several times. Also this is what making this tutorial outdated http://www.sc2mapster.com/forums/resources/tutorials/9000-data-working-with-turrets-beginner-difficulty/. You can't create site actor which will be used by your action actor upon unit creation, it will just disappear immediately.
Another important caveat: If action actor has some launch assets => creates LaunchModel actor for attacker it doesn't create LaunchSite actor, and LaunchModel gets referenced as _LaunchGuide, if there are no launch assets defined for action actor, it creates LaunchSite actor and it gets referenced as _LaunchGuide. However, this is valid mostly for missiles, in some cases action actor can skip creating BOTH of them, in this case there is a action flags "Launch Force Site" and "Impact Force Site" which forces action actor to create _LaunchGuide and _ImpactGuide actors in any case. This is realy some tricky shit and my inglisch isn't that good to describe every case, so you can POST A MAP so i will fix it in a best way possible.
There are plenty of ways realy how to adjust launch location for action actor even if LaunchRequest+ doesn't work (which is realy wierd). For example you can create custom LaunchSite or LaunchModel actor (depending on the caveat i described above) for your Action Actor and use "HostSetOffset" actor message. Open this new LaunchSite actor events and put: ActorCreation => HostSetOffset. Put in HostName "::Host" and in HostSubject reference of your attachment (may be just it's name). This works even for missile attacks (calculates pathing properly). This is realy like hammer fix, but i don't know your setup so you can just post a map.
Thanks, LaunchModel and "Force Site" seem to both work just fine. For some reason just adding the actor ID works for Launch Model: Host but not for Launch Request, oh well.