[Won't fix] Patrol routes

Bugs that have been investigated and resolved somehow.

Moderator: GZDoom Developers

Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
Post Reply
User avatar
The Ultimate DooMer
Posts: 2109
Joined: Tue Jul 15, 2003 5:29 pm
Location: Industrial Zone

Patrol routes

Post by The Ultimate DooMer »

Is anyone else finding monster patrol routes to be a little unreliable? I have some set up for my SSD intro, and the marine often wanders away from the path between two points (shouldn't they go in a straight line?), bumping into obstacles, missing doors and failing to get to the end of the path in time.

The smallest route I have works fine, but the others (which are longer and also have doors) are the ones that screw up.
User avatar
Hirogen2
Posts: 2033
Joined: Sat Jul 19, 2003 6:15 am
Operating System Version (Optional): Tumbleweed x64
Graphics Processor: Intel with Vulkan/Metal Support
Location: Central Germany
Contact:

Post by Hirogen2 »

The first map of Massmouth2 also seems to have this issue. When these gray bugs
destroy the door and walk down the hallway, they also do not walk in a straight
line.
I dunno if the patrol pointsin MM2 are straightforward or arranged in a fancy
fashion...
Cyb
Posts: 912
Joined: Tue Jul 15, 2003 5:12 pm

Post by Cyb »

use monster blocking lines to keep them on a path and set them unblocking later if need be
User avatar
The Ultimate DooMer
Posts: 2109
Joined: Tue Jul 15, 2003 5:29 pm
Location: Industrial Zone

Post by The Ultimate DooMer »

I actually did that - in one scene the marine starts outside one of those octagonal LTSD doors and he was missing the entrance. I put impassable lines around him and he still bumped into them and turned round. Fortunately the small space means he still opens the door pretty quickly. (and the patrol point is straight ahead from the marine when he starts) moving and follow with 90º turns and straight lines only after that)

So the marine still goes off course with impassable lines there, as he just turns into them and eventually faces the wrong way, but it's probably better than letting him wander all over the place. Unless I set up sectors that block the way behind him when he enters it...I suppose I could try that.
User avatar
Zell
Posts: 791
Joined: Thu Jul 24, 2003 7:47 am
Location: IN A GODDAMN BOX[In Erie.]

Post by Zell »

what i did once was make diffrent points with monsters that were spawned with thing_hate apllied to them, then to the next room with the monster in it so he followed it. Just make empty rooms that he fits in and set it next to his first destination, then make him teleport to the next area. =)
User avatar
HotWax
Posts: 10002
Joined: Fri Jul 18, 2003 6:18 pm
Location: Idaho Falls, ID

Post by HotWax »

Patrol routes tell the actor in question to move to the targetted spot, and then let the normal enemy movement kick in. The reason they don't take a straight line to get there is because they are limited to 8 directions of movement: N/NE/E/SE/S/SW/W/NW. This means they have to wander around a bit in order to move in between those directions. AFAIK, they wander even if the path from their current position to the destination is along one of those 8 directions, probably so that they don't end up wandering for a little bit and then suddenly make a beeline straight for their target when they happen to hit the right angle.
User avatar
randi
Site Admin
Posts: 7749
Joined: Wed Jul 09, 2003 10:30 pm
Contact:

Post by randi »

Unfortunately, it is as HotWax says. Monsters can only walk in one of eight directions. Changing this is more work than I feel like doing for this.
User avatar
Hirogen2
Posts: 2033
Joined: Sat Jul 19, 2003 6:15 am
Operating System Version (Optional): Tumbleweed x64
Graphics Processor: Intel with Vulkan/Metal Support
Location: Central Germany
Contact:

Post by Hirogen2 »

Why? Because there is only 8 rotations? Sounds logically, but what if there are 16 rotations for a sprite? Otherwise, just let the actor walk the set angle (i.e. 10° right, when 0° is North) to the next waypoint and draw ACTRx0 then.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49235
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Post by Graf Zahl »

Hirogen2 wrote:Why? Because there is only 8 rotations? Sounds logically, but what if there are 16 rotations for a sprite? Otherwise, just let the actor walk the set angle (i.e. 10° right, when 0° is North) to the next waypoint and draw ACTRx0 then.

No, because the code relies on this limitation. It seems to make some things easier to calculate which was important back when Doom was created. Significant changes to the movement code (as in a major rewrite) would be necessary to remove this limitation. But what about a simpler solution? Isn't it possible to completely circumvent the normal movement code while on a patrol route and go straight to the next point?
Post Reply

Return to “Closed Bugs [GZDoom]”