RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login

    Possible to port GridWars 2

    Scheduled Pinned Locked Moved General Discussion and Gaming
    55 Posts 7 Posters 9.3k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      spud11 @mitu
      last edited by

      @mitu Seems a bit strange because I haven't used noexec option anywhere. All files appear in the /home/pi/RetroPie/roms/gridwars2 folder that I have created and I'm just trying to start the file from commandline.

      RetroPie v4.4.1 • RPi3 Model B • 5.1V 2.5A PSU • 32GB SanDisk Extreme microSD • 2TB Toshiba Canvio Basics Portable USB 3.0 hard drive • 4 x DragonRise USB Arcade joysticks • 2 x TurboTwist spinners • 1 x USB trackball • 1 x PS4 wireless • 1 x 8BitDo Zero

      mituM 1 Reply Last reply Reply Quote 0
      • mituM
        mitu Global Moderator @spud11
        last edited by

        @spud11 Have you made the file executable (chmod +x gridwards-armhf-rel) ? Note that you should run it via ./gridwars-armhf-rel, not with sudo bash ....

        S 1 Reply Last reply Reply Quote 0
        • S
          spud11 @mitu
          last edited by

          @mitu said in Possible to port GridWars 2:

          ./gridwars-armhf-rel

          Hi mitu. Happy New Year! Yes, I have given it the correct permissions and for good measure used the command you gave. I have also tried ./gridwars-armhf-rel, but get permission denied.

          RetroPie v4.4.1 • RPi3 Model B • 5.1V 2.5A PSU • 32GB SanDisk Extreme microSD • 2TB Toshiba Canvio Basics Portable USB 3.0 hard drive • 4 x DragonRise USB Arcade joysticks • 2 x TurboTwist spinners • 1 x USB trackball • 1 x PS4 wireless • 1 x 8BitDo Zero

          mituM 1 Reply Last reply Reply Quote 0
          • fluffypillowF
            fluffypillow
            last edited by

            Just tried the binary on an up-to-date RetroPie, and it launches fine for me, without sudo or anything. Your errors seem to show filesystem issues as @mitu said; are you trying to run the game from USB or Samba share perhaps? Have you tried a different SD card?

            As for the game, due to the GLES lib name changes on Stretch, it hangs on startup with an initialization error, then eventually crashes (patching the binary is not enough). Likely a bug in the engine itself.

            1 Reply Last reply Reply Quote 2
            • mituM
              mitu Global Moderator @spud11
              last edited by

              @spud11 I got the same behavior as @fluffypillow - the program starts, but it's not fully compatible and crashes. But it's not the same error as yours, for sure.

              1 Reply Last reply Reply Quote 1
              • cyperghostC
                cyperghost
                last edited by

                If someone is interested for Windows version.
                This link seems to be the only woking one

                You will find download link directly under first picture ;)

                T 1 Reply Last reply Reply Quote 0
                • T
                  toto2000 @cyperghost
                  last edited by

                  Up ! Can someone sum up where we are?
                  Which version did you use ?
                  I can certainly help going forward with this quest (having GW run on the pi), I'm a CS engineer...

                  fluffypillowF S 2 Replies Last reply Reply Quote 1
                  • fluffypillowF
                    fluffypillow @toto2000
                    last edited by

                    @toto2000 great! So at the moment on Debian Stretch the game doesn't start up properly, however it used to work (as in, launched) on Jessie (Wheezy?). There are quite a few issues with the engine causing crashes, you may want to run through the code with the debugger to catch them all.

                    You can get the code and my patches here, and also some build instructions. A prebuilt binary is here, the one that used to launch originally.

                    T 3 Replies Last reply Reply Quote 1
                    • S
                      spud11 @toto2000
                      last edited by

                      @toto2000 That would be great. I was unable to get the pre-built binary to work on Jessie (which I'm still on).

                      RetroPie v4.4.1 • RPi3 Model B • 5.1V 2.5A PSU • 32GB SanDisk Extreme microSD • 2TB Toshiba Canvio Basics Portable USB 3.0 hard drive • 4 x DragonRise USB Arcade joysticks • 2 x TurboTwist spinners • 1 x USB trackball • 1 x PS4 wireless • 1 x 8BitDo Zero

                      1 Reply Last reply Reply Quote 0
                      • T
                        toto2000 @fluffypillow
                        last edited by

                        @fluffypillow Ok, I already managed to recompile completely the compiler itself and maxIDE on my Mac + compile GridWars using the command line + MaxIDE. Next -> recompile all these things in the Pi. I followed your instructions + get your controls.bmx patched file (original did not compile due to a Joycon not found error)

                        Do you have an idea of what was going wrong? Problems with the OpenGL version?

                        1 Reply Last reply Reply Quote 1
                        • T
                          toto2000 @fluffypillow
                          last edited by

                          @fluffypillow Which version of the compiler did you use? This one : https://github.com/bmx-ng/bmx-ng/releases/tag/v0.81.3.16.rpi or a more recent one that you recompiled for the pi? On the Mac I used https://github.com/bmx-ng/bmx-ng/releases/tag/v0.99.3.31.macos and was wondering if I could recompile the up to date sources on the Pi, like I did on the Mac... Maybe this would maximize the chances of building a runnable GridWars..?

                          1 Reply Last reply Reply Quote 1
                          • T
                            toto2000 @fluffypillow
                            last edited by

                            @fluffypillow You have been talking about Opengles, but the REAL OpenGl should be supported on Pi (see

                            ) with the Mesa lib... I saw that you added some ? if nopt Opengles in some of the bmx files so that it compiles. Do you think that might be the problem when the game was badly running? Do you think it was slow because it did not use OpenGL hardware acceleration two years ago?

                            Look at the YT video I linked. Apparently, OpenGL hardware acceleration is still experimental in 2018 and should be turned on from raspi-config... Ok, I'm investigating, and will let you know if I find something interesting...

                            mituM 1 Reply Last reply Reply Quote 1
                            • mituM
                              mitu Global Moderator @toto2000
                              last edited by

                              @toto2000 Turning on the OpenGL driver will probably break the other RetroPie emulators, so be aware of that when testing.

                              T 2 Replies Last reply Reply Quote 1
                              • T
                                toto2000 @mitu
                                last edited by

                                @mitu Ok. I'll see what's happening then....

                                1 Reply Last reply Reply Quote 1
                                • T
                                  toto2000 @mitu
                                  last edited by

                                  @mitu The problem is that Gridwars uses the OpenGL driver that requires OpenGL 1.1 minimum. (See this line in gridwars.bmx :

                                  Framework BRL.GLMax2D
                                  

                                  If I change this to :

                                  Framework Pub.OpenGLES
                                  

                                  That is the framework supported by default by the Pi, then, many things will not compile (such as TImage not recognized etc.)

                                  So, we have to stick with the openGL driver. And if it's not hardware accelerated, then the Mesa OpenGL software implementation is certainly the one being used, that for sure will make the game unplayable.
                                  My goal is to 1) recompile blitzmax tools (not use the old precompiled binary) 2) compile GridWars 3) try with the experimental hardware accelerated driver.

                                  I'll keep you informed...

                                  fluffypillowF 1 Reply Last reply Reply Quote 1
                                  • fluffypillowF
                                    fluffypillow @toto2000
                                    last edited by

                                    @toto2000

                                    Which version of the compiler did you use? This one : https://github.com/bmx-ng/bmx-ng/releases/tag/v0.81.3.16.rpi or a more recent one that you recompiled for the pi?

                                    Yes, I've used that for the on-the-Pi builds. It used to be "just a few days old" back when I've compiled the game first; a newer version would certainly have more chance for success.

                                    Problems with the OpenGL version?
                                    Do you think it was slow because it did not use OpenGL hardware acceleration two years ago?

                                    Yes, there are several places where desktop OpenGL calls are used for effects. As a workaround I've disabled them, but that didn't help with the rest of the crashes unfortunately. If I remember correctly there wasn't proper Mesa support back then, so trying it out now would be an interesting experiment.

                                    1 Reply Last reply Reply Quote 1
                                    • cyperghostC
                                      cyperghost
                                      last edited by cyperghost

                                      @toto2000
                                      Maybe this can help
                                      https://github.com/ptitSeb/gl4es
                                      This made OpenBOR 6xxx branch run on Raspberry.

                                      1 Reply Last reply Reply Quote 0
                                      • T
                                        toto2000
                                        last edited by

                                        Thanks, I will give it a try... I'll certainly have time tomorrow....

                                        1 Reply Last reply Reply Quote 0
                                        • T
                                          toto2000
                                          last edited by

                                          Ok, here is where I am:

                                          • I compiled the last blitzmax-ng Linux distrib, bcc and bmx built fine, but it crashed during the compilation of makedocs.bmx with a -m32 error. However all useful commands for compiling were built ok.

                                          • I tried to compile the original sources of GridWars, but it failed due to some errors in images.bmx (type timage not found) and utils.bmx (plot not found)

                                          • I then compiled https://github.com/ptitSeb/gl4es, added <gl4es_dir>/lib/libGL.so.1 to my LD_LIBRARY_PATH, tried to recompile without success (this lib is for linking normally)

                                          • Then I went back to compiling the patched version from @fluffypillow that I think was modified to use SDL instead of OpenGL and I followed his instructions for compiling. It worked (I did not have to add -LEGL at the end, maybe I should have done this?)

                                          • I tried to run this version -> it displays "GL2 (with shaders) Active", then it does a Segmentation fault

                                          I will try again to compile the original version. If you have suggestions, you're welcome :-)

                                          cyperghostC fluffypillowF 2 Replies Last reply Reply Quote 1
                                          • cyperghostC
                                            cyperghost @toto2000
                                            last edited by

                                            @toto2000 not sure but I think lGL switch can be used with gl4es

                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post

                                            Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

                                            Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.