fix(enemizer): bonk fairies and standard tutorial guard fixed

This commit is contained in:
aerinon
2024-04-19 14:29:26 -06:00
parent 22a9f76c77
commit 0faeeeb45f
3 changed files with 6 additions and 3 deletions

View File

@@ -260,7 +260,7 @@ def get_randomize_able_sprites_ow(area_id, data_tables):
req = data_tables.sprite_requirements[key]
if isinstance(req, dict):
continue
if not req.static and req.can_randomize:
if not req.static and req.can_randomize and not sprite.static:
sprite_table[idx] = sprite
return sprite_table

View File

@@ -27,6 +27,7 @@ def init_vanilla_sprites_ow():
create_sprite(0x21b, EnemySprite.GreenKnifeGuard, 0x20, 0x1A, '', 0x09CB51)
create_sprite(0x21b, EnemySprite.TutorialGuard, 0x2D, 0x25, '', 0x09CB54)
create_sprite(0x21b, EnemySprite.TutorialGuard, 0x20, 0x29, '', 0x09CB57)
create_sprite(0x21b, EnemySprite.TutorialGuard, 0x3C, 0x2A, '', 0x09CB5B)
create_sprite(0x21d, EnemySprite.Apple, 0x0B, 0x06, '', 0x09CB5B)
create_sprite(0x22b, EnemySprite.TutorialGuard, 0x09, 0x1E, '', 0x09CB5F)
create_sprite(0x22b, EnemySprite.TutorialGuard, 0x0B, 0x1E, '', 0x09CB62)

View File

@@ -134,9 +134,11 @@ class DataTables:
# calculate how big this table is going to be?
# bytes = sum(1+len(x)*3 for x in self.ow_enemy_table.values() if len(x) > 0)+1
# ending_byte = 0x09CB3B + bytes
max_per_state = {0: 0x40, 1: 0x90, 2: 0x8D} # dropped max on state 2 to steal space for a couple extra sprites (Murahdahla)
max_per_state = {0: 0x40, 1: 0x90, 2: 0x8B} # dropped max on state 2 to steal space for a couple extra sprites (Murahdahla, extra tutorial guard)
pointer_address = snes_to_pc(0x09C881)
data_pointer = snes_to_pc(0x09CB3B) # was originally 0x09CB41 - stealing space for a couple extra sprites (Murahdahla)
# currently borrowed 10 bytes, used 9 (2xMurah + TutorialGuard)
data_pointer = snes_to_pc(0x09CB38) # was originally 0x09CB41 - stealing space for a couple extra sprites (Murahdahla, extra tutorial guard)
empty_pointer = pc_to_snes(data_pointer) & 0xFFFF
rom.write_byte(data_pointer, 0xff)
cached_dark_world = {}