mirror of
https://github.com/Zeal-Operating-System/ZealOS.git
synced 2024-12-25 23:10:32 +00:00
Merge branch 'master' into sandy-beach-palette
This commit is contained in:
commit
1b346915f1
12 changed files with 198 additions and 27 deletions
|
@ -2,15 +2,13 @@
|
|||
|
||||
[![Discord](https://img.shields.io/discord/934200098144022609?color=7289DA&label=Discord&logo=discord&logoColor=white)](https://discord.gg/rK6U3xdr7D) [![](https://img.shields.io/badge/wiki-documentation-forestgreen)](https://github.com/Zeal-Operating-System/ZealOS/wiki)
|
||||
|
||||
The Zeal Operating System is a modernized, professional fork of the 64-bit Temple Operating System. Guiding principles of development include transparency, full user control, and adherence to public-domain/open-source implementations.
|
||||
The Zeal Operating System is a modernized fork of the 64-bit Temple Operating System. Guiding principles of development include transparency, full user control, and adherence to public-domain/open-source implementations.
|
||||
|
||||
![](/screenshots/screenshot2.png)
|
||||
|
||||
ZealOS strives to be simple, documented, and require as little of a knowledge gap as possible. One person should be able to comprehend the entire system in at least a semi-detailed way within a few days of study.
|
||||
Simplify, don't complicate; make accessible, don't obfuscate.
|
||||
|
||||
> The CIA encourages code obfuscation. They make it more complicated than necessary.\
|
||||
—Terry A. Davis
|
||||
**Simplify, don't complicate; make accessible, don't obfuscate.**
|
||||
|
||||
Features in development include:
|
||||
- [32-bit color VBE graphics](https://github.com/TempleProgramming/HolyGL)
|
||||
|
|
|
@ -578,6 +578,29 @@ U0 RotateMan(F64 d)
|
|||
}
|
||||
}
|
||||
|
||||
CTask *mouse_task = NULL;
|
||||
CTask *game_task = Fs;
|
||||
F64 mouse_scale = 32.0;
|
||||
|
||||
U0 MouseHandler()
|
||||
{
|
||||
Bool button;
|
||||
I64 x;
|
||||
while (TRUE)
|
||||
{
|
||||
button = mouse_hard.raw_bttns[0];
|
||||
x = mouse_hard.raw_data.x;
|
||||
if (button || x!=0)
|
||||
MouseRawReset; // Mark mouse data as consumed
|
||||
if (button)
|
||||
MessagePostWait(game_task,MESSAGE_KEY_DOWN_UP,CH_SPACE,0);
|
||||
if (x != 0) {
|
||||
man_é += (x/mouse_scale)/MICRO_STEPS;
|
||||
}
|
||||
Sleep(10);
|
||||
}
|
||||
}
|
||||
|
||||
U0 CastleFrankenstein()
|
||||
{
|
||||
I64 sc;
|
||||
|
@ -618,6 +641,26 @@ U0 CastleFrankenstein()
|
|||
Fire;
|
||||
break;
|
||||
|
||||
case 'm':
|
||||
if (!mouse_task) {
|
||||
MouseRaw(TRUE);
|
||||
mouse_task=Spawn(&MouseHandler,NULL);
|
||||
}
|
||||
else {
|
||||
Kill(mouse_task);
|
||||
mouse_task=NULL;
|
||||
MouseRaw(FALSE);
|
||||
}
|
||||
break;
|
||||
|
||||
case '+':
|
||||
mouse_scale *= 0.9;
|
||||
break;
|
||||
|
||||
case '-':
|
||||
mouse_scale *= 1.1;
|
||||
break;
|
||||
|
||||
case '\n':
|
||||
Init;
|
||||
break;
|
||||
|
@ -663,7 +706,11 @@ fs_done:
|
|||
RegWrite("ZealOS/CastleFrankenstein", "F64 best_score=%5.4f;\n", best_score);
|
||||
}
|
||||
|
||||
MouseRaw(TRUE);
|
||||
mouse_task=Spawn(&MouseHandler,NULL);
|
||||
CastleFrankenstein;
|
||||
if (mouse_task) Kill(mouse_task);
|
||||
MouseRaw(FALSE);
|
||||
|