H-Craft Championship Open Source

Announce new projects or updates of Irrlicht Engine related tools, games, and applications.
Also check the Wiki
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

H-Craft Championship Open Source

Post by CuteAlien »

Hi everyone!

As some already knew I've been working on open-sourcing our Sci-Fi racer H-Craft Championship for a while.
The game uses Irrlicht (obviously) - and runs on Windows, Linux and Android.
The license is zlib, same as in Irrlicht, so you can use all the code in your own games!
Note that the media-files (textures and music) are restricted to private use.

All infos about it can be found on this page: http://www.irrgheist.com/hcraftsource.htm

Any questions about the sources, please use this thread.

I hope it will be of some use to you - have fun playing with the sources.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Nadro
Posts: 1648
Joined: Sun Feb 19, 2006 9:08 am
Location: Warsaw, Poland

Re: H-Craft Championship Open Source

Post by Nadro »

Congratulations Michael, You've done a great work! Source code of this game should be helpful for a lot of developers. IMHO it's one of the best open source game. Zlib license is also an advantage :)
Library helping with network requests, tasks management, logger etc in desktop and mobile apps: https://github.com/GrupaPracuj/hermes
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Re: H-Craft Championship Open Source

Post by christianclavet »

Thanks CuteAlien!
polylux
Posts: 267
Joined: Thu Aug 27, 2009 12:39 pm
Location: EU

Re: H-Craft Championship Open Source

Post by polylux »

Nice move, CuteAlien! :)
By the way, browsing the code can be quite entertaining.

Code: Select all

int GhostRecordSettings::CalcChecksum()
{
    // Man - how I hate it to get back to years old code and all I find is a stupid comment like that *sigh*
    // I guess I just used 2 random numbers.
    return ((mGhostType + mTime) * 3771) | 4711; // this cryptographic formula will definitly revolutionize the world!!!
}
I totally know what you mean in the first two comment lines ;)
beer->setMotivationCallback(this);
hendu
Posts: 2600
Joined: Sat Dec 18, 2010 12:53 pm

Re: H-Craft Championship Open Source

Post by hendu »

Not even primes, I expect better :P
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: H-Craft Championship Open Source

Post by CuteAlien »

Pfff, every cryptographer can use primes - where's the revolution in that ;-)
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
kas1e
Posts: 212
Joined: Sun Jan 21, 2018 8:39 am

Re: H-Craft Championship Open Source

Post by kas1e »

@CuteAlien
Oh what a surprise that you are author of H-Craft !

Trying to port it to amigaos4 now, but firstly want to make latest sources works for win32/mingw (so to understand how all done and how all should be , etc).

And for now fighting for good few hours with latest sources & media from the repo , and all the time on running i have that:

Code: Select all

 
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_rotorwind.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_rotorwind.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_rotorwind.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_hc_fx_teleport.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_hc_fx_teleport.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_hc_fx_teleport.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_hc_fx_teleport.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_hc_fx_teleport.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_hc_fx_teleport.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_blobshadow01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_blobshadow01.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_blobshadow01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Could not load texture: D:/msys64/work/hcraft_test/media/textures/ALPHA_race_shipstream01.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/ui/selectH1.tga
Unsupported TGA format: D:/msys64/work/hcraft_test/media/ui/selectH1.tga
Could not load texture: D:/msys64/work/hcraft_test/media/ui/selectH1.tga
 
The released binary version for win32 does not have that issue of course. Everything works there.

I even tried to get the media data from binary-release (where they 100% ok) : and still same issue.

I checked, and that message come from Irrlicht itself. So question is : can it be that Irrlicht in H-Craft repo was updated , but wasn't tested with latest h-craft sources, or , its just me doing something wrong there ?:)

Its all looks like or i just build irrlicht which come with h-craft somehow wrong (but then, what can be wrong there), or something else happens ..

Maybe you have an idea about ..

Thanks !
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: H-Craft Championship Open Source

Post by CuteAlien »

Very sorry, I haven't compiled that in a long time :-( Considered it recently when I found out that it no longer runs on Debian 10, but every time I pause a few years things no longer work when coming back *sigh* (and always enough tasks to work on...).Will have to test myself. But the Irrlicht in the repository should have been tested in the past... I think.

Maybe different gcc/g++ version messing up things again. My first guess was that my Irrlicht version there is so old it doesn't have yet the fix for the struct packing changes which were needed for gcc 4.7 on MinGW. That could have messed up the loading of the magic-key in tga files. But looking at the changes.txt in there it should already be in there.

*sigh* there isn't even a good reason to have tga files, we just didn't have enough experience when we started out. Could use png's instead.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: H-Craft Championship Open Source

Post by CuteAlien »

One hint - there is a file build.txt in the doc folder.

I just did a quick test on Linux. I got compile-errors on first test (in Irrlicht I needed -Wno-narrowing to avoid some errors).
And I had to clean and rebuild H-Craft once as it failed on first try (but likely because I still had .obj files around from older g++ from before my recent system update). But works now without troubles - including loading those .tga's.
So I guess a MinGW problem.

Which g++ version are you running?
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
kas1e
Posts: 212
Joined: Sun Jan 21, 2018 8:39 am

Re: H-Craft Championship Open Source

Post by kas1e »

@CuteAlien
One hint - there is a file build.txt in the doc folder.
Yeah i read it all, but as i have no codeblocks, i just build all manually. I just go to lib/irrlicht/source/Irrlicht , and do "make win32 NDEBUG=1".

Then , i compile all the H-Craft objects manually, just like this:

Code: Select all

 
cd src/
mkdir objs
 
 
gcc -I/mingw32/include/freetype2/ -I../libs/irrlicht/include -c -O2 CGUITTFont.cpp -o objs/CGUITTFont.obj
gcc -I../libs/irrlicht/include -c -O2 CGUITextSlider.cpp -o objs/CGUITextSlider.obj
gcc -I../libs/irrlicht/include -c -O2 CLMOMeshFileLoader.cpp -o objs/CLMOMeshFileLoader.obj
gcc -I../libs/irrlicht/include -c -O2 ai_track.cpp -o objs/ai_track.obj
gcc -I../libs/irrlicht/include -c -O2 app_tester.cpp -o objs/app_tester.obj
gcc -I../libs/irrlicht/include -c -O2 camera.cpp -o objs/camera.obj
gcc -I../libs/irrlicht/include -c -O2 championship.cpp -o objs/championship.obj
gcc -I../libs/irrlicht/include -c -O2 config.cpp -o objs/config.obj
gcc -I../libs/irrlicht/include -c -O2 controller.cpp -o objs/controller.obj
gcc -I../libs/irrlicht/include -c -O2 convert_utf.c -o objs/convert_utf.obj
gcc -I../libs/irrlicht/include -c -O2 device_joystick.cpp -o objs/device_joystick.obj
gcc -I../libs/irrlicht/include -c -O2 device_joystick_settings.cpp -o objs/device_joystick_settings.obj
gcc -I../libs/irrlicht/include -c -O2 device_keyboard.cpp -o objs/device_keyboard.obj
gcc -I../libs/irrlicht/include -c -O2 device_mouse.cpp -o objs/device_mouse.obj
gcc -I../libs/irrlicht/include -c -O2 device_touch.cpp -o objs/device_touch.obj
gcc -I../libs/irrlicht/include -c -O2 device_touch_settings.cpp -o objs/device_touch_settings.obj
gcc -I../libs/irrlicht/include -c -O2 editor.cpp -o objs/editor.obj
gcc -I../libs/irrlicht/include -c -O2 event_receiver_base.cpp -o objs/event_receiver_base.obj
gcc -I/mingw32/include/freetype2/ -I../libs/irrlicht/include -c -O2 font_manager.cpp -o objs/font_manager.obj
gcc -I../libs/irrlicht/include -c -O2 game.cpp -o objs/game.obj
gcc -I../libs/irrlicht/include -c -O2 grid_triangle_selector.cpp -o objs/grid_triangle_selector.obj
gcc -I../libs/irrlicht/include -c -O2 gui.cpp -o objs/gui.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialog.cpp -o objs/gui_dialog.obj
gcc -I../libs/irrlicht/include -c -O2 helper_file.cpp -o objs/helper_file.obj
gcc -I../libs/irrlicht/include -c -O2 helper_irr.cpp -o objs/helper_irr.obj
gcc -I../libs/irrlicht/include -c -O2 helper_math.cpp -o objs/helper_math.obj
gcc -I../libs/irrlicht/include -c -O2 helper_str.cpp -o objs/helper_str.obj
gcc -I../libs/irrlicht/include -c -O2 helper_xml.cpp -o objs/helper_xml.obj
gcc -I../libs/irrlicht/include -c -O2 highscores.cpp -o objs/highscores.obj
gcc -I../libs/irrlicht/include -c -O2 hover.cpp -o objs/hover.obj
gcc -I../libs/irrlicht/include -c -O2 input_device.cpp -o objs/input_device.obj
gcc -I../libs/irrlicht/include -c -O2 input_device_manager.cpp -o objs/input_device_manager.obj
gcc -I../libs/irrlicht/include -c -O2 irrlicht_manager.cpp -o objs/irrlicht_manager.obj
gcc -I../libs/irrlicht/include -c -O2 keycode_strings.cpp -o objs/keycode_strings.obj
gcc -I../libs/irrlicht/include -c -O2 level.cpp -o objs/level.obj
gcc -I../libs/irrlicht/include -c -O2 level_manager.cpp -o objs/level_manager.obj
gcc -I../libs/irrlicht/include -c -O2 logging.cpp -o objs/logging.obj
gcc -I../libs/irrlicht/include -c -O2 main.cpp -o objs/main.obj
gcc -I../libs/irrlicht/include -c -O2 mesh_texture_loader.cpp -o objs/mesh_texture_loader.obj
gcc -I../libs/irrlicht/include -c -O2 music_manager.cpp -o objs/music_manager.obj
gcc -I../libs/irrlicht/include -c -O2 nn.cpp -o objs/nn.obj
gcc -I../libs/irrlicht/include -c -O2 node_manager.cpp -o objs/node_manager.obj
gcc -I../libs/irrlicht/include -c -O2 ogg_stream.cpp -o objs/ogg_stream.obj
gcc -I../libs/irrlicht/include -c -O2 ogles2_materials.cpp -o objs/ogles2_materials.obj
gcc -I../libs/irrlicht/include -c -O2 ov_callbacks.cpp -o objs/ov_callbacks.obj
gcc -I../libs/irrlicht/include -c -O2 physics.cpp -o objs/physics.obj
gcc -I../libs/irrlicht/include -c -O2 player.cpp -o objs/player.obj
gcc -I../libs/irrlicht/include -c -O2 profiles.cpp -o objs/profiles.obj
gcc -I../libs/irrlicht/include -c -O2 random.cpp -o objs/random.obj
gcc -I../libs/irrlicht/include -c -O2 recorder.cpp -o objs/recorder.obj
gcc -I../libs/irrlicht/include -c -O2 rivalsmode.cpp -o objs/rivalsmode.obj
gcc -I../libs/irrlicht/include -c -O2 sound_openal.cpp -o objs/sound_openal.obj
gcc -I../libs/irrlicht/include -c -O2 sound_settings.cpp -o objs/sound_settings.obj
gcc -I../libs/irrlicht/include -c -O2 start_browser.cpp -o objs/start_browser.obj
gcc -I../libs/irrlicht/include -c -O2 streaming.cpp -o objs/streaming.obj
gcc -I../libs/irrlicht/include -c -O2 string_table.cpp -o objs/string_table.obj
gcc -I../libs/irrlicht/include -c -O2 timer.cpp -o objs/timer.obj
gcc -I../libs/irrlicht/include -c -O2 track_marker.cpp -o objs/track_marker.obj
 
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_ai.cpp -o objs/gui_ai.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_controller_display.cpp -o objs/gui_controller_display.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_developer_settings.cpp -o objs/gui_developer_settings.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_dlg_okcancel.cpp -o objs/gui_dlg_okcancel.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_editor.cpp -o objs/gui_editor.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_game.cpp -o objs/gui_game.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_helper.cpp -o objs/gui_helper.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_hud.cpp -o objs/gui_hud.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_intro.cpp -o objs/gui_intro.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_levelmanager.cpp -o objs/gui_levelmanager.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_analog.cpp -o objs/gui_menu_analog.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_arcade.cpp -o objs/gui_menu_arcade.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_championship.cpp -o objs/gui_menu_championship.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_championship_progress.cpp -o objs/gui_menu_championship_progress.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_championship_winner.cpp -o objs/gui_menu_championship_winner.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_controls.cpp -o objs/gui_menu_controls.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_credits.cpp -o objs/gui_menu_credits.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_gameend.cpp -o objs/gui_menu_gameend.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_gameend_champ.cpp -o objs/gui_menu_gameend_champ.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_gameend_rivals.cpp -o objs/gui_menu_gameend_rivals.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_graphics.cpp -o objs/gui_menu_graphics.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_highscores.cpp -o objs/gui_menu_highscores.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_hover_unlocked.cpp -o objs/gui_menu_hover_unlocked.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_keyboard.cpp -o objs/gui_menu_keyboard.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_licenses.cpp -o objs/gui_menu_licenses.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_loadingscreen.cpp -o objs/gui_menu_loadingscreen.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_main.cpp -o objs/gui_menu_main.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_nagscreen.cpp -o objs/gui_menu_nagscreen.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_newprofile.cpp -o objs/gui_menu_newprofile.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_options.cpp -o objs/gui_menu_options.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_pause.cpp -o objs/gui_menu_pause.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_profiles.cpp -o objs/gui_menu_profiles.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_replaytheatre.cpp -o objs/gui_menu_replaytheatre.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_rivals.cpp -o objs/gui_menu_rivals.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_rivals_score.cpp -o objs/gui_menu_rivals_score.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_selecthover.cpp -o objs/gui_menu_selecthover.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_timeattack.cpp -o objs/gui_menu_timeattack.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_menu_tutorial3.cpp -o objs/gui_menu_tutorial3.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_modellist.cpp -o objs/gui_modellist.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_nodemanager.cpp -o objs/gui_nodemanager.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_touch.cpp -o objs/gui_touch.obj
gcc -I../libs/irrlicht/include -c -O2 gui_dialogs/gui_user_controls.cpp -o objs/gui_user_controls.obj
 
gcc -I../libs/irrlicht/include -c -O2 mobile/advert_admob.cpp -o objs/advert_admob.obj
gcc -I../libs/irrlicht/include -c -O2 mobile/android_tools.cpp -o objs/android_tools.obj
gcc -I../libs/irrlicht/include -c -O2 mobile/app_restrictions.cpp -o objs/app_restrictions.obj
gcc -I../libs/irrlicht/include -c -O2 mobile/billing_googleplay.cpp -o objs/billing_googleplay.obj
 
gcc -I../libs/irrlicht/include -c -O2 tinyxml/tinystr.cpp -o objs/tinystr.obj
gcc -I../libs/irrlicht/include -c -O2 tinyxml/tinyxml.cpp -o objs/tinyxml.obj
gcc -I../libs/irrlicht/include -c -O2 tinyxml/tinyxmlerror.cpp -o objs/tinyxmlerror.obj
gcc -I../libs/irrlicht/include -c -O2 tinyxml/tinyxmlparser.cpp -o objs/tinyxmlparser.obj
 
Then for linking just:

Code: Select all

 
g++ -o hcraft \
objs/CGUITTFont.obj objs/CGUITextSlider.obj objs/CLMOMeshFileLoader.obj objs/ai_track.obj objs/app_tester.obj objs/camera.obj objs/championship.obj objs/config.obj objs/controller.obj objs/convert_utf.obj \
objs/device_joystick.obj objs/device_joystick_settings.obj objs/device_keyboard.obj objs/device_mouse.obj objs/device_touch.obj objs/device_touch_settings.obj objs/editor.obj objs/event_receiver_base.obj \
objs/font_manager.obj objs/game.obj objs/grid_triangle_selector.obj objs/gui.obj objs/gui_dialog.obj objs/helper_file.obj objs/helper_irr.obj objs/helper_math.obj objs/helper_str.obj objs/helper_xml.obj \
objs/highscores.obj objs/hover.obj objs/input_device.obj objs/input_device_manager.obj objs/irrlicht_manager.obj objs/keycode_strings.obj objs/level.obj objs/level_manager.obj objs/logging.obj objs/main.obj \
objs/mesh_texture_loader.obj objs/music_manager.obj objs/nn.obj objs/node_manager.obj objs/ogg_stream.obj objs/ogles2_materials.obj objs/ov_callbacks.obj objs/physics.obj objs/player.obj objs/profiles.obj \
objs/random.obj objs/recorder.obj objs/rivalsmode.obj objs/sound_openal.obj objs/sound_settings.obj objs/start_browser.obj objs/streaming.obj objs/string_table.obj objs/timer.obj objs/track_marker.obj \
objs/gui_ai.obj objs/gui_controller_display.obj objs/gui_developer_settings.obj objs/gui_dlg_okcancel.obj objs/gui_editor.obj objs/gui_game.obj objs/gui_helper.obj objs/gui_hud.obj objs/gui_intro.obj \
objs/gui_levelmanager.obj objs/gui_menu_analog.obj objs/gui_menu_arcade.obj objs/gui_menu_championship.obj objs/gui_menu_championship_progress.obj objs/gui_menu_championship_winner.obj objs/gui_menu_controls.obj \
objs/gui_menu_credits.obj objs/gui_menu_gameend.obj objs/gui_menu_gameend_champ.obj objs/gui_menu_gameend_rivals.obj objs/gui_menu_graphics.obj objs/gui_menu_highscores.obj objs/gui_menu_hover_unlocked.obj \
objs/gui_menu_keyboard.obj objs/gui_menu_licenses.obj objs/gui_menu_loadingscreen.obj objs/gui_menu_main.obj objs/gui_menu_nagscreen.obj objs/gui_menu_newprofile.obj objs/gui_menu_options.obj objs/gui_menu_pause.obj \
objs/gui_menu_profiles.obj objs/gui_menu_replaytheatre.obj objs/gui_menu_rivals.obj objs/gui_menu_rivals_score.obj objs/gui_menu_selecthover.obj objs/gui_menu_timeattack.obj objs/gui_menu_tutorial3.obj \
objs/gui_modellist.obj objs/gui_nodemanager.obj objs/gui_touch.obj objs/gui_user_controls.obj objs/advert_admob.obj objs/android_tools.obj objs/app_restrictions.obj objs/billing_googleplay.obj \
objs/tinystr.obj objs/tinyxml.obj objs/tinyxmlerror.obj objs/tinyxmlparser.obj ../libs/irrlicht/lib/Win32-gcc/libIrrlicht.a  -lSDL -lopenal -lalut  -lvorbisfile -lvorbis -logg -lfreetype -lopengl32
 
Maybe the way i do it broke something.. Maybe some missing gcc optimisation should be in place as well to make loading of tga works ? But i tried it also to build everything as done in *.cbp : i.e. with those flags:

Code: Select all

 
 -march=i686 -fexpensive-optimizations -O3 -Wall -W -fno-strict-aliasing -Wno-unused -DNDEBUG -D__GNUWIN32__ -DWIN32 -DHOVER_RELEASE 
 
But issue still there :(
I got compile-errors on first test (in Irrlicht I needed -Wno-narrowing to avoid some errors).
Yeah, i have them too and fix it the same. That error happens for aesGladman/sha2.cpp (seems was changed since 1.8.4, at least sha2.h for sure have different size).
Which g++ version are you running?
My gcc is i686-w64-mingw32 7.3.0
*sigh* there isn't even a good reason to have tga files, we just didn't have enough experience when we started out. Could use png's instead.
I can try to just manually convert all the .tga inside of media directory to .png . Or there is some code in h-craft which want to deal with tga somehow instead of handling via irrlicht ? I mean, maybe it will just works once conver tga to pngs ?

Will try to rebuild everything from scratch again just in case
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: H-Craft Championship Open Source

Post by CuteAlien »

You could install Code::Blocks for a quick test. It's free and open-source. Although except for other compile-flags it should not make a difference as C::B also uses the installed g++ compiler. But should be quick to do (install and then click compile on 2 project files).

Just replacing tga by png is likely not working, you would also have to replace the filenames in the models which try to load the texture. Or maybe not - could be I even try loading same file with other file-endings (I remember I did something like that once for some reason... not sure if that's still in there).
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
kas1e
Posts: 212
Joined: Sun Jan 21, 2018 8:39 am

Re: H-Craft Championship Open Source

Post by kas1e »

You could install Code::Blocks for a quick test. It's free and open-source. Although except for other compile-flags it should not make a difference as C::B also uses the installed g++ compiler. But should be quick to do (install and then click compile on 2 project files).
Will try now
Just replacing tga by png is likely not working, you would also have to replace the filenames in the models which try to load the texture. Or maybe not - could be I even try loading same file with other file-endings (I remember I did something like that once for some reason... not sure if that's still in there).
I just tried to convert ALPHA_race_shipstream01.tga to ALPHA_race_shipstream01.png, and replace in all .mtl files all instances of ALPHA_race_shipstream01.tga on ALPHA_race_shipstream01.png : it even didn't go futher profiling call , even didn't see that irrlich started , and then crashes :) So probabaly something in code exactly .tga is need it.
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: H-Craft Championship Open Source

Post by CuteAlien »

I just realize I use MinGW32. Could be I never tried to create a 64-bit version on Windows (I use 64-bit on Linux, but on Windows there was was no problem just keeping it with 32-bit, so I never changed that).
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
CuteAlien
Admin
Posts: 9628
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: H-Craft Championship Open Source

Post by CuteAlien »

Setting up a sane 64-bit environment for MinGW seems to be a bit more work (first test I ended up without a working debugger, but likely just because I still used an old installation). But at least I could test one thing - when I get current Irrlicht + Examples compiled in 64 bit there I can still load the TGA files from H-Craft.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
kas1e
Posts: 212
Joined: Sun Jan 21, 2018 8:39 am

Re: H-Craft Championship Open Source

Post by kas1e »

@Cutealien
My mingw also 32bit one (i686-w64-mingw32) , so that ok then

I also installed code::blocks, and rebuild fresh version of h-craft's irrlicht and h-craft itself : still same issue.

Then, made some experiments, and found, that once i use irrlicht.dll from the archive coming with original hcraft win32 version release, all works fine. Once i use one builded from latest sources : that error.

I.e. i even can use my own hovercraft.exe builded, just with irrlicht.dll from win32 binary release : and all works. Once i use that one which i build from latest repo , then have that error.

My bet, that maybe for you it also should fail, just somewhere in the system you have "right" libirrlicht.dll placed.

My windows binary version from where i got working libirrlicht.dll are hcraft_v1_3b.zip

In other words, the fault at moment seems are build of repo's irrlicht (at least on my side currently).

Just to be sure that we use the same, i downloaded both source and media files from there:

https://bitbucket.org/mzeilfelder/trunk_hc1
https://bitbucket.org/mzeilfelder/media_hc1

And in source one i download not any branch or tags, but just "trunk repository", so the last code i assume.

In meantime i tried to build latest irrlicht.dll from current trunk sources, but sadly to say i can't use it with hcraft, it says "entry point into _ZdaPvj not found in irrlicht.dll".

Interesting what can cause irrlicht didn't builds as expected.. I even choice exactly the same target as in build.txt writen : Win32 Release - accurate math - dll. It just looks like that something is can be broken in irrlicht's code in the h-craft repo about tgas (which maybe was fixed in latest irrlicht, but then i can't use latest irrlicht with hcraft - maybe need to try to build static version of it..)
Post Reply