Results 1 to 10 of 37

Thread: PGD Challenge in the Winter?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Quote Originally Posted by SilverWarior View Post
    Making game to be able to run on multiple platforms isn't easy especially if you don't have sufficient expirience with target platform. While windows is still most popular platform on PC computers this is no guarantee that all of us have suficient expirience with it even due the fact that probably all of us used Windows at some point. But if someone is using MAC OS for the last 5 yers it will have a lot of troubles making game to run smothly on Windows due to qute some changes in Windows architercture (changed various paths, lots of changes in acces premisons etc.). Same will go for me if I would try to make my game runable on MAC OS or Linux becouse I have no expirience with MAC OS and verry litle expirience with Linux.
    It's not that difficult when you are making apps with Lazarus Simplest requirement is not to include Windows in the uses list. Second is converting all paths to fit operating system. For this there is a internal constant PathDelim, which is \ or / depending on OS. But also you can get tips from nxPascal FixPath() function

    That should be all there is to crossplatform. Use OpenGL, not DirectX. Some differences with dll libraries, but that's a problem outside of compiled executable.

  2. #2
    Quote Originally Posted by User137 View Post
    It's not that difficult when you are making apps with Lazarus Simplest requirement is not to include Windows in the uses list. Second is converting all paths to fit operating system. For this there is a internal constant PathDelim, which is \ or / depending on OS. But also you can get tips from nxPascal FixPath() function

    That should be all there is to crossplatform. Use OpenGL, not DirectX. Some differences with dll libraries, but that's a problem outside of compiled executable.
    Actually, this is much easier to say than to do. In reality, when you have worked on Windows platform for too long, it *is* difficult porting to other platforms. OpenGL is nice, but its initialization differs (unless you use GLUT or similar helpers, which have its own problems - for one, they are not readily available on Windows and are outdated). Sockets (anything beyond trivial) are considerably different due to WinSock specifics. Other helpers such as temporary path folders, registry configuration, dynamic libraries, etc. all all different too.

    Also, you need to be very careful with the code you write to keep it portable.

    To resume, for some very basic or crippled games/applications that will work and look poorly on all platforms - sure, it is relatively easy to acomplish, but as soon as you start working on features beyond trivial you *have* to start using platform-specific routes, which makes the code considerably more complex by adding many different code paths. Just take a look at actual LCL source code to see the real scope of a cross-platform project.

    However, it is still a good idea to pursue multi-platform PGD challange and it will help people to work out issues in their code. Making and running your applications on different platforms is an ultimate challenge for writing applications, that requires discipline and experience to make proper architectural decisions.

  3. #3
    Or you could write it using Oxygene for Java and it will run on Windows, Linux, and Mac OSX if Java is installed LOL

  4. #4
    Quote Originally Posted by paul_nicholls View Post
    Or you could write it using Oxygene for Java and it will run on Windows, Linux, and Mac OSX if Java is installed LOL
    Similarly, you could write it in Delphi Prism, or alternatively in Embarcadero HTML5 Builder and it will in any HTML5-based browser, even on Android.

  5. #5
    Quote Originally Posted by Lifepower View Post
    Similarly, you could write it in Delphi Prism, or alternatively in Embarcadero HTML5 Builder and it will in any HTML5-based browser, even on Android.
    Or Smart Mobile Studio as HTML5 application too

  6. #6
    Co-Founder / PGD Elder WILL's Avatar
    Join Date
    Apr 2003
    Location
    Canada
    Posts
    6,107
    Blog Entries
    25
    Quote Originally Posted by paul_nicholls View Post
    Or you could write it using Oxygene for Java and it will run on Windows, Linux, and Mac OSX if Java is installed LOL
    I think you still need to get Platformation working on all 3 platforms though don't you Paul?
    Jason McMillen
    Pascal Game Development
    Co-Founder





  7. #7
    Quote Originally Posted by WILL View Post
    I think you still need to get Platformation working on all 3 platforms though don't you Paul?
    LOL yes
    I tried Platformation in the latest Oxygene for Java, and I am having to change a bunch of things due to compiler changes...so that hasn't happened yet

  8. #8
    Co-Founder / PGD Elder WILL's Avatar
    Join Date
    Apr 2003
    Location
    Canada
    Posts
    6,107
    Blog Entries
    25
    Quote Originally Posted by User137 View Post
    It's not that difficult when you are making apps with Lazarus Simplest requirement is not to include Windows in the uses list. Second is converting all paths to fit operating system. For this there is a internal constant PathDelim, which is \ or / depending on OS. But also you can get tips from nxPascal FixPath() function

    That should be all there is to crossplatform. Use OpenGL, not DirectX. Some differences with dll libraries, but that's a problem outside of compiled executable.
    From personal experience (I develop on a Mac exclusively now.) setting up your project from Windows to a Mac takes a lot of IFDEFs or a separate unit to handle resource paths (like what I use now) and some extra configuration in the Project Options to account for multiple platform compilation and bundling. It's not impossible or so complicated that it's barely doable without a rocket scientist degree, but it is a wee bit involved (you need to know Lazarus well!) and you might need some extra guidance from someone that has done it themselves often enough before.

    It took me a good month or so to get Lazarus working for me on my Mac and to convert some of my projects so that they'll compile and run in the IDE and debug properly.

    Sadly with the removal of X11 as standard in the latest version of Mac OS X (Mountain Lion) you now require a 3rd party (open source) project version of X11 for Mac to run my games. I still haven't weeded out X11 linking from my projects yet it seems. I have yet to figure it out.

    So there is a lot of know-how involved when developing across platforms...
    Jason McMillen
    Pascal Game Development
    Co-Founder





Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •