finished physics lesson, moded sass

This commit is contained in:
ronny abraham 2025-02-19 03:38:14 +02:00
parent 33fcf1fc95
commit 5315d730f8
6 changed files with 84 additions and 1 deletions

View file

@ -2,3 +2,4 @@
@use "sass:color"
@use 'org-media-sass/categories/graphics' as *
@use 'org-media-sass/tables' as *

@ -1 +1 @@
Subproject commit 81ab28665924e14c9fabbe78a56bfa8563583d82
Subproject commit 1d968bab23a361acc994d81b0be157d44236e6f6

View file

@ -1,8 +1,80 @@
#+title: Section 04 - Lesson 03 | Physics 2D Nodes
#+HTML_HEAD: <link rel="stylesheet" type="text/css" href="../../_share/media/css/godot.css" />
#+OPTIONS: H:6
* Links
- [[../../toc.org][TOC - Godot Notes]]
- [[https://www.udemy.com/course/jumpstart-to-2d-game-development-godot-4-for-beginners/learn/lecture/45069801#overview][S04:L45.03 - video]]
* Notes
** overview
*** assets
1. sprite sheet plane, 3 figures
2. pipe and laser site
3. some backgrounds for parallax effect
*** scenes
1. main game scene
2. plane sceen
3. pipes scene (2 pipes)
4. laser scene
*** approach
- make the basic game scene
- make a plance scene
- code plane movement
- build the pipe / laser / pipes scene
- setup the scrolling logic
- setup collishions and plane death
- create the main screen and setup navigation
- add game over
- add scoring with high score saving
- parallax background
*** plane scene
- falls with gravity
- press a key to jump or fly
- collides with laser, pipes, floor, ceiling
- animated propellor
** physics
*** overview
- gravity
- collisions
- movement
- forces
- impulse
- get hit by a rocket
*** physics 2D nodes
#+attr_html: :class two-column-definitions
| node type | definition |
|------------------+---------------------------------------------------------------------------------------------------------------------------------|
| StaticBody2D | Physics body for 2D physics which is static or moves only by script. Useful for floor and walls. |
| CharacterBody2D | Specialized 2D physics body node for characters moved by script |
| AnimatableBody2D | Physics body for 2D physics which moves only by script or animation. Useful for moving platforms and doors |
| RigidBody2D | Physics body which is moved by 2D physics simulation. Useful for objects that have gravity and can be pushed by other objects. |
**** StaticBody2D
- wall, rock, ceiling floor, platform in the middle of the level
- designed not to move
- things will bounce or stick to it depending on what your physics is
**** CharacterBody2D
- think platform character
- set the velocities
**** AnimatableBody2D
- inherits from StaticBody2D
- getting a StaticBody and a Character to move together is a pain and buggy
**** RigidBody2D
- tennis ball
- rocket fired
*** how they interact
- interact with other Physics2D nodes
- we DO NOT control the position, the physics engine does
- we supply velocity / force
- physics engine calculates where we go and what our speed / position is

View file

@ -0,0 +1,9 @@
#+title: Section 04 - Lesson 04 | plane scene and resources
#+HTML_HEAD: <link rel="stylesheet" type="text/css" href="../../_share/media/css/godot.css" />
#+OPTIONS: H:6
* Links
- [[../../toc.org][TOC - Godot Notes]]
- [[https://www.udemy.com/course/jumpstart-to-2d-game-development-godot-4-for-beginners/learn/lecture/45069803#overview][S04:L49.04 - video]]
* Notes

View file

@ -28,3 +28,4 @@
- [[./_subsections/sec04/lesson-01.org][Lesson 01 | Project Setup & Aspect Ratios]]
- [[./_subsections/sec04/lesson-02.org][Lesson 02 | Project Assets & Imports]]
- [[./_subsections/sec04/lesson-03.org][Lesson 03 | Physics 2D Nodes]]
- [[./_subsections/sec04/lesson-04.org][Lesson 04 | Plane Scene and Resources]]