List of commits:
Subject Hash Author Date (UTC)
Work on particle light and bump version to v0.6.5 73b7b68133f7767f78c47492f693c5e9e965e214 mse 2021-11-19 08:04:32
Improve rim lighting and flatten floor gibs 4a7082e02eda370dba12bb44089777552859c5bd mse 2021-11-18 04:30:05
Change rim lighting to specular 937d99bee19b936fbf95927c5877a915c4128de1 mse 2021-11-18 03:49:41
Add sprite rim lighting eb9ade21b6253e050d6962c273187f090c20ff2a mse 2021-11-18 01:29:22
Bump version to v0.6.4 c2aeae76122cc95d03756a55a528b62609762820 mse 2021-11-17 11:38:37
Attempt to fix JSON serializing in locales with commas beae8b63fb0deaaf0b66ef4f188df270120ebe1c mse 2021-11-17 11:19:18
Limit network settings to network-enabled builds 8ccef75176b9059a45afa9ea251c313be7b7cfe0 mse 2021-11-17 09:20:56
Add /fps console command 207ef051937c91f78dae3928ef004ee7aa7f2a7a mse 2021-11-16 21:33:32
Move userdata to game root directory f9bff9bb941b714e7c0987327804175d852b470b mse 2021-11-16 02:55:04
Add --savehere flag and bump version to v0.6.3 a59633113908903af57e4e1c62008fe154d4cbb7 mse 2021-11-16 02:12:25
Disable networking and remove dead code aaa8bd8300f89099bace4ee1de374d05dff2c089 mse 2021-11-15 05:17:06
Update gamecontrollerdb 828ce88dd2107d69b6332b9768f7c556473b8a24 mse 2021-11-14 00:29:26
Bump version to 0.6.2 baa2215230b5deed37b69f4075bd3b3385dbb913 mse 2021-11-14 00:08:13
Fix controller menu selection 3a1567ae279289d72058d6aa23d0c4eb147db2a8 mse 2021-11-13 23:00:12
Chinese translations for confec-select and name-your-confec 6c5c9d0fadb17066af82d459d1d46868af0e9faa mse 2021-11-13 20:58:26
Parse newlines in CSL notifications fc21ba1563a1c36ff20711c84b0dc3f3d7588646 mse 2021-11-13 05:12:11
Scriptable special items: GIVESPECIAL <id> <name> 256a2581e75dc3762b098f8cae3259899f8c4a94 mse 2021-11-13 03:24:02
Improved particles, darker nights, work on GIVESPECIAL e8e352e03fdffb8a8e57f94f99028bc1c6c03376 mse 2021-11-12 08:51:36
Fix caption padding bug a49cd2397d2e1b98679828303116db858d146a93 mse 2021-11-08 23:35:07
Disable is_regular_file for Boost support ebee78afad8b29f0332a4cf719c7c4d70e8c9ff8 mse 2021-11-08 22:41:42
Commit 73b7b68133f7767f78c47492f693c5e9e965e214 - Work on particle light and bump version to v0.6.5
Author: mse
Author date (UTC): 2021-11-19 08:04
Committer name: mse
Committer date (UTC): 2021-11-19 08:04
Parent(s): 4a7082e02eda370dba12bb44089777552859c5bd
Signing key:
Tree: 87b075b260fd42959ac750911de488d7c2f071f9
File Lines added Lines deleted
confec.cpp 23 12
File confec.cpp changed (mode: 100644) (index 516208d..613fd8c)
... ... struct SpecialItem {
456 456 int32_t special_item_result = 0; int32_t special_item_result = 0;
457 457
458 458 // App variable definitions. // App variable definitions.
459 std::string app_version = "v0.6.4";
459 std::string app_version = "v0.6.5";
460 460 #ifdef __DEMO__ #ifdef __DEMO__
461 461 app_version += " demo"; app_version += " demo";
462 462 std::string app_name = "Confectioner Engine Demo"; std::string app_name = "Confectioner Engine Demo";
 
... ... std::vector<SpecialItem> special_items;
474 474 std::string language = "en"; std::string language = "en";
475 475
476 476 // Whitelist these languages. Generally, every game should support these. // Whitelist these languages. Generally, every game should support these.
477 std::vector<std::string> language_whitelist = { "en", "zh" };
477 std::vector<std::string> language_whitelist = { "en", "el", "zh" };
478 478
479 479 // Use these mods. The "game" folder is layered on top of the base data. // Use these mods. The "game" folder is layered on top of the base data.
480 480 std::vector<std::string> mod_paths = { "game" }; std::vector<std::string> mod_paths = { "game" };
 
... ... void Tick();
812 812
813 813 void TurboSleep(); void TurboSleep();
814 814
815 void UpdateRimSun();
815 void UpdateSun();
816 816
817 817 void UpdateRichPresence(); void UpdateRichPresence();
818 818
 
... ... int main( int argc, char* argv[] ){
926 926 is_steam_china = true; is_steam_china = true;
927 927 // Determine language. // Determine language.
928 928 std::string game_lang = SteamApps()->GetCurrentGameLanguage(); std::string game_lang = SteamApps()->GetCurrentGameLanguage();
929 if( game_lang == "greek" ) language = "el";
929 930 if( game_lang == "schinese" || game_lang == "tchinese" ) if( game_lang == "schinese" || game_lang == "tchinese" )
930 931 language = "zh"; language = "zh";
931 932 // Register the text handler. // Register the text handler.
 
... ... int main( int argc, char* argv[] ){
941 942 // Determine language. Reset locale to deal with "unholy things" in GCC. // Determine language. Reset locale to deal with "unholy things" in GCC.
942 943 std::string loc = setlocale( LC_ALL, "" ); std::string loc = setlocale( LC_ALL, "" );
943 944 setlocale( LC_ALL, "C" ); setlocale( LC_ALL, "C" );
944 if( ( loc.length() >= 2 && loc.substr( 0, 2 ) == "zh" )
945 if( loc.length() >= 2 ){
946 if( loc.substr( 0, 2 ) == "el"
947 || ( loc.length() >= 5 && loc.substr( 0, 5 ) == "Greek" ) ){
948 language = "el";
949 }
950 if( loc.substr( 0, 2 ) == "zh"
945 951 || ( loc.length() >= 7 && loc.substr( 0, 7 ) == "Chinese" ) ){ || ( loc.length() >= 7 && loc.substr( 0, 7 ) == "Chinese" ) ){
946 language = "zh";
952 language = "zh";
953 }
947 954 } }
948 955 #endif #endif
949 956
 
... ... void TurboSleep(){
4088 4095 } }
4089 4096
4090 4097 // Update the sun position for sprite rim lighting. // Update the sun position for sprite rim lighting.
4091 void UpdateRimSun(){
4098 void UpdateSun(){
4092 4099 float angle = player_time * 6.283; float angle = player_time * 6.283;
4093 4100 auto sun = linalg::normalize( linalg::vec<float,2>( auto sun = linalg::normalize( linalg::vec<float,2>(
4094 4101 std::sin( angle ), std::sin( angle ),
 
... ... void UpdateRimSun(){
4096 4103 ) ); ) );
4097 4104 // Manhattan normalize. // Manhattan normalize.
4098 4105 sun /= std::max( std::abs( sun.x ), std::abs( sun.y ) ); sun /= std::max( std::abs( sun.x ), std::abs( sun.y ) );
4099 if( sun.y > 0.0f ) sun *= 1.0f - std::min( sun.y / 0.2f, 1.0f );
4106 if( sun.y > 0.0f ){
4107 sun *= 1.0f - std::min( sun.y / 0.2f, 1.0f );
4108 angle = 3.14159;
4109 }
4110 // Angle the rim light.
4100 4111 glUniform2f( glUniform2f(
4101 4112 glGetUniformLocation( rimlitSpritePipeline.programObject, "u_sun" ), glGetUniformLocation( rimlitSpritePipeline.programObject, "u_sun" ),
4102 4113 sun.x, sun.x,
4103 4114 sun.y sun.y
4104 4115 ); );
4116 // TODO: I don't know what the hell the particles are doing.
4117 fgl::lightMatrix =
4118 linalg::rotation_matrix( fgl::eulerToQuat( 0.0, -1.57, 1.57 ) );
4105 4119 } }
4106 4120
4107 4121 void UpdateRichPresence(){ void UpdateRichPresence(){
 
... ... void Render(){
4717 4731 DrawFloorParticles(); DrawFloorParticles();
4718 4732 // Draw the entities with rim lighting. // Draw the entities with rim lighting.
4719 4733 fgl::setPipeline( rimlitSpritePipeline ); fgl::setPipeline( rimlitSpritePipeline );
4720 UpdateRimSun();
4734 UpdateSun();
4721 4735 if( multiplayer ) if( multiplayer )
4722 4736 world.drawEntities( ws_entities ); world.drawEntities( ws_entities );
4723 4737 else else
 
... ... void SimulateParticles( double d ){
5046 5060 ), ),
5047 5061 gibs.end() gibs.end()
5048 5062 ); );
5049 // Angle the light to best accentuate the particles.
5050 fgl::lightMatrix =
5051 linalg::rotation_matrix( fgl::eulerToQuat( 0.0, -1.5, 1.5 ) );
5052 5063 } }
5053 5064
5054 5065 void DrawFloorParticles(){ void DrawFloorParticles(){
 
... ... void GameLoop( double d ){
5965 5976 } }
5966 5977 // Draw the entities with rim lighting. // Draw the entities with rim lighting.
5967 5978 fgl::setPipeline( rimlitSpritePipeline ); fgl::setPipeline( rimlitSpritePipeline );
5968 UpdateRimSun();
5979 UpdateSun();
5969 5980 if( multiplayer ) if( multiplayer )
5970 5981 world.drawEntities( ws_entities ); world.drawEntities( ws_entities );
5971 5982 else else
Hints:
Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://rocketgit.com/user/mse/ConfectionerEngine

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@ssh.rocketgit.com/user/mse/ConfectionerEngine

Clone this repository using git:
git clone git://git.rocketgit.com/user/mse/ConfectionerEngine

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a merge request:
... clone the repository ...
... make some changes and some commits ...
git push origin main