diff options
author | Cheng Hann Gan <chenghanngan.us@gmail.com> | 2021-12-12 15:52:06 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-12 12:52:06 -0800 |
commit | c53bdc35f8bdd401e90dfae263a3f5fc9182f86b (patch) | |
tree | 6111353227b153e4aa56422d91e4e79288ce7376 /src/dungeon_random_1.c | |
parent | a34c9ab91b553fcb1f72b94eb912b94bea58885b (diff) |
Dungeon random/AI decomp + converted positions to structs (#83)
* Decomped RollPercentChance()
* Decomped DungeonRandomCapped()
* Decomped DungeonRandom()
* Decomped FindRockItemTargets()
-Added position struct.
Diffstat (limited to 'src/dungeon_random_1.c')
-rw-r--r-- | src/dungeon_random_1.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/dungeon_random_1.c b/src/dungeon_random_1.c new file mode 100644 index 0000000..a6941f3 --- /dev/null +++ b/src/dungeon_random_1.c @@ -0,0 +1,13 @@ +#include "global.h" +#include "dungeon_random_1.h" + +#include "dungeon_random.h" + +bool8 RollPercentChance(s32 percentChance) +{ + if (DungeonRandomCapped(100) < percentChance) + { + return TRUE; + } + return FALSE; +} |