Speaking of which, how long more do we have to wait for Doomscript?Gez wrote:Then WFDS I guess
ACS access to individual sectors/lines
Moderator: GZDoom Developers
- Mánibranðr System
- Posts: 179
- Joined: Sun Aug 26, 2012 5:28 pm
- Preferred Pronouns: They/Them
- Location: Hong Kong
Re: ACS access to individual sectors/lines
-
- Posts: 59
- Joined: Sat Apr 12, 2014 11:10 am
Re: ACS access to individual sectors/lines
I guess, another 8 years, but I really want it!ArcheKruz wrote:Speaking of which, how long more do we have to wait for Doomscript?Gez wrote:Then WFDS I guess
Last edited by Monsterovich on Thu Apr 17, 2014 10:03 am, edited 4 times in total.
Re: ACS access to individual sectors/lines
Okay, so you refuse to implement direct access to sectors and lines because it would break compatibility (although no one named any mod that uses negative tags, except for CiF3, and that issue can be solved with a compatflag). So instead we could make different functions for direct access, like SectorNum_SetColor, that works the same as Sector_SetColor, but with sector numbers instead of tags. I proposed negative tags because they keep all the old sector/line access functions and I haven't seen a single mod that uses negative tags.
But don't tell me that direct access to sectors and lines (and actors) is useless. Without it, how do I make a day/night/weather system that correctly restores sector properties back to original without manually setting tags for hundreds of sectors and inevitably making mistakes? (that's what my friends want to do in a real project, but got stuck with the tag system) How do I make new gamemodes based on existing maps that add new features to them? (of course, better editing requires more sector information functions)
And the tag system is restrictive because it doesn't allow you to assign more than one tag to one object (sector/line/actor). This means that when there are multiple tag ranges with intersections between them, you have to assign a different tag to every object. And that's no different from individual access, just worse, because the "tag" field could have been used to provide additional information about the sector. And UDMF user vars...
Actually, individual access to sectors/lines/actors would make UDMF user vars A LOT more useful. Any sector can have any vars set, acting like an overhauled tag system, where every sector/line/actor may have multiple tags and those tags may have additional numers attached. THAT would be REALLY convenient!
But don't tell me that direct access to sectors and lines (and actors) is useless. Without it, how do I make a day/night/weather system that correctly restores sector properties back to original without manually setting tags for hundreds of sectors and inevitably making mistakes? (that's what my friends want to do in a real project, but got stuck with the tag system) How do I make new gamemodes based on existing maps that add new features to them? (of course, better editing requires more sector information functions)
And the tag system is restrictive because it doesn't allow you to assign more than one tag to one object (sector/line/actor). This means that when there are multiple tag ranges with intersections between them, you have to assign a different tag to every object. And that's no different from individual access, just worse, because the "tag" field could have been used to provide additional information about the sector. And UDMF user vars...
Actually, individual access to sectors/lines/actors would make UDMF user vars A LOT more useful. Any sector can have any vars set, acting like an overhauled tag system, where every sector/line/actor may have multiple tags and those tags may have additional numers attached. THAT would be REALLY convenient!
Re: ACS access to individual sectors/lines
Because using tags to do that is better of course..Gez wrote:The idea of having gameplay mods that mess around with lines and sectors in maps which weren't specifically designed for them sounds like a recipe for undefined behaviors and game-breaking bugs.
I think that's just your opinion.Graf Zahl wrote:Without detailed knowledge of the map such access is utterly useless.
I don't think I would call that "cleaner".GooberMan wrote:You know what would be cleaner here? A script that activates once for each sector. Like a new SECTORINIT script type. And then you could get the sector's tag, and if it's zero then you can set it to any unused tag. Say, for example, starting at the minimum value (0x80000000 for 32 bit - chop off the 4 extra zeros if it has to be 16 bit) and checking if that tag is taken and then assigning if it is not.
If his suggestion would be implemented without any problems concerning the tag system I think it would be a much cleaner and better solution than that.
Re: ACS access to individual sectors/lines
You should get out more.Korshun wrote:I haven't seen a single mod that uses negative tags.
You don't. And that's not a bad thing.Korshun wrote:Without it, how do I make a day/night/weather system that correctly restores sector properties back to original without manually setting tags for hundreds of sectors and inevitably making mistakes?
Both myself and Nash have separate day/night/weather systems. What's the problem? You're clearly not thinking it through. You have no problem setting a sector's properties to give it nukage damage, but a tag for a lighting effect is a bad thing?
Rubbish. A tag provides a (non-)unique identifier for a sector/line/actor. The only thing providing additional information about the sector is the scripts you write/line actions you set to support it.Korshun wrote:And that's no different from individual access, just worse, because the "tag" field could have been used to provide additional information about the sector.
It also hides the fact that a sector/line/thing number can change underneath the system. Like I said, it is no different to naming an object in a modern engine so that you can access it via script. The internal representation of the data should be completely meaningless to a mapper/modder. Anyone arguing against this has a very specific purpose in mind and should make a fork for their own nefarious needs rather than messing up a long-standing design decision that is still valid in modern engines.
Welcome to several posts ago.Korshun wrote:Any sector can have any vars set
EDIT:
Then you're also not thinking it through. A script function that lets you analyze a sector on initialisation and decide what you want to do with it? Cleaner, more flexible, and less error-prone than giving direct access to sectors through a half-assed ill-informed modification to the tag system.Leonard2 wrote:I don't think I would call that "cleaner".
EDIT2: I just want to go on record and state that one of the suggested mods that are possible with direct sector access - one that you can alter the properties of a sector such as height with a gun of some sorts on any map in Doom history - is a horrible idea. Because upper/lower linedefs on either side for the relevant sector won't be set correctly because the map won't have been designed to move in that fashion. Helloooooooooo rendering artifacts. Oh, wait, you want access to lines too so you can set upper/lower textures if they don't exist? Bzzzzt. Say goodbye to every vanilla rendering hack.
Re: ACS access to individual sectors/lines
Well, I don't know how flexible something like this would be versus the original intent of this request but, just to make the point, you don't need to use hundred of sector tags to affect things in existing maps. Load the attached file into any of the supported games and start playing.
Re: ACS access to individual sectors/lines
GooberMan wrote:You should get out more.
So, will you name any wad?
How did you implement support for changing light level, color and fog on about 1000 sectors and then restoring their original values? Like, I have a sector gradient light on a street, and it needs to get brighter as the sun rises, and then get darker, but not less than its original value. To implement this in the original system, I need to manually tag every such sector with a different tag for every light level, and what if I have some areas that sometimes get foggy? Now I need to double the amount of tags. Considering that there would be about 200 such sectors, and a lot of tags, it's easy to mix them and end up in bugs. Individual access to sectors fixes all the problems here. Just mark all street light sectors with one tag and make a script that changes and restores all needed properties.GooberMan wrote:Both myself and Nash have separate day/night/weather systems. What's the problem? You're clearly not thinking it through. You have no problem setting a sector's properties to give it nukage damage, but a tag for a lighting effect is a bad thing?
Sector/line/actor numbers need to be NUMBERS only because everything is a number in ACS. If that was DoomScript, they would be object references. Also, what was the last time a sector or line number changed during the game?GooberMan wrote:It also hides the fact that a sector/line/thing number can change underneath the system.
EDIT: Enjay, I know that such scripting is possible. But is it possible to apply a DIFFERENT effect to each sector? (like in the example in the first post)
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49067
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: ACS access to individual sectors/lines
So...
What is it with you people anyway?
You demand the things you need and throw a fit if you don't get them for very valid reasons.
Reality check: This is NOT your engine!!!
What is it with you people anyway?
You demand the things you need and throw a fit if you don't get them for very valid reasons.
Reality check: This is NOT your engine!!!