Merge branch 'romhack' into lighting

This commit is contained in:
Ariel A 2022-06-28 00:07:23 -04:00
commit 090dc6b294
7 changed files with 11 additions and 5 deletions

View File

@ -12,10 +12,10 @@
"allow_running": true,
"show_map_name": true,
"battle_scene": "MAP_BATTLE_SCENE_NORMAL",
"connections": null,
"connections": 0,
"object_events": [
{
"graphics_id": "OBJ_EVENT_GFX_REGISTEEL",
"graphics_id": "OBJ_EVENT_GFX_OW_MON",
"x": 8,
"y": 7,
"elevation": 3,
@ -51,7 +51,9 @@
"dest_warp_id": 1
}
],
"coord_events": [],
"coord_events": [
],
"bg_events": [
{
"type": "sign",

View File

@ -25,6 +25,7 @@ EventScript_UseCut::
end
EventScript_CutTreeDown::
setflag FLAG_SAFE_FOLLOWER_MOVEMENT
applymovement VAR_LAST_TALKED, Movement_CutTreeDown
waitmovement 0
removeobject VAR_LAST_TALKED

Binary file not shown.

Before

Width:  |  Height:  |  Size: 546 B

After

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 418 B

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 488 B

After

Width:  |  Height:  |  Size: 7.1 KiB

View File

@ -1,5 +1,6 @@
#include "global.h"
#include "event_data.h"
#include "event_object_movement.h"
#include "field_camera.h"
#include "field_effect.h"
#include "script.h"
@ -214,6 +215,7 @@ static void DoBrailleRegirockEffect(void)
PlaySE(SE_BANG);
FlagSet(FLAG_SYS_REGIROCK_PUZZLE_COMPLETED);
ScriptContext2_Disable();
UnfreezeObjectEvents();
}
bool8 ShouldDoBrailleRegisteelEffect(void)
@ -253,6 +255,7 @@ static void DoBrailleRegisteelEffect(void)
PlaySE(SE_BANG);
FlagSet(FLAG_SYS_REGISTEEL_PUZZLE_COMPLETED);
ScriptContext2_Disable();
UnfreezeObjectEvents();
}
// theory: another commented out DoBrailleWait and Task_BrailleWait.

View File

@ -105,6 +105,7 @@ bool8 ScrCmd_nop1(struct ScriptContext *ctx)
bool8 ScrCmd_end(struct ScriptContext *ctx)
{
FlagClear(FLAG_SAFE_FOLLOWER_MOVEMENT);
StopScript(ctx);
return FALSE;
}
@ -295,6 +296,7 @@ bool8 ScrCmd_returnram(struct ScriptContext *ctx)
bool8 ScrCmd_endram(struct ScriptContext *ctx)
{
FlagClear(FLAG_SAFE_FOLLOWER_MOVEMENT);
ClearRamScript();
StopScript(ctx);
return TRUE;
@ -1270,7 +1272,6 @@ bool8 ScrCmd_releaseall(struct ScriptContext *ctx)
{
u8 playerObjectId;
struct ObjectEvent *followerObject = GetFollowerObject();
FlagClear(FLAG_SAFE_FOLLOWER_MOVEMENT);
// Release follower from movement iff it exists and is in the shadowing state
if (followerObject && gSprites[followerObject->spriteId].data[1] == 0)
ClearObjectEventMovement(followerObject, &gSprites[followerObject->spriteId]);
@ -1287,7 +1288,6 @@ bool8 ScrCmd_release(struct ScriptContext *ctx)
{
u8 playerObjectId;
struct ObjectEvent *followerObject = GetFollowerObject();
FlagClear(FLAG_SAFE_FOLLOWER_MOVEMENT);
// Release follower from movement iff it exists and is in the shadowing state
if (followerObject && gSprites[followerObject->spriteId].data[1] == 0)
ClearObjectEventMovement(followerObject, &gSprites[followerObject->spriteId]);