]> Shamusworld >> Repos - thunder/blobdiff - src/thunder.cpp
Fixed pointer size problem that caused GUI crash.
[thunder] / src / thunder.cpp
index d3134ed62db44ff5d5f84bf57f421836b474e1c5..4cd035c2304fb993c21ebd587a86bc37d0d41996 100644 (file)
@@ -1406,6 +1406,7 @@ WriteLog("About to enter main loop...\n");
                                                        DeactivateGUI();
                                                else
                                                        ActivateGUI();
+
                                                debounce = 10;
                                        }
                                }
@@ -1453,28 +1454,38 @@ WriteLog("About to enter main loop...\n");
                                if (keys[SDLK_RETURN])                                                  // Return
                                {
                                        uint8_t retval = UserSelectedSomething();
+
                                        if (retval == EXIT)
                                                running = false;
+
                                        if (retval == REFRESH)
                                        {
                                                refresh2 = !refresh2;
                                                SetRefreshRate(refresh2);
                                        }
                                }
+
                                if (keys[SDLK_1])
                                        gram1[0x427A] = 1;                      // (1)
+
                                if (keys[SDLK_2])
                                        gram1[0x427C] = 1;                      // (2)
+
                                if (keys[SDLK_3])
                                        gram1[0x427E] = 1;                      // (3)
+
                                if (keys[SDLK_5])
                                        gram1[0x4280] = 1;                      // (5)
+
                                if (keys[SDLK_q] | keys[29])
                                        gram1[0x4276] = 1;                      // (Q)  Jump
+
                                if (keys[SDLK_w])
                                        gram1[0x426A] = 1;                      // (W)
+
                                if (fire_debounce)
                                        fire_debounce--;
+
                                if (keys[SDLK_e] | keys[56])    // (E) Fire
                                {
                                        if (!fire_debounce)
@@ -1487,30 +1498,41 @@ WriteLog("About to enter main loop...\n");
                                                        fire_debounce = 2;
                                        }
                                }
+
                                if (keys[SDLK_r])
                                        gram1[0x426C] = 1;                      // (R)
+
                                if (keys[SDLK_t])
                                        gram1[0x4262] = 1;                      // (T)
+
                                if (keys[SDLK_y])
                                        gram1[0x4260] = 1;                      // (Y)
+
                                if (keys[SDLK_F10])
                                        gram1[0x41A5]++;                        // Coin? (F10)
+
                                if (keys[SDLK_z])
                                        gram1[0x4189]++;                        // ? (Z) credits l dig
+
                                if (keys[SDLK_x])
                                        gram1[0x418A]++;                        // ? (X) credits r dig
+
                                if (keys[SDLK_c])
                                        gram1[0x418C]++;                        // ? (C) Start
+
                                if (keys[SDLK_v])
                                        gram1[0x418D]++;                        // ? (V)
+
                                if (keys[SDLK_F7])
                                        SpawnSound(USERSOUND, 0);       // Do user sound (F7)
+
 //                             if (keys[SDLK_F8])
 //                             {
 //                                     gram1[0x4380] = 0;                      // (F8) kill music (this worx)
 //                                     charbase = false;                       // Switch chars out...
 //                             }
 //                             if (keys[SDLK_F9])  gram1[0x4285] = 1;          // (F9) strobe unknown loc
+
                                if (keys[SDLK_F11])                             // (F11)
                                {
                                        Execute6809(&cpu1, 10);
@@ -1523,6 +1545,7 @@ WriteLog("About to enter main loop...\n");
                                        cpu1.cpuFlags |= V6809_ASSERT_LINE_RESET;
                                        cpu2.cpuFlags |= V6809_ASSERT_LINE_RESET;
                                }
+
                                if (keys[SDLK_d])                               // (D) start disassembly
                                        disasm = true;
 #if 0