Make some map data struct functions accessible from ui scope
Moderator: GZDoom Developers
- Marisa the Magician
- Posts: 3886
- Joined: Fri Feb 08, 2008 9:15 am
- Preferred Pronouns: She/Her
- Operating System Version (Optional): (btw I use) Arch
- Graphics Processor: nVidia with Vulkan support
- Location: Vigo, Galicia
- Contact:
Make some map data struct functions accessible from ui scope
Namely, those that are pretty much read-only / have no side effects, such as Line's Index(), and various other getters. It would be fine if these were all marked as clearscope, just like many other function on the Actor class, for example.
It's kind of annoying to not have this, honestly, when trying to read properties of these structs from, say, a RenderOverlay function in an event handler.
Edit: Can this be moved to code submissions? I have a pull request ready
It's kind of annoying to not have this, honestly, when trying to read properties of these structs from, say, a RenderOverlay function in an event handler.
Edit: Can this be moved to code submissions? I have a pull request ready
- Major Cooke
- Posts: 8170
- Joined: Sun Jan 28, 2007 3:55 pm
- Preferred Pronouns: He/Him
- Location: QZDoom Maintenance Team
Re: Make some map data struct functions accessible from ui s
This would be highly appreciated. Not having to access ACS specifically for certain contexts would be greatly helpful, especially if we want to not use TIDs.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49056
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Make some map data struct functions accessible from ui s
I'm not convinced this is good. You basically made everything that looked constant accessible. A large portion of these functions has little to no use in UI scope and may cause problems down the line that more state than necessary needs to be kept up-to-date on the UI side of things.
Please break this down into smaller submissions so that they can be evaluated independently of each other.
Please break this down into smaller submissions so that they can be evaluated independently of each other.
- Marisa the Magician
- Posts: 3886
- Joined: Fri Feb 08, 2008 9:15 am
- Preferred Pronouns: She/Her
- Operating System Version (Optional): (btw I use) Arch
- Graphics Processor: nVidia with Vulkan support
- Location: Vigo, Galicia
- Contact:
Re: Make some map data struct functions accessible from ui s
Very well.
Edit: I have opened a small PR for now. Those three functions are the only ones I can find a "general" use for.
Edit: I have opened a small PR for now. Those three functions are the only ones I can find a "general" use for.
- Major Cooke
- Posts: 8170
- Joined: Sun Jan 28, 2007 3:55 pm
- Preferred Pronouns: He/Him
- Location: QZDoom Maintenance Team
Re: Make some map data struct functions accessible from ui s
And an image too, also by Marisa. Holy crap this looks fantastic!
- gwHero
- Posts: 360
- Joined: Mon May 08, 2017 3:23 am
- Graphics Processor: Intel with Vulkan/Metal Support
- Location: The Netherlands
Re: Make some map data struct functions accessible from ui s
Wow, checked that example wad, that's quite impressive. Do you think this will perform well also on large maps?Marisa Kirisame wrote:Very well.
Edit: I have opened a small PR for now. Those three functions are the only ones I can find a "general" use for.
- Marisa the Magician
- Posts: 3886
- Joined: Fri Feb 08, 2008 9:15 am
- Preferred Pronouns: She/Her
- Operating System Version (Optional): (btw I use) Arch
- Graphics Processor: nVidia with Vulkan support
- Location: Vigo, Galicia
- Contact:
Re: Make some map data struct functions accessible from ui s
It shouldn't make any difference. The trace is only as long as the player's use range.
- Marisa the Magician
- Posts: 3886
- Joined: Fri Feb 08, 2008 9:15 am
- Preferred Pronouns: She/Her
- Operating System Version (Optional): (btw I use) Arch
- Graphics Processor: nVidia with Vulkan support
- Location: Vigo, Galicia
- Contact:
Re: Make some map data struct functions accessible from ui s
Big bump: I think this should just be closed, can't think of any other functions that should be ui-accessible.