Skip to content

Commit

Permalink
Fix #687: RE 2, room 219, crash due to G-Adult
Browse files Browse the repository at this point in the history
  • Loading branch information
IntelOrca committed Dec 8, 2023
1 parent 0773c40 commit 05615c0
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 6 deletions.
4 changes: 4 additions & 0 deletions IntelOrca.Biohazard.BioRand/RE2/Re2EnemyHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,10 @@ public void SetEnemy(RandoConfig config, Rng rng, SceEmSetOpcode enemy, MapRoomE
{
enemy.State = 1;
enemy.SoundBank = 21;
if (enemy.Id != 0)
{
throw new Exception("G-Adult not set for ID_EM_0");
}
}
break;
}
Expand Down
26 changes: 20 additions & 6 deletions IntelOrca.Biohazard.BioRand/data/re2/rdt.json
Original file line number Diff line number Diff line change
Expand Up @@ -560,6 +560,7 @@
"enemies": [
{
"nop": [ "0x2DEC-0x2E90" ],
"excludeTypes": [ 40 ],
"randomPlacements": true
}
]
Expand Down Expand Up @@ -593,30 +594,34 @@
],
"enemies": [
{
"excludeTypes": [ 42, 58 ],
"excludeTypes": [ 40, 42, 58 ],
"maxDifficulty": 2,
"randomPlacements": false
},
{
"nop": [ "0x10A8", "0x0F86-0x0F94" ],
"excludeTypes": [ 40 ],
"randomPlacements": true,
"scenario": 0,
"player": 0
},
{
"condition": "4:15",
"excludeTypes": [ 40 ],
"randomPlacements": true,
"scenario": 1,
"player": 0
},
{
"condition": "4:15",
"excludeTypes": [ 40 ],
"randomPlacements": true,
"scenario": 0,
"player": 1
},
{
"nop": [ "0x0F90", "0x0F3C-0x0F4A" ],
"excludeTypes": [ 40 ],
"randomPlacements": true,
"scenario": 1,
"player": 1
Expand Down Expand Up @@ -1604,6 +1609,7 @@
"enemies": [
{
"condition": "3:67 && !4:55",
"excludeTypes": [ 40 ],
"player": 0
},
{
Expand Down Expand Up @@ -1764,6 +1770,7 @@
},
{
"condition": "3:5 && !1:3",
"excludeTypes": [ 40 ],
"player": 1
}
],
Expand Down Expand Up @@ -2035,11 +2042,13 @@
},
{
"condition": "3:9 && !1:3",
"excludeTypes": [ 40 ],
"scenario": 0,
"player": 1
},
{
"condition": "!1:3",
"excludeTypes": [ 40 ],
"scenario": 1,
"player": 1
}
Expand Down Expand Up @@ -2073,6 +2082,7 @@
},
{
"condition": "!1:3",
"excludeTypes": [ 40 ],
"player": 1
}
],
Expand Down Expand Up @@ -3357,11 +3367,13 @@
"enemies": [
{
"condition": "$27 != 1536 && !34:43",
"excludeTypes": [ 40 ],
"scenario": 1,
"player": 0
},
{
"condition": "$27 != 1536",
"excludeTypes": [ 40 ],
"player": 1
}
]
Expand All @@ -3388,7 +3400,7 @@
"enemies": [
{
"excludeOffsets": [ 10858 ],
"excludeTypes": [ 58 ],
"excludeTypes": [ 40, 58 ],
"restricted": true
}
]
Expand Down Expand Up @@ -3958,31 +3970,31 @@
},
{
"condition": "!3:67",
"excludeTypes": [ 58 ],
"excludeTypes": [ 40, 58 ],
"restricted": true,
"doorRando": false,
"scenario": 0,
"player": 1
},
{
"condition": "!34:43",
"excludeTypes": [ 58 ],
"excludeTypes": [ 40, 58 ],
"restricted": true,
"doorRando": false,
"scenario": 1,
"player": 1
},
{
"condition": "3:133",
"excludeTypes": [ 58 ],
"excludeTypes": [ 40, 58 ],
"restricted": true,
"doorRando": true,
"scenario": 0,
"player": 1
},
{
"condition": "3:132",
"excludeTypes": [ 58 ],
"excludeTypes": [ 40, 58 ],
"restricted": true,
"doorRando": true,
"scenario": 1,
Expand Down Expand Up @@ -4357,11 +4369,13 @@
],
"enemies": [
{
"excludeTypes": [ 40 ],
"restricted": true,
"scenario": 0
},
{
"condition": "!4:137",
"excludeTypes": [ 40 ],
"restricted": true,
"scenario": 1
}
Expand Down

0 comments on commit 05615c0

Please sign in to comment.