| project2-godot | ||
| .editorconfig | ||
| .envrc | ||
| .gitattributes | ||
| .gitignore | ||
| COPYING | ||
| flake.lock | ||
| flake.nix | ||
| README.md | ||
Project2
The biggest of chungus projects.
I love hmbrgors
AAHHAHHHAHA
DMC 2 (real) game best & biggest
now 327 years in the making!
Debug Controls
- G to open debug overlay
- B to enable in-game gizmos
- F5 to respawn
- F6 to set respawn point (remembers across sessions)
- C to toggle debug camera, left-click then drag to pan
- Ctlr-S to save game.
- Ctlr-O to load game.
Important
This repo uses git LFS.
Systems Description
Actor (Player + NPCs + enemies) Scene Structure
The root actor node is the glue that determines when the states under the stm (STate Machine) happen, hence the root actor node exports timers / whether abilities are enabled. The state nodes under stm exports data that are relevant to that state, say gravity for air.
HOWEVER, there is a unintuitive aspect to this. The air state for example has many different ways of entering it, hence the stats (JumpStats) that it uses can be given by the previous state. For example when you jump from the ground the ground state has the stats for the jump (most of the values relevant for being in air).
Camera System (OUTDATED)
The camera system is a thin layer (script ExtendedCamera.gd) on top of Godot's Camera2D node, it adds the ability for a camera, typically the player's camera, to "inherit" properties from other cameras in a layered fasion so that multiple cameras can act on the player camera at the same time in different ways. When doing this, properties are interpolated according to a curve. Things that are currently interpolated/transfered/supported (nag Rakarake if you need something else): * position, for when you want the camera to focus on/follow something * limits, usefull when having dynamic rooms that only want to show a portion of the screen Another ting of note is that Camera2D can be weird with it's smoothing, i.g. when interpolating limits don't do it where one camera has Godot's very high default, set it to something reasonably high.
Scene Transitions
TLDR instanciate the "SceneTransition" scene then add a collision shape to it. The properties determine how it behaves, if it's an interactable area or a zone you walk into. "SceneTransition" nodes can work both as entrances and exits, you reference them by the scene in which they reside and the name of the node. Make sure that the node names are unique! in the same scene.
The export/file-picker used to select the scene sadly does not update when you move the file it points to, it has to be manually updated.
Project Folder Structure
Like this:
/(root)
/characters
/player
player.tscn
extendedcamer.gd
etc.
/assets
atk.png
jump.png
etc.png
/npcs
/painter
painter.tscn
etc.
/assets
painting.png
griddy.png
/etc
/enemies
/arnold
Arnold.gd
Arnold.tscn
etc...
/assets
atkL.png
walkR.png
etc.png
/bingus
bingus.tscn
bingus.gd
etc...
/assets
atkL.png
walkR.png
etc.png
/etc.
/zones
/fungus
/rooms
/room_1
room_1.tscn
idk all the other stuff, if no other stuff than we could just move the rooms up one directory
/room_n
/prefabs
/rocks
/fungi
/fungus_1
fungus_1.tscn
...the other not sprite stuff idk what that might be
/assets
fungus_1.png
/fungus_2
fungus_2.tscn
/assets
fungus_2.png
/fungus_n
/trees
/generic_forest
/rooms
/prefabs
/ash_zone
/rooms
/prefabs
/shaders
/global
/thing(s)
game engine & code stuff
/etc.....