How do I do this? Let's say I want to change the Attacking Animation Speed from Marines ingame with an upgrade. It doesn't matter if it's a trigger or a data solution, it just has to work properly. Got any ideas?
There's an actor action called AnimSetTimeScale, which is applied to a specific animation as far as I can tell. You can also specify a time scale for animation brackets. Link it to an AddUpgrade event or something.
You could also have the upgrade initiate a model swap, to a model with a faster animation speed (this is global for all animations of that model)
Both these solutions require a new setup for every level of that upgrade. The upgrade->model swap version also prevents you from using a multilevel upgrade (well, you can use one, but all levels will have the same animation speed)
A quick glance at the Trigger Editor only led to the actor event solution, but you can't use a trigger variable as an input for the time scale command.
Thanks for the reply. Your second solution would be the most convenient for me since I don't intend to use multilevel upgrades. Thing is, when i look @ the upgrade effects I can add, theres no content for the actor "Marine Attack" for example. There are some values editable for "Marine" but I need the "Marine Attack" actor to be changed, so this solution doesn't work apparently.
Secondly, I'm not sure if I understand your first solution. For doing this I would need to change the same actor aswell, wouldn't I? I don't really know what you mean by AddUpgrade events too.
Model Swap: This can only change the animation speed of the attacking unit, not the muzzle fire/blast effects etc. You replace the model of the unit with one that has a faster innate animation speed, thus increasing the speed of all animations performed by that unit. This won't help you much if you only want a faster blade swipe or muzzle flash.
Please clarify: do you want to speed up the Marine's recoil animation or the muzzle flash?
The latter will probably require you to create a new actor for the muzzle fire, as referring to the launch/impact fields of Attack actors isn't possible afaik.
I want to achieve an acceleration of the gunfire animation = muzzle flash primarily yes. Everything else is unimportant to me. It's practically that what you get when changing the "Animation Speed" Value of the "Marine Attack" model. It just has to be changed ingame when using a certain upgrade. But replacing the model ("Marine Attack" by "Marine Attack 2" with a higher anim speed) would be perfect for me, I still don't know how it works though.
It doesn't with the current setup. Unless someone tells us a way of referencing the Launch/Impact Action of the Attack actor. Very annoying if you want to tint muzzle effects. The model swap option only works for whole units.
You have to create a new actor of type Model, animation style "once" (curses on me not having an English editor). Give it the Marine Attack model, and add a Host Site Operation SOpAttachWeapon00. Under Event+, add:
Event: Effect.GuassRifle.Start (this is the Marine weapon's damage effect)
Property: At Caster
Action: Create
Event: ActorCreation
Property: Validate (Player I think), have the validator check for the upgrade
Action: AnimSetTimeScale BSD [enter desired number here]
Delete the Marine Attack model from the Attack actor's launch chart. As a simple check to see if the new actor is working, add this to the new actor's Event+ field:
Event: ActorCreation
Action: SetTintColor [vile green, pink or so, something that's easy to recognise]
To see if your Validator is working, change the action of the [second Event in my post] to SetTintColor [different color]
EDIT: I tried your solution out but on the way I came up with an idea and got it running. I simply created a new damage effect, copied the attack actor and the attack launch model, adjusted the values (so that the new effect provided by the upgrade runs a different actor than usual which refers to a different model - with changed anim speed by default). (I know I asked for changing the anim speed ingame, but I didn't know that there was a solution that makes this process redundant.)
I'm sure your method would have worked smoothly aswell, but somehow I didn't manage to adjust all values according to what you had in mind probably. Thanks a lot for the help Photoloss! :)
Don't forget that with a new damage effect you have to add that to any weapon upgrade that affects the unit, and potentially add it to Critical Strike effect lists etc (if you have anything that uses a list of damage effects)
Slight update on my part: Instead of creating the actor like I said, you could use the Art-[Container/Launch/Impact] Model fields of the Attack actor to reference Bunkerattack/launch/impact chart objects. I don't know the exact limits on this though.
The advantage of using only actors is that you can't mess up anything outside of graphical effects, and only have to adjust those should the need be. As an example, the Voidray buff in one of the latest patches was done by adding a behavior to all "massive" units, which contains a list of all VR damage effects! If you used a new damage effect in this case you'd have to add it to the list or the buff would be lost.
Unless it's a 0-damage dummy effect which is added to the weapon via a Set effect, and only triggers if the upgrade is researched.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
How do I do this? Let's say I want to change the Attacking Animation Speed from Marines ingame with an upgrade. It doesn't matter if it's a trigger or a data solution, it just has to work properly. Got any ideas?
There's an actor action called AnimSetTimeScale, which is applied to a specific animation as far as I can tell. You can also specify a time scale for animation brackets. Link it to an AddUpgrade event or something.
You could also have the upgrade initiate a model swap, to a model with a faster animation speed (this is global for all animations of that model)
Both these solutions require a new setup for every level of that upgrade. The upgrade->model swap version also prevents you from using a multilevel upgrade (well, you can use one, but all levels will have the same animation speed)
A quick glance at the Trigger Editor only led to the actor event solution, but you can't use a trigger variable as an input for the time scale command.
@Photoloss: Go
Thanks for the reply. Your second solution would be the most convenient for me since I don't intend to use multilevel upgrades. Thing is, when i look @ the upgrade effects I can add, theres no content for the actor "Marine Attack" for example. There are some values editable for "Marine" but I need the "Marine Attack" actor to be changed, so this solution doesn't work apparently.
Secondly, I'm not sure if I understand your first solution. For doing this I would need to change the same actor aswell, wouldn't I? I don't really know what you mean by AddUpgrade events too.
Model Swap: This can only change the animation speed of the attacking unit, not the muzzle fire/blast effects etc. You replace the model of the unit with one that has a faster innate animation speed, thus increasing the speed of all animations performed by that unit. This won't help you much if you only want a faster blade swipe or muzzle flash.
Please clarify: do you want to speed up the Marine's recoil animation or the muzzle flash?
The latter will probably require you to create a new actor for the muzzle fire, as referring to the launch/impact fields of Attack actors isn't possible afaik.
@Photoloss: Go
I want to achieve an acceleration of the gunfire animation = muzzle flash primarily yes. Everything else is unimportant to me. It's practically that what you get when changing the "Animation Speed" Value of the "Marine Attack" model. It just has to be changed ingame when using a certain upgrade. But replacing the model ("Marine Attack" by "Marine Attack 2" with a higher anim speed) would be perfect for me, I still don't know how it works though.
It doesn't with the current setup. Unless someone tells us a way of referencing the Launch/Impact Action of the Attack actor. Very annoying if you want to tint muzzle effects. The model swap option only works for whole units.
You have to create a new actor of type Model, animation style "once" (curses on me not having an English editor). Give it the Marine Attack model, and add a Host Site Operation SOpAttachWeapon00. Under Event+, add:
Delete the Marine Attack model from the Attack actor's launch chart. As a simple check to see if the new actor is working, add this to the new actor's Event+ field:
To see if your Validator is working, change the action of the [second Event in my post] to SetTintColor [different color]
@Photoloss: Go
EDIT: I tried your solution out but on the way I came up with an idea and got it running. I simply created a new damage effect, copied the attack actor and the attack launch model, adjusted the values (so that the new effect provided by the upgrade runs a different actor than usual which refers to a different model - with changed anim speed by default). (I know I asked for changing the anim speed ingame, but I didn't know that there was a solution that makes this process redundant.)
I'm sure your method would have worked smoothly aswell, but somehow I didn't manage to adjust all values according to what you had in mind probably. Thanks a lot for the help Photoloss! :)
Don't forget that with a new damage effect you have to add that to any weapon upgrade that affects the unit, and potentially add it to Critical Strike effect lists etc (if you have anything that uses a list of damage effects)
Slight update on my part: Instead of creating the actor like I said, you could use the Art-[Container/Launch/Impact] Model fields of the Attack actor to reference Bunkerattack/launch/impact chart objects. I don't know the exact limits on this though.
The advantage of using only actors is that you can't mess up anything outside of graphical effects, and only have to adjust those should the need be. As an example, the Voidray buff in one of the latest patches was done by adding a behavior to all "massive" units, which contains a list of all VR damage effects! If you used a new damage effect in this case you'd have to add it to the list or the buff would be lost.
Unless it's a 0-damage dummy effect which is added to the weapon via a Set effect, and only triggers if the upgrade is researched.