Pattern Playground lets you select and modify the fill patterns and colours of various shapes in a set, see the rendered results, choose a combination that you like, and output its values to the console.
It helped me get a better grip on patterns while working on some other yet to be released project.
Instructions
Selection / Editing Contexts
- Set (as in, a grouping of shapes) selector
- Object (as in, shape) selector
- Current object (base) colour selector
- Pattern editor
- Pattern on-bits colour vs. transparency toggle
- Pattern on-bits colour selector
Controls
- U/D/L/R to navigate across and within contexts
- [X] to toggle/select
- [Z] to print current set object patterns and colours to console
Sets
Mixed
Prairie
Mars
Is there a way to determine rendered text height, knowing that said text may contain the tall rendering mode option ? I could search for the presence of "\^t" if I can find a way to express the escaped version of that.
-- always prints 6 local text = "\^thello" local h = 6 if sub(text,1,3) == "\^t" then h = 12 end print(h) |
I am getting different results when invoking code in the console as opposed to calling it from inside a running program. The code overrides the default behaviour of the cos function.
pi=3.14159 two_pi=pi*2 -- override cos to work with radians p8cos = cos function cos(rad) return p8cos(rad/two_pi) end -- degrees to radians function d2r(d) return d*two_pi/360 end -- this test works (cos(45 deg) => 0.7071) function _draw() cls() print(cos(d2r(45))) end |
I then run the code, observing correct results (0.7071).
Invoking this from the console however: print(cos(d2r(45)))
prints different results (0.2206).
Are function overrides ignored in the console?
What are the actual steps one must follow to begin scripting in Voxatron?
EDIT
It was right in the API docs
EXAMPLE (global script)
- create a script object, add it to the room, and edit it.
old_draw = _draw function _draw() clv() old_draw() local dz = sin(time())*5 sphere(64,64,32+dz,8,7) end
|
You owe money to the wrong people and you only have a few minutes to pay it back. Grab the money bags and drop them at the safe house. Don't get caught. Don't run out of fuel.
Inspired by Getaway!, a crime-themed game designed by Mark Reid and published for Atari 8-bit computers in 1982.
Screenshots
Controls
- up/down/left/right: drive/steer
- x : speed boost
Changelog
1.3
- minor UI and help text adjustments.
1.2
- easy level debt reduced to $2000, with a due date of 2 minutes.
I have a controller connected to my laptop. To configure pico-8 for it, I did : launch Gamepad Tool > Copy Mapping String > append string to sdl_controllers.txt > relaunch pico-8. This works well.
Now, I would like to use the controller's shoulder buttons as replacements for the d-pad's dpleft (btn 0) and dpright (btn 1), respectively. Can this be done at all? Note that this is not for exported (to html) games but rather to those launched from the pico-8 console.
EDIT:
To be clear, I'd like to control a pico-8 game using a gamepad's shoulder buttons.
EDIT2:
GamepadTool mapping string, as entered in sdl_controllers.txt is this:
03000000bd12000015d0000000010000,Tomee SNES USB Controller,a:b2,b:b1,back:b8,dpdown:+a1,dpleft:-a0,dpright:+a0,dpup:-a1,leftshoulder:b4,rightshoulder:b5,start:b9,x:b3,y:b0,platform:Mac OS X,
(This may sound convoluted)
Is it possible to invoke an embedded ("export html") pico-8 program's functions from an external javascript file?
In this particular case, I wrote a .js app that fetches remote data asynchronously (via ajax). I then want to map that data to a sequence of pico-8 program function names, invoking each one in turn at regular intervals.
I often browse the pico-8 forums on my mobile. On my phone (Samsung S4), I have to squint like a maniac because the contents of the pages are not rescaled by the browser, which they would be if the following viewport meta was on each page:
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" /> |
Can the person responsible for these forums (and web site in general) add that so that I can go back to "squintless" reading. :)
Cheers
Alex
Hi all.
The following code doesn't work -- players don't get drawn.
What am I doing wrong?
Thanks in advance.
Alex
players = {} function make_player(col) local p = {} p.x = 0 p.y = 0 p.color = col return p end function draw_player(p) rectfill(p.x-2,p.y-2,p.x+2,p.y+2,p.color) end function _init() players.home = make_player(1) players.visitor = make_player(8) end function _draw() cls() foreach(players, function(p) draw_player(p)) end |
Could someone explain how glitch effects similar to Benjamin Soulé's Mr.Beam were done? No code as much as an overview.
Thanks in advance.
Alex