View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0000519 | The Dark Mod | AI | public | 13.01.2008 11:44 | 22.02.2012 16:23 |
Reporter | tels | Assigned To | |||
Priority | normal | Severity | normal | Reproducibility | have not tried |
Status | resolved | Resolution | fixed | ||
Target Version | TDM 1.08 | Fixed in Version | TDM 1.08 | ||
Summary | 0000519: AI needs "wait for resource" lock (aka: work together) | ||||
Description | Crispay said: Elevators and doors will probably need a "waiting" mechanism to deal with the case where multiple AI are trying to use them at once. Otherwise, think of a 3-floor, open-air elevator, where the player has gone to the middle floor and there are AIs on the upper and lower floors chasing him. Each AI would repeatedly call the elevator to their floor before the other AI had a chance to board it, causing a very stupid-looking infinite loop! As for doors, there's an analogous situation where one AI needs to close a door to get past it (in a narrow corridor), whereas another AI needs to open the same door. End result: both of them get stuck. Closest / highest-ranking / luckiest AI gets priority, perhaps. Or if the elevator floors are different distances apart, choose the AI who has the least vertical distance to travel. | ||||
Additional Information | This issue is a general problem with multiple AI that try to do the same thing. They some how need to work together. This is even the case for the very simple scenary where there is a narrow corridor and two AI want to go through it at the same time. They might be both get stuck at the entrance, trying to puch each other out of the way. We could simple set priorities in the following fashion: * guards are higher than civilians * higher ranks beat lower ranks * stronger (more health) beats weaker Either add some random element, or use totally random numbers would also work. Two AI would then "negotiate" who has to wait and who can go. | ||||
Tags | No tags attached. | ||||
The door-handling was changed to handle multiple AI. Narrow hallways are handled by the AI negotiating how to get past each other. As a last resort, one stands still and goes non-solid until the other has passed. A more elegant solution would cover the hallway with an entity that serves as a traffic cop w/in its bounds, allowing one AI through at a time, or perhaps several heading in the same direction. Elevators, etc. remain a problem. |
|
Doors and elevators are correctly shared now. | |
Date Modified | Username | Field | Change |
---|---|---|---|
13.01.2008 11:44 | tels | New Issue | |
13.01.2008 11:45 | tels | Relationship added | parent of 0000516 |
13.01.2008 12:14 | greebo | Status | new => confirmed |
21.06.2011 03:53 | grayman | Note Added: 0003893 | |
21.06.2011 03:56 | grayman | Note Edited: 0003893 | |
22.02.2012 16:23 | grayman | Note Added: 0004344 | |
22.02.2012 16:23 | grayman | Status | confirmed => resolved |
22.02.2012 16:23 | grayman | Resolution | open => fixed |
22.02.2012 16:23 | grayman | Fixed in Version | => TDM 1.08 |
22.02.2012 16:23 | grayman | Target Version | => TDM 1.08 |