Why doesn't AI recognize interactive wall portals?
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Why doesn't AI recognize interactive wall portals?
Note: I don't consider this a bug, otherwise I would have made a report on mantis.
I know AI/monsters can use static (Eternity) portals, but those are rather a pain to setup for what I'm planning and are less flexible. (Also, [wiki]Line_SetPortalTarget[/wiki] doesn't affect them.)
I'm just curious what are the technical reasons why the more flexible interactive wall portals are "invisible" to monsters and why you can't hear anything on the other side?
EDIT: Test map removed.
I know AI/monsters can use static (Eternity) portals, but those are rather a pain to setup for what I'm planning and are less flexible. (Also, [wiki]Line_SetPortalTarget[/wiki] doesn't affect them.)
I'm just curious what are the technical reasons why the more flexible interactive wall portals are "invisible" to monsters and why you can't hear anything on the other side?
EDIT: Test map removed.
Last edited by Fishytza on Thu Mar 16, 2017 12:50 pm, edited 1 time in total.
Re: Why doesn't AI recognize interactive wall portals?
Interactive portals are more illusory than static portals. The reason why static portals work is because they link everything together - they try to tie together information from both ends of the portal and essentially make the scene truly seamless - interactive portals are nothing more than a visual window to the other side that just happens to let objects pass through.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49056
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Why doesn't AI recognize interactive wall portals?
The reason is that the AI needs a fixed offset between two regions to handle it - when making calculations it just adds that offset to the coordinates.
Fixed offset means that all paths leading from section A to section B add up to the same displacement. If you have different displacements along different paths the AI cannot determine which one to choose.
Fixed offset means that all paths leading from section A to section B add up to the same displacement. If you have different displacements along different paths the AI cannot determine which one to choose.
Re: Why doesn't AI recognize interactive wall portals?
Thanks for answering so quickly.
- Trusty McLegit
- Posts: 264
- Joined: Sun Feb 07, 2016 8:42 pm
Re: Why doesn't AI recognize interactive wall portals?
So, what's the difference between visual portals and interactive portals?
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49056
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Why doesn't AI recognize interactive wall portals?
Visual portals are just visual, they cannot be crossed.
- Trusty McLegit
- Posts: 264
- Joined: Sun Feb 07, 2016 8:42 pm
Re: Why doesn't AI recognize interactive wall portals?
Sorry, I meant "Visual + simple teleporter"
Re: Why doesn't AI recognize interactive wall portals?
Sound doesn't travel through a visual/simple portal, for starters.
- Trusty McLegit
- Posts: 264
- Joined: Sun Feb 07, 2016 8:42 pm
Re: Why doesn't AI recognize interactive wall portals?
Sound doesn't travel through interactive portals either
Re: Why doesn't AI recognize interactive wall portals?
As far as you, the player, are concerned, you can't hear anything on the other side of a interactive portal (I assume it's the same for visual and visual + simple teleport). Monsters on the other hand can 'hear' you. Meaning if you shoot your gun any monster on the other side of a interactive portal will wake up.
With static portals, you can hear actor-played sounds (monster chatter, fireballs being thrown etc) but sector-played sounds
(eg. a floor lowering) won't be heard, for some odd reason.
With static portals, you can hear actor-played sounds (monster chatter, fireballs being thrown etc) but sector-played sounds
(eg. a floor lowering) won't be heard, for some odd reason.
- Trusty McLegit
- Posts: 264
- Joined: Sun Feb 07, 2016 8:42 pm
Re: Why doesn't AI recognize interactive wall portals?
Awesome, thanks for the explanation!