Previously, it was possible to attach a ZScript-defined dynamic light to an actor with the target pointer, but at some point recently that was removed. There should be some other way of attaching ZScript-defined lights to actors.
Attaching lights is far simpler than manually managing light positions (especially since SetOffset was exposed to ZScript). Furthermore, because you can't attach ZScript-defined lights to an actor anymore, the DONTLIGHTSELF flag can no longer be used with these lights.
Attaching dynamic lights to actors (ZScript)
Moderator: GZDoom Developers
- Rip and Tear
- Posts: 185
- Joined: Tue May 02, 2017 3:54 pm
Re: Attaching dynamic lights to actors (ZScript)
This is the biggest downside, IMORip and Tear wrote:Furthermore, because you can't attach ZScript-defined lights to an actor anymore, the DONTLIGHTSELF flag can no longer be used with these lights.
On the other hand, the performance improvement gained from this change was desperately needed. Aaaaa
- Matt
- Posts: 9696
- Joined: Sun Jan 04, 2004 5:37 pm
- Preferred Pronouns: They/Them
- Operating System Version (Optional): Debian Bullseye
- Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
- Contact:
Re: Attaching dynamic lights to actors (ZScript)
Here's the sort of thing I ended up doing:
Spoiler:though it could also be possible to have an actor inherit from the dynamic light actor (but making sure to call Actor.Tick() in its Tick override)