Log In  
Follow
lewsidboi
[ :: Read More :: ]

Cart #petri_v1-1 | 2024-04-13 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
4

Petri

Petri is a chill cellular life simulator. Witness the rise and fall of countless living cells all trying their best to survive and reproduce.

Behavior and ultimate fitness are governed by stats, mutations, and a move-set, all of which are encoded into rudimentry DNA that is passed down to offspring.

Cells that consume enough food become healthy enough to reproduce. Reproduction weakens a cell, but allows it to pass its DNA (with potential mutations) on to the next generation.

Controls

❎ (X): Cycle through display modes
Enter/Pause: Display pause menu and adjust various game parameters

Additional Info

Stats

Each cell has three stats: strength, agility, and speed.

  • Speed determines how likely a cell is to move
  • Strength determines how likely a cell is to consume energy each time it moves
  • Agility determines how likely a cell is to change direction each time it moves

Move Sets

Each cell has a move-set consisting of a list of numbers, 1-4, representing a cardinal direction.

Display Modes

The default display mode will output the number of living cells, the number of total births, the number of total dead cells, the amout of food currently in the environment, and the highest generation achieved.

The text-based display mode outputs the stats of the most recently birthed cells. Move-sets for each cell are indicated by a band of pixels, each color representing a different direction.

Sounds

There are only two sounds effects in the game, one to indicate a birth, and one to indicate a death.

P#145866 2024-04-06 00:21 ( Edited 2024-04-13 20:00)

[ :: Read More :: ]

Cart #clouds_v1-0 | 2021-08-03 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

I found myself flying across the Atlantic recently and tried to capture the vibe in a wee Pico8 vignette.

P#95622 2021-08-03 17:45 ( Edited 2021-08-03 17:46)

[ :: Read More :: ]

Cart #moonmissions-9 | 2020-11-06 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
9

Moon Missions

My take on a lunar lander game, for the Pico-8.

Features:

  • One obnoxious flying saucer
  • A catchy intro tune
  • Semi-procedural levels
  • Persistent high scores

Directions:

Try to land your lunar vehicle on the surface of the moon while keeping an eye on your fuel
and landing speed. Do your part to advance science (and boost your high score) by passing
through each level's "data" waypoints. Keep an eye out for alien interface!

Tip 1: When your landing speed is too high to land, warning lights flash from within your ship.
Tip 2: Keep your eyes out for each level's fuel cannister to get some extra range and boost your score.

Playable in browser at https://www.lexaloffle.com/bbs/?tid=40106

Controls:

  • Up/Left/Right to control directional thrusters
  • (❎) can also be used as an alternate for up thrust

Credits:

This game was designed and created by me, lewsidboi, for you.

http://lewsid.com

P#83563 2020-11-01 03:55 ( Edited 2024-02-01 19:50)

[ :: Read More :: ]

How would I go about comparing numbers greater than 32,767?

I'm using @Felice's code from https://www.lexaloffle.com/bbs/?pid=22677:

function get_score_text(val)
    local s = ""
    local v = abs(val)
    while (v!=0) do
        s = shl(v % 0x0.000a, 16)..s
        v /= 10
    end
    if (val<0)  s = "-"..s

    if(s=="") then
        s="0"
    end

    return s 
end 

I'm saving the three highest scores to the cart data. Unfortunately, I'm struggling to solve how to determine if the user's current high score (stored as a string) is greater than one of the other three. I'm looking for a function along these lines:

function check_new_high_score()
    --high_scores = table of tables { 1 => (player_name), 2 => (player score) }
    for i=1,#high_scores do
        local raw_high_score = get_score_text(config.total_score)
        local raw_saved_score = high_scores[i][2]

        if(raw_high_score>raw_saved_score) then
           return i
        end
    end

    return false
end

Unfortunately, yea, this just fails because I'm comparing strings to each other with a comparison operator. I'd love to know how to resolve this, I've been struggling with it for some time. Things end up in weird places:

P#82692 2020-10-07 22:48 ( Edited 2020-10-07 22:51)