shithub: cstory

Download patch

ref: b461211fb539286a826ab790985f769a647fc053
parent: e4c520bb7c931f3595a19e9440bc2a5fe835c9c0
author: Clownacy <[email protected]>
date: Wed Feb 6 15:46:18 EST 2019

Bugfix and a widescreen/tallscreen fix

--- a/src/NpcAct160.cpp
+++ b/src/NpcAct160.cpp
@@ -11,6 +11,7 @@
 #include "Frame.h"
 #include "Caret.h"
 #include "MycParam.h"
+#include "CommonDefines.h"
 
 //Puu Black
 void ActNpc160(NPCHAR *npc)
@@ -923,7 +924,7 @@
 	rcRight[2] = {48, 152, 72, 176};
 	rcRight[3] = {72, 152, 96, 176};
 
-	if (npc->x <= gMC.x + 0x28000 && npc->x >= gMC.x - 0x28000 && npc->y <= gMC.y + 0x1E000 && npc->y >= gMC.y - 0x1E000)
+	if (npc->x <= gMC.x + (WINDOW_WIDTH * 0x200) && npc->x >= gMC.x - (WINDOW_WIDTH * 0x200) && npc->y <= gMC.y + (WINDOW_HEIGHT * 0x200) && npc->y >= gMC.y - (WINDOW_HEIGHT * 0x200))
 	{
 		switch (npc->act_no)
 		{
--- a/src/NpcAct320.cpp
+++ b/src/NpcAct320.cpp
@@ -37,7 +37,7 @@
 				npc->y = gMC.y - 0x400;
 			}
 			// Fallthrough
-		case 1:
+		case 10:
 			if (++npc->act_wait / 8 & 1)
 				npc->ani_no = 0;
 			else