View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0000342 | Gameplay + OpenGL | (No Category) | public | 2017-02-26 12:55 | 2017-02-27 00:33 |
| Reporter | Talon1024 | ||||
| Assigned To | |||||
| Priority | normal | Severity | minor | Reproducibility | always |
| Status | resolved | Resolution | fixed | ||
| Platform | Linux | OS | Ubuntu | OS Version | 16.04 |
| Summary | 0000342: TIF_NOTAKEINFINITE does not work if player has PowerInfiniteAmmo subclass. | ||||
| Description | If the player has a powerup that is a subclass of PowerInfiniteAmmo, TIF_NOTAKEINFINITE does not prevent the ammo item from being taken away. | ||||
| Steps To Reproduce |
| ||||
| Tags | No tags attached. | ||||
|
This bug was introduced in commit e6b31dde27b47f484c4d1073cc3760cab5b4b2a3 on 2017/feb/26 I tried fixing this bug, but was unsuccessful. This was my fix: (it did not work) Note that replacing the FindInventory call with "1" works. "player" is not null. I do not know why it is not finding the subclass object like it should be. p_mobj.cpp (line 904): from: ((dmflags & DF_INFINITE_AMMO) || (player && FindInventory(NAME_PowerInfiniteAmmo))) && item->IsKindOf(NAME_Ammo)) to: ((dmflags & DF_INFINITE_AMMO) || (player && FindInventory(NAME_PowerInfiniteAmmo, true))) && item->IsKindOf(NAME_Ammo)) |
|
|
That should work. Maybe FindInventory is broken as well... |
|
| Well, the fix works for me. | |
| Yeah, mistake on my part. I thought I had a PowerInfiniteAmmo in my inventory in my savegame I was using to test with but I didn't. When I did add it, it worked. | |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2017-02-26 12:55 | Talon1024 | New Issue | |
| 2017-02-26 15:46 | Rachael | Assigned To | => Rachael |
| 2017-02-26 15:46 | Rachael | Status | new => acknowledged |
| 2017-02-26 16:00 | Rachael | Status | acknowledged => assigned |
| 2017-02-26 16:27 | Rachael | Assigned To | Rachael => |
| 2017-02-26 16:27 | Rachael | Status | assigned => confirmed |
| 2017-02-26 16:27 | Rachael | Note Added: 0000783 | |
| 2017-02-26 16:28 | Rachael | Note Edited: 0000783 | View Revisions |
| 2017-02-26 16:28 | Rachael | Note Edited: 0000783 | View Revisions |
| 2017-02-26 19:10 | Graf Zahl | Status | confirmed => resolved |
| 2017-02-26 19:10 | Graf Zahl | Resolution | open => fixed |
| 2017-02-26 19:10 | Graf Zahl | Note Added: 0000789 | |
| 2017-02-26 19:19 | Graf Zahl | Note Added: 0000790 | |
| 2017-02-27 00:33 | Rachael | Note Added: 0000794 |