summaryrefslogtreecommitdiff
path: root/data/maps/JaggedPass
diff options
context:
space:
mode:
Diffstat (limited to 'data/maps/JaggedPass')
-rw-r--r--data/maps/JaggedPass/events.inc35
-rw-r--r--data/maps/JaggedPass/header.inc15
-rw-r--r--data/maps/JaggedPass/map.json246
-rw-r--r--data/maps/JaggedPass/scripts.inc28
4 files changed, 260 insertions, 64 deletions
diff --git a/data/maps/JaggedPass/events.inc b/data/maps/JaggedPass/events.inc
deleted file mode 100644
index f9a82c89b..000000000
--- a/data/maps/JaggedPass/events.inc
+++ /dev/null
@@ -1,35 +0,0 @@
-JaggedPass_EventObjects: @ 8534AE4
- object_event 1, EVENT_OBJ_GFX_HIKER, 0, 10, 8, 3, MOVEMENT_TYPE_FACE_RIGHT, 0, 0, 1, 3, JaggedPass_EventScript_230785, 0
- object_event 2, EVENT_OBJ_GFX_CAMPER, 0, 16, 35, 3, MOVEMENT_TYPE_FACE_LEFT_AND_RIGHT, 0, 0, 1, 4, JaggedPass_EventScript_2307FB, 0
- object_event 3, EVENT_OBJ_GFX_ITEM_BALL, 0, 23, 24, 3, MOVEMENT_TYPE_LOOK_AROUND, 0, 0, 0, 0, JaggedPass_EventScript_291184, FLAG_ITEM_JAGGED_PASS_BURN_HEAL
- object_event 4, EVENT_OBJ_GFX_PICNICKER, 0, 9, 21, 3, MOVEMENT_TYPE_FACE_UP_AND_RIGHT, 1, 1, 1, 3, JaggedPass_EventScript_23079C, 0
- object_event 5, EVENT_OBJ_GFX_MAGMA_MEMBER_M, 0, 16, 19, 3, MOVEMENT_TYPE_FACE_UP, 1, 1, 0, 0, JaggedPass_EventScript_230718, FLAG_HIDE_JAGGED_PASS_MAGMA_GUARD
- object_event 6, EVENT_OBJ_GFX_PICNICKER, 0, 14, 25, 3, MOVEMENT_TYPE_FACE_RIGHT, 1, 1, 1, 3, JaggedPass_EventScript_230871, 0
- object_event 7, EVENT_OBJ_GFX_CYCLING_TRIATHLETE_M, 0, 18, 25, 3, MOVEMENT_TYPE_FACE_LEFT, 1, 1, 1, 3, JaggedPass_EventScript_23085A, 0
-
-JaggedPass_MapWarps: @ 8534B8C
- warp_def 14, 40, 3, 2, MAP_ROUTE112
- warp_def 15, 40, 3, 3, MAP_ROUTE112
- warp_def 13, 5, 3, 2, MAP_MT_CHIMNEY
- warp_def 14, 5, 3, 3, MAP_MT_CHIMNEY
- warp_def 16, 18, 0, 0, MAP_MAGMA_HIDEOUT_1F
-
-JaggedPass_MapCoordEvents: @ 8534BB4
- coord_weather_event 13, 15, 3, COORD_EVENT_WEATHER_SUNNY
- coord_weather_event 21, 12, 3, COORD_EVENT_WEATHER_ASH
- coord_weather_event 14, 15, 3, COORD_EVENT_WEATHER_SUNNY
- coord_weather_event 18, 17, 3, COORD_EVENT_WEATHER_SUNNY
- coord_weather_event 22, 19, 3, COORD_EVENT_WEATHER_SUNNY
- coord_event 21, 15, 3, VAR_0x40C8, 1, JaggedPass_EventScript_2306BB
- coord_event 22, 20, 3, VAR_0x40C8, 1, JaggedPass_EventScript_2306BB
- coord_event 21, 20, 3, VAR_0x40C8, 1, JaggedPass_EventScript_2306BB
- coord_event 14, 15, 3, VAR_0x40C8, 1, JaggedPass_EventScript_2306BB
- coord_event 13, 15, 3, VAR_0x40C8, 1, JaggedPass_EventScript_2306BB
-
-JaggedPass_MapBGEvents: @ 8534C54
- bg_hidden_item_event 8, 10, 3, ITEM_FULL_HEAL, FLAG_HIDDEN_ITEM_JAGGED_PASS_FULL_HEAL
- bg_hidden_item_event 7, 29, 3, ITEM_GREAT_BALL, FLAG_HIDDEN_ITEM_JAGGED_PASS_GREAT_BALL
-
-JaggedPass_MapEvents:: @ 8534C6C
- map_events JaggedPass_EventObjects, JaggedPass_MapWarps, JaggedPass_MapCoordEvents, JaggedPass_MapBGEvents
-
diff --git a/data/maps/JaggedPass/header.inc b/data/maps/JaggedPass/header.inc
deleted file mode 100644
index f53bfbe65..000000000
--- a/data/maps/JaggedPass/header.inc
+++ /dev/null
@@ -1,15 +0,0 @@
-JaggedPass: @ 848402C
- .4byte JaggedPass_Layout
- .4byte JaggedPass_MapEvents
- .4byte JaggedPass_MapScripts
- .4byte 0x0
- .2byte MUS_DAN01
- .2byte 292
- .byte MAPSEC_JAGGED_PASS
- .byte 0
- .byte WEATHER_NONE
- .byte MAP_TYPE_ROUTE
- .2byte 0
- map_header_flags allow_bike=1, allow_escape_rope=0, allow_run=1, show_map_name=1
- .byte MAP_BATTLE_SCENE_NORMAL
-
diff --git a/data/maps/JaggedPass/map.json b/data/maps/JaggedPass/map.json
new file mode 100644
index 000000000..3ec89fce6
--- /dev/null
+++ b/data/maps/JaggedPass/map.json
@@ -0,0 +1,246 @@
+{
+ "id": "MAP_JAGGED_PASS",
+ "name": "JaggedPass",
+ "layout": "LAYOUT_JAGGED_PASS",
+ "music": "MUS_DAN01",
+ "region_map_section": "MAPSEC_JAGGED_PASS",
+ "requires_flash": false,
+ "weather": "WEATHER_NONE",
+ "map_type": "MAP_TYPE_ROUTE",
+ "allow_bike": true,
+ "allow_escape_rope": false,
+ "allow_running": true,
+ "show_map_name": true,
+ "battle_scene": "MAP_BATTLE_SCENE_NORMAL",
+ "connections": null,
+ "object_events": [
+ {
+ "graphics_id": "EVENT_OBJ_GFX_HIKER",
+ "x": 10,
+ "y": 8,
+ "elevation": 3,
+ "movement_type": "MOVEMENT_TYPE_FACE_RIGHT",
+ "movement_range_x": 0,
+ "movement_range_y": 0,
+ "trainer_type": "1",
+ "trainer_sight_or_berry_tree_id": "3",
+ "script": "JaggedPass_EventScript_230785",
+ "flag": "0"
+ },
+ {
+ "graphics_id": "EVENT_OBJ_GFX_CAMPER",
+ "x": 16,
+ "y": 35,
+ "elevation": 3,
+ "movement_type": "MOVEMENT_TYPE_FACE_LEFT_AND_RIGHT",
+ "movement_range_x": 0,
+ "movement_range_y": 0,
+ "trainer_type": "1",
+ "trainer_sight_or_berry_tree_id": "4",
+ "script": "JaggedPass_EventScript_2307FB",
+ "flag": "0"
+ },
+ {
+ "graphics_id": "EVENT_OBJ_GFX_ITEM_BALL",
+ "x": 23,
+ "y": 24,
+ "elevation": 3,
+ "movement_type": "MOVEMENT_TYPE_LOOK_AROUND",
+ "movement_range_x": 0,
+ "movement_range_y": 0,
+ "trainer_type": "0",
+ "trainer_sight_or_berry_tree_id": "0",
+ "script": "JaggedPass_EventScript_291184",
+ "flag": "FLAG_ITEM_JAGGED_PASS_BURN_HEAL"
+ },
+ {
+ "graphics_id": "EVENT_OBJ_GFX_PICNICKER",
+ "x": 9,
+ "y": 21,
+ "elevation": 3,
+ "movement_type": "MOVEMENT_TYPE_FACE_UP_AND_RIGHT",
+ "movement_range_x": 1,
+ "movement_range_y": 1,
+ "trainer_type": "1",
+ "trainer_sight_or_berry_tree_id": "3",
+ "script": "JaggedPass_EventScript_23079C",
+ "flag": "0"
+ },
+ {
+ "graphics_id": "EVENT_OBJ_GFX_MAGMA_MEMBER_M",
+ "x": 16,
+ "y": 19,
+ "elevation": 3,
+ "movement_type": "MOVEMENT_TYPE_FACE_UP",
+ "movement_range_x": 1,
+ "movement_range_y": 1,
+ "trainer_type": "0",
+ "trainer_sight_or_berry_tree_id": "0",
+ "script": "JaggedPass_EventScript_230718",
+ "flag": "FLAG_HIDE_JAGGED_PASS_MAGMA_GUARD"
+ },
+ {
+ "graphics_id": "EVENT_OBJ_GFX_PICNICKER",
+ "x": 14,
+ "y": 25,
+ "elevation": 3,
+ "movement_type": "MOVEMENT_TYPE_FACE_RIGHT",
+ "movement_range_x": 1,
+ "movement_range_y": 1,
+ "trainer_type": "1",
+ "trainer_sight_or_berry_tree_id": "3",
+ "script": "JaggedPass_EventScript_230871",
+ "flag": "0"
+ },
+ {
+ "graphics_id": "EVENT_OBJ_GFX_CYCLING_TRIATHLETE_M",
+ "x": 18,
+ "y": 25,
+ "elevation": 3,
+ "movement_type": "MOVEMENT_TYPE_FACE_LEFT",
+ "movement_range_x": 1,
+ "movement_range_y": 1,
+ "trainer_type": "1",
+ "trainer_sight_or_berry_tree_id": "3",
+ "script": "JaggedPass_EventScript_23085A",
+ "flag": "0"
+ }
+ ],
+ "warp_events": [
+ {
+ "x": 14,
+ "y": 40,
+ "elevation": 3,
+ "dest_map": "MAP_ROUTE112",
+ "dest_warp_id": 2
+ },
+ {
+ "x": 15,
+ "y": 40,
+ "elevation": 3,
+ "dest_map": "MAP_ROUTE112",
+ "dest_warp_id": 3
+ },
+ {
+ "x": 13,
+ "y": 5,
+ "elevation": 3,
+ "dest_map": "MAP_MT_CHIMNEY",
+ "dest_warp_id": 2
+ },
+ {
+ "x": 14,
+ "y": 5,
+ "elevation": 3,
+ "dest_map": "MAP_MT_CHIMNEY",
+ "dest_warp_id": 3
+ },
+ {
+ "x": 16,
+ "y": 18,
+ "elevation": 0,
+ "dest_map": "MAP_MAGMA_HIDEOUT_1F",
+ "dest_warp_id": 0
+ }
+ ],
+ "coord_events": [
+ {
+ "type": "weather",
+ "x": 13,
+ "y": 15,
+ "elevation": 3,
+ "weather": "COORD_EVENT_WEATHER_SUNNY"
+ },
+ {
+ "type": "weather",
+ "x": 21,
+ "y": 12,
+ "elevation": 3,
+ "weather": "COORD_EVENT_WEATHER_ASH"
+ },
+ {
+ "type": "weather",
+ "x": 14,
+ "y": 15,
+ "elevation": 3,
+ "weather": "COORD_EVENT_WEATHER_SUNNY"
+ },
+ {
+ "type": "weather",
+ "x": 18,
+ "y": 17,
+ "elevation": 3,
+ "weather": "COORD_EVENT_WEATHER_SUNNY"
+ },
+ {
+ "type": "weather",
+ "x": 22,
+ "y": 19,
+ "elevation": 3,
+ "weather": "COORD_EVENT_WEATHER_SUNNY"
+ },
+ {
+ "type": "trigger",
+ "x": 21,
+ "y": 15,
+ "elevation": 3,
+ "var": "VAR_JAGGED_PASS_STATE",
+ "var_value": "1",
+ "script": "JaggedPass_EventScript_2306BB"
+ },
+ {
+ "type": "trigger",
+ "x": 22,
+ "y": 20,
+ "elevation": 3,
+ "var": "VAR_JAGGED_PASS_STATE",
+ "var_value": "1",
+ "script": "JaggedPass_EventScript_2306BB"
+ },
+ {
+ "type": "trigger",
+ "x": 21,
+ "y": 20,
+ "elevation": 3,
+ "var": "VAR_JAGGED_PASS_STATE",
+ "var_value": "1",
+ "script": "JaggedPass_EventScript_2306BB"
+ },
+ {
+ "type": "trigger",
+ "x": 14,
+ "y": 15,
+ "elevation": 3,
+ "var": "VAR_JAGGED_PASS_STATE",
+ "var_value": "1",
+ "script": "JaggedPass_EventScript_2306BB"
+ },
+ {
+ "type": "trigger",
+ "x": 13,
+ "y": 15,
+ "elevation": 3,
+ "var": "VAR_JAGGED_PASS_STATE",
+ "var_value": "1",
+ "script": "JaggedPass_EventScript_2306BB"
+ }
+ ],
+ "bg_events": [
+ {
+ "type": "hidden_item",
+ "x": 8,
+ "y": 10,
+ "elevation": 3,
+ "item": "ITEM_FULL_HEAL",
+ "flag": "FLAG_HIDDEN_ITEM_JAGGED_PASS_FULL_HEAL"
+ },
+ {
+ "type": "hidden_item",
+ "x": 7,
+ "y": 29,
+ "elevation": 3,
+ "item": "ITEM_GREAT_BALL",
+ "flag": "FLAG_HIDDEN_ITEM_JAGGED_PASS_GREAT_BALL"
+ }
+ ]
+} \ No newline at end of file
diff --git a/data/maps/JaggedPass/scripts.inc b/data/maps/JaggedPass/scripts.inc
index 93788a703..c51a5ec26 100644
--- a/data/maps/JaggedPass/scripts.inc
+++ b/data/maps/JaggedPass/scripts.inc
@@ -1,12 +1,12 @@
JaggedPass_MapScripts:: @ 8230656
- map_script 5, JaggedPass_MapScript1_230666
- map_script 3, JaggedPass_MapScript1_23068B
- map_script 1, JaggedPass_MapScript1_23069C
+ map_script MAP_SCRIPT_ON_RESUME, JaggedPass_MapScript1_230666
+ map_script MAP_SCRIPT_ON_TRANSITION, JaggedPass_MapScript1_23068B
+ map_script MAP_SCRIPT_ON_LOAD, JaggedPass_MapScript1_23069C
.byte 0
JaggedPass_MapScript1_230666: @ 8230666
setstepcallback 1
- compare VAR_0x40C8, 0
+ compare VAR_JAGGED_PASS_STATE, 0
call_if_eq JaggedPass_EventScript_230674
end
@@ -17,11 +17,11 @@ JaggedPass_EventScript_230674:: @ 8230674
return
JaggedPass_EventScript_230685:: @ 8230685
- setvar VAR_0x40C8, 1
+ setvar VAR_JAGGED_PASS_STATE, 1
return
JaggedPass_MapScript1_23068B: @ 823068B
- compare VAR_0x40BD, 1
+ compare VAR_JAGGED_PASS_ASH_WEATHER, 1
call_if_eq JaggedPass_EventScript_230697
end
@@ -31,7 +31,7 @@ JaggedPass_EventScript_230697:: @ 8230697
return
JaggedPass_MapScript1_23069C: @ 823069C
- compare VAR_0x40C8, 1
+ compare VAR_JAGGED_PASS_STATE, 1
goto_if_le JaggedPass_EventScript_2306A8
end
@@ -61,7 +61,7 @@ JaggedPass_EventScript_2306BB:: @ 82306BB
setmetatile 16, 18, 606, 0
special DrawWholeMapView
delay 30
- setvar VAR_0x40C8, 2
+ setvar VAR_JAGGED_PASS_STATE, 2
waitse
releaseall
end
@@ -71,27 +71,27 @@ JaggedPass_EventScript_230718:: @ 8230718
goto_if_set FLAG_BEAT_MAGMA_GRUNT_JAGGED_PASS, JaggedPass_EventScript_230766
waitse
playse SE_PIN
- applymovement 5, JaggedPass_Movement_272598
+ applymovement 5, Common_Movement_ExclamationMark
waitmovement 0
- applymovement 5, JaggedPass_Movement_27259A
+ applymovement 5, Common_Movement_Delay48
waitmovement 0
- applymovement 5, JaggedPass_Movement_27259E
+ applymovement 5, Common_Movement_FacePlayer
waitmovement 0
msgbox JaggedPass_Text_230CCB, MSGBOX_DEFAULT
closemessage
trainerbattle_no_intro TRAINER_GRUNT_30, JaggedPass_Text_230D2D
setflag FLAG_BEAT_MAGMA_GRUNT_JAGGED_PASS
- applymovement 5, JaggedPass_Movement_2725A2
+ applymovement 5, Common_Movement_FaceOriginalDirection
waitmovement 0
releaseall
end
JaggedPass_EventScript_230766:: @ 8230766
- applymovement 5, JaggedPass_Movement_27259E
+ applymovement 5, Common_Movement_FacePlayer
waitmovement 0
msgbox JaggedPass_Text_230D65, MSGBOX_DEFAULT
closemessage
- applymovement 5, JaggedPass_Movement_2725A2
+ applymovement 5, Common_Movement_FaceOriginalDirection
waitmovement 0
releaseall
end