mirror of https://github.com/pret/pokecrystal.git
vba warp function
This commit is contained in:
parent
eacf9b85f5
commit
a98dcc1745
|
@ -462,6 +462,16 @@ class crystal:
|
||||||
crystal.walk_through_walls()
|
crystal.walk_through_walls()
|
||||||
step()
|
step()
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def disable_triggers():
|
||||||
|
set_memory_at(0x23c4, 0xAF)
|
||||||
|
set_memory_at(0x23d0, 0xAF);
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def disable_callbacks():
|
||||||
|
set_memory_at(0x23f2, 0xAF)
|
||||||
|
set_memory_at(0x23fe, 0xAF)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def get_map_group_id():
|
def get_map_group_id():
|
||||||
"""
|
"""
|
||||||
|
@ -495,6 +505,24 @@ class crystal:
|
||||||
y = get_memory_at(0xdcb7)
|
y = get_memory_at(0xdcb7)
|
||||||
return (x, y)
|
return (x, y)
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def menu_select(id=1):
|
||||||
|
"""
|
||||||
|
Sets the cursor to the given pokemon in the player's party. This is
|
||||||
|
under Start -> PKMN. This is useful for selecting a certain pokemon
|
||||||
|
with fly or another skill.
|
||||||
|
|
||||||
|
This probably works on other menus.
|
||||||
|
"""
|
||||||
|
set_memory_at(0xcfa9, id)
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def warp_to(map_group_id, map_id):
|
||||||
|
"""
|
||||||
|
Warp to a different map. Because I said so.
|
||||||
|
"""
|
||||||
|
raise NotImplementedError
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def is_in_battle():
|
def is_in_battle():
|
||||||
"""
|
"""
|
||||||
|
@ -541,6 +569,17 @@ class crystal:
|
||||||
name = translate_chars(bytez)
|
name = translate_chars(bytez)
|
||||||
return name
|
return name
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def warp(map_group_id, map_id, x, y):
|
||||||
|
set_memory_at(0xdcb5, map_group_id)
|
||||||
|
set_memory_at(0xdcb6, map_id)
|
||||||
|
set_memory_at(0xdcb7, y)
|
||||||
|
set_memory_at(0xdcb8, x)
|
||||||
|
set_memory_at(0xd001, 0xFF)
|
||||||
|
set_memory_at(0xff9f, 0xF1)
|
||||||
|
set_memory_at(0xd432, 1)
|
||||||
|
set_memory_at(0xd434, 0 & 251)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def set_partymon2():
|
def set_partymon2():
|
||||||
"""
|
"""
|
||||||
|
|
Loading…
Reference in New Issue