[Decorate] A_SpawnItemEx Flag: Transfer Scale
Moderator: GZDoom Developers
- NeuralStunner
-
- Posts: 12328
- Joined: Tue Jul 21, 2009 12:04 pm
- Preferred Pronouns: No Preference
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia with Vulkan support
- Location: capital N, capital S, no space
- Contact:
[Decorate] A_SpawnItemEx Flag: Transfer Scale
SXF_TRANSFERSCALE: The caller's ScaleX and ScaleY are transferred to the spawned actor. This would remove the need for a lot of redundant Decorate code.
Re: [Decorate] A_SpawnItemEx Flag: Transfer Scale
I put it in my big submission. http://forum.zdoom.org/viewtopic.php?f= ... 40#p616940
Of course, if there is any kind of problem with that package, the feature could be submitted independently as well.
Most recent patch is untested (I don't have the time right now, must leave immediately).
Of course, if there is any kind of problem with that package, the feature could be submitted independently as well.
Most recent patch is untested (I don't have the time right now, must leave immediately).
- NeuralStunner
-
- Posts: 12328
- Joined: Tue Jul 21, 2009 12:04 pm
- Preferred Pronouns: No Preference
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia with Vulkan support
- Location: capital N, capital S, no space
- Contact:
Re: [Decorate] A_SpawnItemEx Flag: Transfer Scale
Just ran across this again. It's been added already.
Re: [Decorate] A_SpawnItemEx Flag: Transfer Scale
Sorry for the bump, but I think it would have been more flexible if the function had a dedicated "scale" parameter. This would also enable the use of expressions; for example, the "ScaleX" variable should already make the above flag redundant.
Sometimes you don't want the scale of the spawned actor to be neither default, nor equal to that of the calling actor. Currently, a roundabout way to control the scale of the spawned actor is to temporarily re-scale the calling actor (A_SetScale before and after the spawning). A dedicated scale parameter would make this more straightforward.
Sometimes you don't want the scale of the spawned actor to be neither default, nor equal to that of the calling actor. Currently, a roundabout way to control the scale of the spawned actor is to temporarily re-scale the calling actor (A_SetScale before and after the spawning). A dedicated scale parameter would make this more straightforward.
- Major Cooke
- Posts: 8209
- Joined: Sun Jan 28, 2007 3:55 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 10
- Graphics Processor: nVidia with Vulkan support
- Location: GZBoomer Town
- Contact:
Re: [Decorate] A_SpawnItemEx Flag: Transfer Scale
Not going to happen.
Spoiler: Four big reasons I can think of why it won't happenHowever, you also have SXF_IS* flags you can use, if you want to set the scale of the actor just after spawning with A_SetScale call being done from the spawner, pointing it at the child actor via those flags.
Re: [Decorate] A_SpawnItemEx Flag: Transfer Scale
Thanks for that, I didn't realize A_SetScale had an actor pointer parameter.However, you also have SXF_IS* flags you can use, if you want to set the scale of the actor just after spawning with A_SetScale call being done from the spawner, pointing it at the child actor via those flags.
- Major Cooke
- Posts: 8209
- Joined: Sun Jan 28, 2007 3:55 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 10
- Graphics Processor: nVidia with Vulkan support
- Location: GZBoomer Town
- Contact:
Re: [Decorate] A_SpawnItemEx Flag: Transfer Scale
I think this was meant to be tagged as [Already In] or [Duplicate]. The OP suggested SXF_TRANSFERSCALE. 
