Log In  

Interested in games and game design for forever!
Coding novice.
PICO-8 newb.

[ :: Read More :: ]

Cart #markov_demo_22-0 | 2022-06-27 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Demo of Markov Chain Process

Hey everyone, this is my first cart posted to the forums.

I made this tech demo thing to try out Markov Chain modeling, and thought the result was worth sharing.

What is a Markov Model?

A Markov Model or Markov Chain is a process by which an object changes states, and the chance of a change of state is dependent only on the state the object is currently in. At every step (in our case a frame) there is a chance that the object changes states. Each state change can have different chances of occurring. If no state change occurs, the object remains in its current state.

What is this cart?

This cart is just a little demo I made to demonstrate the Markov Chain process. It uses four orbs as objects, each with four different states: move up and down, move left and right, change size, or change color.

Honestly the result came out really nice and is super mesmerizing to me. Wish I could put it as a screensaver.

What you're witnessing is a purely random chance that the orb changes to a different behavior, but the result doesn't quite feel random.

What use is this to me?

The code is pretty generalizable. There are functions that calculate the chance of changing states vs not (dependent on variables you provide) and you can create your own objects and functions that work with the process.

The objects you use need state variables, and a function variable to call, dependent on the state. chkstate, parseorb, and sumtable functions, along with the mark, chnctbl, and states arrays are all you need from this.

Many things in nature can be modeled with a Markov process. So using such a process for your game can add a surprising amount of depth with just a few functions. Enjoy!

P#113706 2022-06-27 02:59

[ :: Read More :: ]

Hi everyone,

I was wondering if anyone had experience importing or transcribing music from a common music editor into PICO-8.

I have a friend who is musically inclined (no coding experience, does not own PICO-8) and was interested in asking him to compose a track for my PICO-8 game.

I have a rudimentary music understanding, and no experience using music composition software.

Is there a way to import music from a midi-like composition software into PICO-8? Or is there an easy way to transcribe music from a file to the PICO-8 cart? Ideally I would be able to import a midi file or similar, or could read the composition in a notation format and transcribe it to the PICO-8 music editor.

My best option so far is to have him learn and use the PICO-8 educational version, and then I copy the music from his cart to mine.

Let me know if you have any advice/suggestions!

P#112946 2022-06-09 16:55 ( Edited 2022-06-09 17:11)