diff --git a/makefile b/makefile index ece37fb..b91e04e 100644 --- a/makefile +++ b/makefile @@ -63,8 +63,6 @@ release: cp -r src iconc.png makefile dino_run/source make gfx - make usb - cp bin/DINO.8xp dino_run/DINO-USB.8xp make no_usb cp bin/DINO.8xp dino_run/DINO.8xp diff --git a/readme.md b/readme.md index 8c70bde..f497763 100644 --- a/readme.md +++ b/readme.md @@ -13,20 +13,19 @@ To avoid having to do this, either update your OS or use a shell such as [Cesium ### Controls: UP to jump, DOWN to duck / fall, enter/2nd to restart, clear to exit. +### Building from source: +The most up-to-date version of the source code may be found [on GitHub](https://github.com/commandblockguy/dino-run-ce). +To build, you will need to install the [CE toolchain](https://github.com/CE-Programming/toolchain/releases). +Run `make` in this directory to produce a binary in `bin/`. + ###USB: -For compatibility with USB devices, use DINO_USB.8xp instead of DINO.8xp. +Please note that USB support is still experimental and not recommended. +To build with USB support, use `make usb` or set USE_USB to 1 in `config.h`. You will also need to send the [USB libraries](https://github.com/CE-Programming/toolchain/tree/usbdrvce). A (probably outdated) prebuilt version can be found [here](http://commandblockguy.xyz/downloads/usblibs.8xg). -Please note that USB support is still experimental and not recommended. You will also need a USB Mini B OTG adapter to use most devices. Dino Run is compatible with HID boot devices (up/left click to jump, down/right click to jump) and the Steam controller (for rumble sounds). - -### Building from source: -The most up-to-date version of the source code may be found [on GitHub](https://github.com/commandblockguy/dino-run-ce). -To build, you will need to install the [CE toolchain](https://github.com/CE-Programming/toolchain/releases). -Run `make` in this directory to produce a binary in `bin/`. - ### Contact: Questions / comments? diff --git a/src/config.h b/src/config.h index e042332..b7e61af 100644 --- a/src/config.h +++ b/src/config.h @@ -13,13 +13,13 @@ #define FRAME_TIME (ONE_SECOND / FPS) #ifndef SHOW_FPS -#define SHOW_FPS 1 +#define SHOW_FPS 0 #endif SHOW_FPS #ifndef SHOW_BOXES #define SHOW_BOXES 0 #endif #ifndef USE_CHEATS -#define USE_CHEATS 1 +#define USE_CHEATS 0 #endif #define GRAVITY 0.6 diff --git a/src/dino.c b/src/dino.c index 68a28f2..58f6792 100644 --- a/src/dino.c +++ b/src/dino.c @@ -11,7 +11,9 @@ void dino_start_jump(void) { game.dino.velocity_y.combined = INT_TO_FIXED_POINT(INITIAL_JUMP_VELOCITY) - game.dino.velocity_x.combined / 10; game.dino.on_ground = false; +#if USE_SOUND play_sound(&game.sound_player, &sounds[SOUND_JUMP]); +#endif } void dino_end_jump(void) { diff --git a/src/main.c b/src/main.c index a4635e7..612b397 100644 --- a/src/main.c +++ b/src/main.c @@ -73,7 +73,9 @@ bool play(void) { } if(game.score >= game.next_beep_score) { game.next_beep_score += 100; +#if USE_SOUND play_sound(&game.sound_player, &sounds[SOUND_ACHIEVEMENT]); +#endif } update_dino();