EGE game engine plan

To be done in game EGE engine

Doing right now towards v0.01game:

✔ mainLoop @done (21-12-07 12:52)
✔ fn _dbgMapScanIn_ms @done (21-12-07 13:09)
☐ run once manually fn _dbgMapScanIn_ms()
☐ fn mapPerfTesting() for top-level tests of map access performance
☐ run map perfTester top level once to get a feel for 256×256 maps perf

Terrain + oxygen added for v0.02game:
☐ do code for fn averageLevelFromXY()
☐ test for oxygen availability
☐ oxygen map has initially a homogenous 3 oxy per each square
☐ player can hold max 255 oxy in lungs
☐ when traversing 10 consequtive movements, expands 1 oxygen
☐ needBreather counter rolls always from 9 to 0, upon hitting 0 will decrease lungsOxy
☐ when player traverses squares, he takes any available oxygen in square, so much as it fits his lungsOxy
Simply implement these as MVP as possible

player’s inventory
has to be compressed manually
when you pick and drop items, the consequtive nature of the memory slots gets broken down
GET an object: its name is string-placed into stringpool
CHECK whether player has object: match of desired object vs. stringpool contents

player HAS object T, or does NOT
stringpool of size 20 slots
placement of tools into stringpool
when you drop a tool, its characters are removed
the memory starts to cripple
new tools may allocate the bytes in non-consequtive manner
..thus you sort of “lose” tools, since the matching function doesn’t find anymore a HAMMER
instead it might find AXE..HAMPICKMER…
tools are same as inventory objects, no particular distinction done
hitpoints
name
positionX
positionY

Description of EGE – Elegant Game Engine:

  • EGE represents and handles objects in game
  • serves game-specific game code, handling grass-roots stuff

Responsible for:

  • main things: set initial objects to game
  • during game: get object state
  • mutate an object in-place
  • heat convection in a heat Map
  • do interactions, by querying what is around (close to) object
  • future: generative terrains (code that creates new stuff into Maps)
  • future: load maps from file
  • has code to store various functional “Maps”
  • a Map is one type of x,y grid storage
  • there’s a Map for air, Map for terrain & rooms, etc.

Heat convection pseudocode:

  • the ‘Q’ heat quantity (an integer) is split into as many numbers as there are free directions
  • Q dissipates to round-robin direction
  • there are 8 possible free slots
  • scan # of free slots for ‘x’
  • swirl-preference is the initial direction (one of 8)
  • swirl-preference has also flag for counterclockwise or clockwise direction of swirl-next
  • the algorithm dissipates the Q until there’s no Q left (to zero)
  • try it out! You’ll see what happens. Only by trying.
  • add wind gusts: changes convection-locks
  • try what happens if you change the initial setting of “swirl-preference”

Example of a “Dust” map:

  • x,y stores a number
  • 0 means no dust at all
  • 255 means a lot of dust, choking if player enters this square
  • player’s health is affected by dust around him (‘x’) in 8 locations
  • secondary dust is aggregate number calculated for ‘x’
  • the secondary dust level is average of all 8 locs around ‘x’
  • secondary dust level health hazards are considered in lungFunction(level)
  • dust can be added to location (or “loc” for short)
  • dust never evaporates completely, it doesn’t go OFF anywhere
  • this is why dust is extremely dangerous, because in the end, activity
    makes people choke

Phenomena:

☐ fume
☐ heat dissipation algorithm, to 2-8 directions (neighboring) using 2 maps, src and final
☐ fire
☐ fire spreading
☐ fire spread is incremental – doesn’t diminish the source square

Fire behavior a Conway:
☐ neighboring 1-2 live fire => spreads
☐ neighboring 3,4,5 sustains current fire situation
☐ neighboring 6-8 live fires will deplete oxygen and diminishing the ‘x’ target fire

Electromagnetism:
☐ crosstalk in wires which go perpendicular ‘-‘ or ‘|’
☐ efficient crosstalk finding algorithm to scan only appropriate areas?

Code categories – different Server loading code:
☐ load a critical patch to Server -> removes vuln[] queue item matching patchId
☐ note that loading patches when vuln is not present at same time, doesn’t “armor” the Server
☐ only patch loaded to vulnerable server removes the vulnerability
☐ loading Armor makes Server invulnerable to a class of malware altogether
☐ load malware to Server -> attempts to stick to OS
☐ malware can stick if Server does not have appropriate matching “Armor”
☐ load null (just workload) to Server -> consumes some power, does no evil
☐ fix os, apply a patch to OS level
☐ running user space ‘apps’ affects just Power consumption
☐ running user space ‘apps’ makes user happy 🙂
☐ driver loading to Server

Vulnerability appearing logic in Servers:
☐ vulnerability goes through Servers connected to particular Cable “id”
☐ randomly at 3% chance every 14 ticks in game a vulnerability can strike a Server
☐ vulnerability attempts to stickToServer(), see above in Code Categories
☐ vulnerability chooses to appear only in one of Connected servers
✔ if 0 connected Servers, they are all safe @done (21-12-06 21:56)

Armor removal malware:
☐ some class of malware can uninstall Armors
☐ privilege escalation? is this required to uninstall Armor

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: