Commit Graph

47 Commits (1c64b1cc27a2fa419ed6b3de3a4073528ec88f14)

Author SHA1 Message Date
En Yi 04d928c97f Add a rendering queue for sprite
Only applies for editor scene as a test
2024-12-21 14:37:18 +08:00
En Yi a6326a3944 Tweak crate fall delay 2024-12-09 21:51:55 +08:00
En Yi c02eba9548 Add air pockets to level data 2024-11-11 22:59:32 +08:00
En Yi 6509b33c5a Rework urchin collision with crates
Changelog:
- Fix error in urchin spawning in main game
- Reduce urchin's collision box
- Adjust crate destruction:
    - Delay with arrows and bombs, instant with anything else
2024-11-09 23:40:54 +08:00
En Yi abdf246382 Adjust explosion hitbox 2024-11-09 12:56:51 +08:00
En Yi b36592311a Add water splash to urchins 2024-10-05 20:32:11 +08:00
En Yi 1382cf1370 Deal with urchin's particle effects 2024-10-05 19:18:42 +08:00
En Yi 8efa3015ad Update urchin hitbox and bbox
This is so that wooden can be destroyed by urchin. Urchin can still be
crushed by a wooden crate though.
2024-09-30 22:47:27 +08:00
En Yi 3520715655 Allow urchin to be crushed
LIMITATION
- Urchin can be crushed by wooden crates.
2024-09-29 17:58:07 +08:00
En Yi d3db15a018 Add urchin sprite and fix its spike collision 2024-09-27 23:15:38 +08:00
En Yi b275caf795 Add spawning urchin in editor 2024-09-23 21:55:06 +08:00
En Yi 4abe996640 Add urchin enemy
Changelog:
- Ctransform component now has a bounce coeffcient which determines
  velocity reflection on contact.
2024-09-08 23:05:12 +08:00
En Yi 89176142b6 Readjust arrows and bombs spawning
Changelog:
- Make use of anchor point function
- Readjust offsets and anchor points of sprites
- Readjust hitboxes offset and sizes
2024-08-21 12:52:19 +08:00
En Yi 2be80ea6bf Add sprites for player finishing the stage
Also add cave exit sprite

They are all placeholder for now.
2024-08-20 14:03:41 +08:00
En Yi e4b5695a15 Allow level end to be deleted 2024-08-19 14:24:33 +08:00
En Yi 0a6e7b4ddc Add delta time handling
Internal Changelog:
- Major change: all engine that does counting uses delta time instead of
  frame counting
- Animation runs at 24 FPS
- Water fill is at a constant rate as well
- Particle update will need to be given delta time as well.
- Particle system is not updated to use float, so no delta time handling
  for the system in this commit
2024-04-23 22:44:52 +08:00
En Yi a2c061c5e8 Place position field into Entity
Position is so commonly used that placing it into Entity from the
CTransform components reduces the reference to CTransform.

Void Particle proved that it made development much easier.
2024-04-22 22:15:21 +08:00
En Yi 70d52cca5b Tweak bomb horizontal spawn 2023-11-20 22:10:02 +08:00
En Yi 72c27ed92e Add more SFX
Also, revert crate ground state behaviour
2023-11-13 14:23:31 +08:00
En Yi c78dc50f50 Fix Boulder landing playing on spawning
Done by setting its ground state to 1. For consistency, this is
done to any entity that can 'land'. So far, this has no tangible
gameplay effects.
2023-11-13 11:34:39 +08:00
En Yi ffc890240b Remove asset argument from entity creation 2023-11-11 12:18:45 +08:00
En Yi 029415e19f Add particles for arrow destruction 2023-11-10 23:15:12 +08:00
En Yi b01edded42 Add chest sprite 2023-11-02 20:37:55 +08:00
En Yi ce8284ab39 Implement level ending
Internal Changelog:
- Activate on collected chest == all chest
- Add spawning level end entity
- Level ending in sandbox will just reset the scene
2023-09-25 22:04:13 +08:00
En Yi e8ebe0f89c Improve player collision to chests vs crates
Internal Changelog:
- Delay zeroing velocity on edge check to after hitbox update
- Update player velocity on hitting a crate explicitly
    - This is due to the zeroing velocity changes above
    - This essentially allow 'phasing' through chest but not wooden
      crates
- Render crates using material instead of fragile flag
2023-09-23 00:28:03 +08:00
En Yi e1a0c6e4e0 Implement Chest Entity
Internal Changelog:
- chest entity: Basically crates, but high def, and fragile
- Add new spawn type for chest
- Add atk modifier for player->chest
- Make crate non-fragile
- Ignore chest for collision check and move with player
2023-09-21 21:48:32 +08:00
En Yi 3a4671cecc Add hurtbox to player
Changelog:
- Update player bbox update
- Update hitbox update system to account for player
- Reduce explosion size to allow better chaining behaviour
- Reduce lifetime of destroyed crates
2023-08-17 22:19:01 +08:00
En Yi 8c889690e8 Add null checks when creating new entity
Also, fix player spawn to reuse the player
2023-08-17 21:51:11 +08:00
En Yi 86a29ccba8 Add sprite info for explosion 2023-08-16 21:41:50 +08:00
En Yi e7c6f9929b Add sprite info for all crates 2023-08-15 21:08:46 +08:00
En Yi b980f16def Add sprite info for arrows and bombs 2023-08-15 20:43:04 +08:00
En Yi 62703c0317 Add arrow sprite 2023-08-13 15:02:20 +08:00
En Yi 7929178411 Add sprite loading from empty crates
Also adjust the gravity delay, bomb timing + size to allow
vertical chain explosion
2023-08-08 23:55:46 +08:00
En Yi f81029b482 Add shape factor to control upthrust and friction 2023-07-25 20:39:42 +08:00
En Yi 966432867f Add delay in crate destruction
Changelog:
- Add Lifetimer and remove hurtbox on hit
    - Still insta-remove on player hit
- Fix adding a component to an entity that already has that component
- Reorder lifetimer update system
2023-07-03 22:18:35 +08:00
En Yi ab582e723c Implement bomb's explosion 2023-07-02 21:52:19 +08:00
En Yi a4900a001b Add bomb crates
Changelog:
- Crates can spawn bombs
- bombs does nothing now
2023-07-02 20:37:16 +08:00
En Yi 7dcff39864 Add direction to arrow spawning 2023-06-28 22:50:09 +08:00
En Yi b578dd95f7 Add arrow spawning from crates
Changelog:
- Add function spawn arrow
- Update game system to handle null components
    - enough for the arrow to work
- Render arrow, sort of
- Initial implementation, definitely need more work
2023-06-27 22:11:14 +08:00
En Yi b70dcc1e98 Add activeness to ctransform
Changelog:
- Activeness determines whether to start moving or not
- Tile collision will skip inactive objects
- Crates are inactive on spawn
2023-06-26 20:42:32 +08:00
En Yi 63930fbe7d Update hitbox-hurtbox system
Changelog:
- Use atk and def values to determine whether a hitbox destroys a
  hurtbox
2023-06-17 13:08:07 +08:00
En Yi 371e6fcbdf Add delay to global external forces for entities
Changelog:
- Apply delay to crates and boulder
2023-06-14 21:00:14 +08:00
En Yi aae8811cc1 Add movement to boulder for grid movement 2023-06-05 15:11:06 +08:00
En Yi 62dc51d45e Implement simple systems for pushing boulder 2023-05-30 21:32:04 +08:00
En Yi 29c9b4eec7 Add boulder entity and moveable component 2023-05-29 21:36:06 +08:00
En Yi bc7f9ef777 Add manager field to an entity
Since an entity is essentially tied to a manager, put it as a field in
Entity. This means no need to pass entity manager when getting a
component, which is more intuitive.
2023-05-23 21:00:23 +08:00
En Yi e9d9ffff20 Refactor implementation of Crate Entity 2023-05-16 22:14:54 +08:00