Game settings / launcher

Hello,

New version (7-1-2019)

  • a ready to go fully working setup

I have been creating a game launcher with settings that saves into an .ini setup.
this version has check-boxes and lists to skip through.

And here is a video to see it in action:

The .blends have comments that you need to read.

Once you are done with building the launcher to your likings. You create a .exe from it.
Now you place the ‘game’ folder and the settings.ini in that same folder where you created the .exe.

Your launcher is ready to go now.

Open ‘game’ folder and open ‘your_game.blend’ this blend is now your game. So create a game in it
and use the launcher to start your game with those settings(or alter the scripts and use your own blend file(s)).

Your game folder structure should look like(default .exe structure):

/game_name/
	- /2.79/ <-folder
	- /game/ <-folder
	- game launcher.exe
	- settings.ini
	- .dll files

game_launcher.blend holds the script to alter the .blend launched + settings
your_game.blend in ‘game’ folder holds the load settings part(filters are not included!)

You can test this launcher by opening game_launcher.blend(recommended at first try) or your_game.blend
Change the settings through the launcher.

game_launcher_by_cotaks.zip (166.4 KB)

Have fun with it!

Cotaks

5 Likes

Fixed a very tiny/small/noobie mistake/bug in the load settings script at #1 post.

Changed

parser.read(logic.expandPath('//settings/') + "settings.ini")

Into

parser.read(logic.expandPath('//') + "settings.ini")

As i stated in #1 post, you should place the script in the same folder as the .blend file, but that would never work due to the script was looking for the settings a directory deeper.

Sorry just noticed it, and you guys didn’t complain so… it should be fine. :wink:

Hello Cotaks. You know me already from previus posts. My problem here is that I cant load the settings.ini in the game. I can change the settings and save them in the settings file. ini but I dont know how to load the file in the game.

Create an empty in the blend where you want to load the settings.
if you use filters, put a property for each filter on the empty (boolean).
connect a property brick (if equal to the right property) - and - add custom filter, for each filter you use.

now you have set the filters.

now add always - python, connect it to the script (only have to run once)
now you loading the settings.

that’s all there is to do to load the settings.

#edit
Added a screenshot with the right setup to load the settings.

have fun with it.

Perfect, good job man!

this is nice work man

Nice work!
I’m developing a launcher and configuration utility for BGE as well, but it runs as standalone (coded entirely in Python) and runs blenderplayer through command line, with the desired settings. It supports custom icon (on Windows), splash screen and most of the video settings on BGE. The user don’t need to configure the game to suport the launcher, only need to configure the launcher to run the game. But I didn’t released it (in this forum), as I think it should be a bit more mature for use. It’s available to download on Github, though.
See how it works at:

1 Like

Perfect, good job man!

this is nice work man

Nice work!

Thanks!

I’m developing a launcher and configuration utility for BGE as well, but it runs as standalone (coded entirely in Python) and runs blenderplayer through command line, with the desired settings. It supports custom icon (on Windows), splash screen and most of the video settings on BGE. The user don’t need to configure the game to suport the launcher, only need to configure the launcher to run the game. But I didn’t released it (in this forum), as I think it should be a bit more mature for use. It’s available to download on Github, though.
See how it works at:

  1. great to so more people creating launchers.
  2. why in python? and not in C? if you make a standalone you should have made it in C.
  3. ‘The user don’t need to configure the game to suport the launcher, only need to configure the launcher to run the game’ so how does blender load the settings, if you only adjust the launcher, blender needs to get the data someway.
  4. why promote your stuff in my topic?, make your own.
  1. I do use Pyinstaller, which freezes Python scripts and Python binaries into a executable.
  2. As I said, it runs blenderplayer through command line… Run in the command line “blenderplayer -h” and you’ll see command line arguments to use (e.g: “blenderplayer.exe -w 800 600 blendfile.blend” will run blendfile.blend in blenderplayer in windowed mode in 800x600).
  3. I’m sorry, I didn’t wanted to promote my project, only show it to you… As I said, my project isn’t in a mature state, so I didn’t made any official annoucement. If you want, I can delete my post, only ask me.

I wanna make turn on and turn off this option in your launcher but how?


I’m sorry, I didn’t wanted to promote my project, only show it to you… As I said, my project isn’t in a mature state, so I didn’t made any official annoucement. If you want, I can delete my post, only ask me.

Not needed i’m not tat bad haha, it’s about " It’s available to download on Github, though." makes it a promotion, i don’t care if people use yours or mine, i really don’t. But i just don’t like people to promote their own stuff in an other persons topic without asking.

Run in the command line

Ah sorry, my bad, didn’t pay enough attention xD

I wanna make turn on and turn off this option in your launcher but how?

You need to point me into the right direction, seems i cant find that option.

This option is in Texture tap in UPBGE when you select “Environment Map” then “Realtime” and as in my screenshot :wink:

Sorry, i am not giving support to UPbge, simply because i don’t work with it, but you should be able to mouse over it and read out it’s python command, or make a new thread for it.

Okay, thanks!

Thanks for quick support
yahoo mail login

Perfect, good job man!

New version (7-1-2019)

  • a ready to go fully working setup
1 Like

Thanks very much bro :+1:

1 Like