Zandronum Chat on our Discord Server Get the latest version: 3.1
Source Code

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0003774Zandronum[All Projects] Bugpublic2020-03-25 04:522020-05-02 00:22
Reportersosleepy 
Assigned To 
PrioritynormalSeverityminorReproducibilityalways
StatusnewResolutionopen 
PlatformLinuxOSUbuntu x86_64OS VersionEoan
Product Version3.0 
Target VersionFixed in Version 
Summary0003774: Bots are paralyzed in closed rooms
DescriptionBots are paralyzed in closed rooms such as the rocket launcher room in Doom II's MAP01 and BFG room in MAP07. Text below is the output of botdebug_botcommands when Chubbs is paralyzed in the rocket launcher room in MAP01, facing the wall, opposite direction of the "door".

[...]
bot Chubbs command: Roam
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
bot Chubbs command: LookForWeapons
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
bot Chubbs command: LookForPowerups
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
bot Chubbs command: GetHealth
bot Chubbs command: GetBaseHealth
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
bot Chubbs command: GetArmor
bot Chubbs command: GetBaseArmor
bot Chubbs command: LookForBaseArmor
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
bot Chubbs command: LookForSuperHealth
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
bot Chubbs command: LookForSuperArmor
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
bot Chubbs command: LookForWeapons
bot Chubbs command: GetCurrentWeapon
bot Chubbs command: StringsAreEqual
bot Chubbs command: GetClosestPlayerEnemy
bot Chubbs command: Roam
[...]
Attached Files? file icon botwalk.wad [^] (3,832 bytes) 2020-03-26 02:43
jpg file icon bot_stuck_map.jpg [^] (111,927 bytes) 2020-04-30 18:58


? file icon botwalk-moving.wad [^] (3,832 bytes) 2020-05-01 17:32
? file icon botwalk-large.wad [^] (3,832 bytes) 2020-05-01 17:35

- Relationships

-  Notes
User avatar (0021239)
sosleepy (reporter)
2020-03-26 02:45

Minimal map provided, if the run is any bigger, the bot will start roaming, the bot does not pickup any weapon placed within the room, maybe except if it is right in front of it. Run file with: zandronum -file botwalk.wad -iwad DOOM2.WAD -deathmatch -warp 01 +addbot chubbs +spectate
User avatar (0021243)
Vicious Pariah (reporter)
2020-03-27 00:30
edited on: 2020-03-27 00:33

I have to be completely honest. The bot code is extremely old and I really don't think any major updates to Zandronum or Skulltag had addressed bot glitches. To be honest, bots were not expected to be very smart, heh.

I've been thinking about taking a gander at the bot code a bit more and attempting the task of making it a little bit "smarter". However, it's a large undertaking and I still have to study the codebase more.

User avatar (0021278)
sosleepy (reporter)
2020-04-21 20:15

Since Roam() is executed, botcmd_Roam() and ASTAR_SelectRandomMapLocation() should be studied, since the problem seems to be that the bot doesn't select a new location to roam to, or that the location is selected but then it is necessary to study botcmd_Roam() more.
User avatar (0021294)
zeber (reporter)
2020-04-30 18:58
edited on: 2020-04-30 19:00

We are using bots a lot for practice. I'm attaching a screen from SLADE: on the left is the "rocket launcher room in Doom II's MAP01" from one of the wads, where the bot is stuck. Once we change it to look like the one on the right - the bot works ok! We even thought that the angles between walls matter.

User avatar (0021296)
sosleepy (reporter)
2020-04-30 20:46

Something is happening that the following condition in botcmd_Roam() is never satisfied:
if ( ReturnVal.ulFlags & PF_COMPLETE )
ReturnVal is set by ASTAR_Path()
User avatar (0021297)
sosleepy (reporter)
2020-04-30 20:59

This condition is always satisfied and it appears to be the root of the problem:'https://bitbucket.org/Torr_Samaho/zandronum-stable/src/cfa30cac72570ba01d1fdc0bf07cb07125c5711b/src/botpath.cpp#lines-475 [^]'
BOTPATH_IsPositionBlocked() is worth checking.
User avatar (0021298)
Edward-san (developer)
2020-05-01 15:59
edited on: 2020-05-01 16:00

Quote
Minimal map provided, if the run is any bigger, the bot will start roaming


Can you share another demo map where the bot moves around instead?

Moreover, does this happen also in previous versions of Zandronum, or also in Skulltag?

User avatar (0021299)
sosleepy (reporter)
2020-05-01 17:48

botwalk-moving has 8 units added to the east and 8 units added to the south, that is sufficient to make the bot move, I have also added botwalk-large. I have tested on skulltag 0.98d and the issue appears there.
User avatar (0021300)
sosleepy (reporter)
2020-05-01 18:05

Except in skulltag 0.94c, but then the bot there keeps pushing against a wall.
User avatar (0021302)
sosleepy (reporter)
2020-05-02 00:22

I don't know how helpful this is but changing the magic numbers of the conditions in ASTAR_SelectRandomMapLocation() does help a little. Apparently the bot is simply unable to select a random map location to go to.

Issue Community Support
Only registered users can voice their support. Click here to register, or here to log in.
Supporters: zeber eagle
Opponents: No one explicitly opposes this issue yet.

- Issue History
Date Modified Username Field Change
2020-03-25 04:52 sosleepy New Issue
2020-03-26 02:43 sosleepy File Added: botwalk.wad
2020-03-26 02:45 sosleepy Note Added: 0021239
2020-03-27 00:30 Vicious Pariah Note Added: 0021243
2020-03-27 00:32 Vicious Pariah Note Edited: 0021243 View Revisions
2020-03-27 00:33 Vicious Pariah Note Edited: 0021243 View Revisions
2020-04-21 20:15 sosleepy Note Added: 0021278
2020-04-30 18:58 zeber Note Added: 0021294
2020-04-30 18:58 zeber File Added: bot_stuck_map.jpg
2020-04-30 19:00 zeber Note Edited: 0021294 View Revisions
2020-04-30 20:46 sosleepy Note Added: 0021296
2020-04-30 20:59 sosleepy Note Added: 0021297
2020-05-01 15:59 Edward-san Note Added: 0021298
2020-05-01 15:59 Edward-san Status new => feedback
2020-05-01 16:00 Edward-san Note Edited: 0021298 View Revisions
2020-05-01 17:32 sosleepy File Added: botwalk-moving.wad
2020-05-01 17:35 sosleepy File Added: botwalk-large.wad
2020-05-01 17:48 sosleepy Note Added: 0021299
2020-05-01 17:48 sosleepy Status feedback => new
2020-05-01 18:05 sosleepy Note Added: 0021300
2020-05-02 00:22 sosleepy Note Added: 0021302






Questions or other issues? Contact Us.

Links


Copyright © 2000 - 2024 MantisBT Team
Powered by Mantis Bugtracker