summaryrefslogtreecommitdiff
path: root/src/koopatlas/shop.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/koopatlas/shop.cpp48
1 files changed, 46 insertions, 2 deletions
diff --git a/src/koopatlas/shop.cpp b/src/koopatlas/shop.cpp
index 04d7e54..ed64c8e 100644
--- a/src/koopatlas/shop.cpp
+++ b/src/koopatlas/shop.cpp
@@ -165,6 +165,8 @@ int dWMShop_c::onCreate() {
layout.enableNonLoopAnim(i);
}
+ layout.drawOrder = 0x01;
+
layoutLoaded = true;
}
@@ -186,7 +188,7 @@ int dWMShop_c::onExecute() {
if (!layout.isAnyAnimOn()) {
if (nowPressed & WPAD_B) {
- MapSoundPlayer(SoundRelatedClass, SE_SYS_WINDOW_CLOSE, 1);
+ MapSoundPlayer(SoundRelatedClass, SE_SYS_DIALOGUE_OUT_AUTO, 1);
CloseUpShop();
} else if (nowPressed & WPAD_DOWN) {
if (currentItem == 6) { return true; }
@@ -252,6 +254,48 @@ int dWMShop_c::onDraw() {
return true;
}
+void dWMShop_c::specialDraw1() {
+ OSReport("Lakionnnne....");
+ if (!isHidden) {
+ Vec pos = {layout.posX, layout.posY, 40000.0};
+ S16Vec rot = {0,0,0};
+ Vec scale = {1.0, 1.0, 1.0};
+ matrix.translation(pos.x, pos.y, pos.z);
+ matrix.applyRotationYXZ(&rot.x, &rot.y, &rot.z);
+
+ shopkeep.setDrawMatrix(matrix);
+ shopkeep.setScale(&scale);
+ shopkeep.calcWorld(false);
+ shopkeep.scheduleForDrawing();
+ shopkeep._vf1C();
+
+ if(this->ska.isAnimationDone())
+ this->ska.setCurrentFrame(0.0);
+ }
+ return;
+}
+
+void dWMShop_c::specialDraw2() {
+ OSReport("Lakituuu....");
+ if (!isHidden) {
+ Vec pos = {layout.posX, layout.posY, 40000.0};
+ S16Vec rot = {0,0,0};
+ Vec scale = {1.0, 1.0, 1.0};
+ matrix.translation(pos.x, pos.y, pos.z);
+ matrix.applyRotationYXZ(&rot.x, &rot.y, &rot.z);
+
+ shopkeep.setDrawMatrix(matrix);
+ shopkeep.setScale(&scale);
+ shopkeep.calcWorld(false);
+ shopkeep.scheduleForDrawing();
+ shopkeep._vf1C();
+
+ if(this->ska.isAnimationDone())
+ this->ska.setCurrentFrame(0.0);
+ }
+ return;
+}
+
void dWMShop_c::changeItem(int last, int current) {
@@ -295,7 +339,7 @@ void dWMShop_c::LoadShopForWorld(int world) {
return; }
// Handle showing it
- MapSoundPlayer(SoundRelatedClass, SE_SYS_WINDOW_OPEN, 1);
+ MapSoundPlayer(SoundRelatedClass, SE_SYS_DIALOGUE_IN, 1);
isHidden = false;
layout.enableNonLoopAnim(18);