Log In  

BBS > Superblog
Posts: All | Following    GIFs: All | Postcarts    Off-site: Accounts

I've been getting a lot of "** failed to save screenshot" (or video) for some time, and I just narrowed it down to load():

  • open a new instance of pico8
  • press f1 -> saved screenshot to desktop
  • load somecart from console
  • press f1 -> ** failed to save screenshot

this works though:

  • pico8.exe -run somecart.p8
  • press f1 -> saved screenshot to desktop

I mostly run my carts from notepad++ (with -run) so it took me a while to figure it out. in fact I only noticed because I'm using the multicart system (thus using load() in code).

Am I the only one experiencing this? (windows10, desktop_path is empty in config.txt)

(edit) works ok on linux...

(edit2) I had backslashes in my root_path ("C:\DEV\SRC\PICO8\carts\" instead of "C:/DEV/SRC/PICO8/carts/"). that seems to fix the problem, for some reason.

1
2 comments


Cart #50714 | 2018-03-23 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

  • add grid and wave effect

A GeometryWar inspired game made during a jam in february

Cart #49915 | 2018-03-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

Controls :

E S D F to move
Mouse to aim
Left click to fire
Right click to bomb when available

1
2 comments



Hey y'all! I'm so excited to share an object-oriented component system I've been working on for PICO-8. I'm still super new to the platform, so I'm looking for any and all feedback you might have -- how to save tokens, smarter ways to loop over updates, cooler rendering techniques, anything!

I built it out as a toolset for the game I'm working on right now, so please forgive me if I've forgotten to take out anything too specialized. Let me know if you're able to use it on a project or if you have any feedback at all!

Thanks for reading! Below is the readme from the github page, linked below.

GITHUB: https://github.com/walt-er/compos

compos: reusable components for object-oriented PICO-8

compos: like "components", but with fewer characters!

compos are independent, reusable objects that can be added to your game's actors to give them certain behaviors. compos manage their own state, initialization, updating, and drawing. The only thing you might need to do is set some intitial values.

There's a fair amount of overhead for defining so many components right out of the gate. But hopefully the savings come down the line: it's easy to attach behaviors to actors independently, so defining large numbers of actors with similar behaviors is simple and doesn't require messy class inheritance. This system is build with procedural generation in mind -- it's easy to spawn complex actors on the fly, mixing and matching qualities without spending tokens.

The compos include:

  • Position
  • Size
  • Velocity
  • Gravity
  • Collider
  • Age
  • Patrol

This library also includes a number of helper functions, including methods for drawing sprites and primitives with outlines, integrated logging, generating vectors, copying tables, tiling sprites, and more.

More importantly, the methods for adding and removing actors from the active list, used in conjunction with the compos update pool (where actors and compos register to run their updates), mean that once you've defined an init(), update() or draw() function to an actor, they'll act just as you expect as they are added and removed from the global list of actors.

Starting with actors

compos loops over an "actors" array and runs the functions those actors and their components have registered for. For your entities to use the compos lifecycle, they will need to copy over the desired components and then be added to the global list of actors.

Here's an example of an object that draws an animating sprite in the middle of the screen:

local thingy = {
    physical = true, -- this inits the x, y, w, and y properties
    sprite = copy(sprite), -- this copies in the compo sprite component
    init = function(self) -- this runs on compo_init (or on demand if this actor is added with add_actor()
        translate(self, 60, 60) -- translate moves an actor to an x and y vector
        local spritesheet = split'0, 1, 2' -- split saves tokens by turning comma separated lists into arrays
        self.sprite:animate(self, spritesheet, 15, true) -- the third parameter is sprites-per-seocnd, the fourth is looping
    end
}
-- add to list of actors to be initialized and updated
add(actors, thingy)

Notice that the actor does not need to register any update or draw functions -- the sprite compo, when initialized, will register for all the lifecycle methods it requires.

If you're adding actors on the fly, use add_actor(). This method will run the required initialization and event registration before the actor is added to the scene.

Lifecycle and the update pool

compos will handle their own updates, but you'll need to add compos functions somewhere for them to run. If nothing else, add the three basic functions to your cart:

function _init()
    compos_init()
end

function _update()
    compos_update()
end

function _draw()
    cls() -- compos doesn't clear for you!
    compos_draw()
end

Behind the scenes, within those compos_* functions, there are various "pools" of actors and compos that have registered to run each frame. The update functions availible are early_update, update, late_update, and fixed_update, and drawing is done in early_update and update.

When an actor is initialized, it's update functions are registered in those pools and run in the order they are added. Keep that in mind for drawing -- actors added later will be drawn on top. (Note that I want to add an optional override for this soon! For now you can use early_draw to make sure things are drawn in first.)

It's important to remove actors by using remove_actor(), as opposed to, say, del(actors, thingy), because the remove_actor function also unregisters all events. Failing to use it could mean a memory leak as more and more actors are registered and none are rmeoved.

Integrating compos into your project

The most direct way to integrate compos into your project is simply copy pasting all of compos.lua into your cart, then deleting unwanted components and functions. There are a lot of functions included here, and cherrypicking what you want will save a ton of tokens. You probably don't need it all!

Integration can also be achieved using picotool, with some extra work. Just require('compos.lua') in your source pico8 file to include compos inside a "require" function. Just note that you'll need to delete the function wrapping the compo definitions for your code to reference them without errors. (NOTE: if you think I could get around this, let me know!)

You could also just hack the compo.p8 cart, using that as a jumping off point!

Demo: Bouncy Blobs

Here's some code that uses compos to draw hundreds of actors with positions, sizes, colors, and gravity:

SOURCE: https://github.com/walt-er/compos/blob/develop/demo.lua

!

[ Continue Reading.. ]

4
13 comments


Cart #49978 | 2018-03-05 | Code ▽ | Embed ▽ | No License
3

A small, experimental game I've been working on. Throwing it up for playtesting!

Update: 18/03/05


Added Game Over to Stage 5 when out of fuel

3
0 comments


Version 1.1B

Cart #picosokoban-0 | 2019-08-20 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
8

Version 1.1A

Cart #54753 | 2018-08-06 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
8

Version 1.1

Cart #50933 | 2018-03-28 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
8

[ Continue Reading.. ]

8
13 comments




Redid the animation and decided to upload it here if anyone's interested. Thanks again to enargy for the font mechanic :)

3
6 comments


Cart #49887 | 2018-03-03 | Code ▽ | Embed ▽ | No License
2


One of my first Pico-8 games. Gather resources, build farms and houses. Place shops en some bigger buildings like churches. Keep all villagers happy. 8 different levels.

2
6 comments


Everything I type in Pico-8 comes out in bash, including pressing of the enter key. So if I accidentally enter a bash command, it gets executed. For example "reboot" in pico-8 not only reboots pico-8, but my raspberry -pi itself.

I'm not extremely experienced with Linux, but I've used enough linux software to think this should not be happening by default. In the meantime I am attempting to find a way to somehow capture the mouse and keyboard while a process is running so it is ignored. Tried "wait" from bash to no avail.

2
1 comment


The second game in my undergraduate capstone project, Picohistory, in which I remake very old games for PICO-8 with my own tweaks. This particular game is Hunt the Wumpus, made graphical with as few changes to gameplay as possible.

I originally intended to include lighting (for atmosphere) based on Dank Tombs, but realized that it would prevent the player from seeing which directions had exit doors, or else be so broad as to not matter, and so saved time by not bothering.

Official project landing page is https://qwertystop.github.io/gamedev/picohistory/ ; official feedback form for the games in the project is https://goo.gl/forms/S9iV9UQGe6da58Bv2 .

Cart #49877 | 2018-03-02 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

1
0 comments


The third game in my undergraduate capstone project, Picohistory, in which I remake very old games for PICO-8 with my own tweaks. In this case, Pac-Man, but zoomed in so you see only about a quarter of the maze at once, with slightly different ghost AI (no bugs when you're facing north), and no lives, multiple levels, or fruit.

Pac-Man is, as far as I am aware, property of Namco.

Official project landing page is https://qwertystop.github.io/gamedev/picohistory/ ; official feedback form for the games in the project is https://goo.gl/forms/S9iV9UQGe6da58Bv2 .

Cart #49870 | 2018-03-02 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

3
4 comments


The second game in my undergraduate capstone project, Picohistory, in which I remake very old games for PICO-8 with my own tweaks. In this one, I heard of Spacewar!, and rebuilt it in PICO-8 having never played it, based on the Wikipedia page describing it.

I think it turned out quite well.

Official project landing page is https://qwertystop.github.io/gamedev/picohistory/ ; official feedback form for the games in the project is https://goo.gl/forms/S9iV9UQGe6da58Bv2 . I'm thinking this one is pretty stable, but it's still got room to change if critique/playtesting points that way.


0 comments


So, this is the first thing I've done in PICO-8, and part one of four of my undergraduate capstone project which I'm calling Picohistory. It's a series of very old games remade in PICO-8, with various tweaks. In this case, Pong with full 2D movement, and your horizontal position affects the ball speed.

Uses some engine code from eevee's Under Construction. I know it's not a good fit here, but I was coming into this pretty much clueless and well behind-schedule due to personal and bureaucratic issues.

Official project landing page is https://qwertystop.github.io/gamedev/picohistory/ ; official feedback form for the games in the project is https://goo.gl/forms/S9iV9UQGe6da58Bv2 . I'm thinking this one is pretty stable, but it's still got room to change if critique/playtesting points that way.

Cart #49864 | 2018-03-02 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

3 comments


Hi folks,

I'm trying to implement the sketch from this video in
pico-8.

but I'm confused by some of the magic included in the Processing API.

Does anyone have any tips or resources on creating the triangle strip mesh and rotating the whole scene on the X axis, or have a cart doing something similar.

Thanks

1 comment


Adapting a solution found ca. pages 179-180 of this white paper:

support.amd.com/TechDocs/25112.PDF (archived)

Apparently it's commonly called "popcount" or "popcnt", after an asm instruction on some CPUs. Basically, it's the population-of-1's count. I think I assumed it would be called "bitcount".

I finagled it into this PICO-8-specific form, which counts every bit (including fractional bits) in constant and pretty-brief time, with just 2 muls, 2 adds, 3 shifts, and 5 bitwise ops:

function popcount(v)
    v-=v>>>1&0x5555.5555
    v=(v&0x3333.3333)+(v>>>2&0x3333.3333)
    return (v*0x1.1&0x0f0f.0f0f)*0x0101.0101<<8&0xff
end

It's a bit uglier than it would be in C/C++, but it's mostly the same operations, with a minor adaptation for the 16-bit shifts inherent in 16.16 fixed-point multiplies. PICO-8 also benefits from being able to do a fast multiply by a fixed-point value like 0x1.1 in the third line of the function, which would have required a shift and an add otherwise.

[ Continue Reading.. ]

6
3 comments


Cart #50162 | 2018-03-09 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

Randomly generated turn based tactics arena.

All units have 10 AP. Moving costs 1 AP and shooting costs 2 AP. Shooting does 1 DMG if it hits. All units start with 5 HP.
Thin lines are half walls. They cost one extra ap to crawl over. They block shots 50% of the time.
Thick lines are full walls. They are impassible. They block 100% of shots.
Hold X to hide UI while menu is up.

Updated with new ai, old ai is called "AI simple". Plus a few little improvements.

Future updates?
-Even better AI!
-Even more general polish.

1
1 comment


Cart #49849 | 2018-03-02 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

Built during the BYU-I Pico-8 Hackathon. My wife and I put it together. Hope you enjoy it!

3
3 comments


"Low Nibble Overflow", by Pingo, 2018.
Original Amiga Pro-Tracker Module by GOTO80/HT, April, 1997.

My first take on covering GOTO80's stuff on the PICO-8. I've done some similar stuff on the BeepBox.co before, but this was actually a bit more difficult. :) Anyway - not the whole song, but at least it kind of works.

/ Pingo

Cart #49843 | 2018-03-01 | Code ▽ | Embed ▽ | No License
4

4
8 comments


Cart #49837 | 2018-03-01 | Embed ▽ | No License

0 comments


@zep
I'm pretty sure this is a bug... shouldn't stat(24) return -1 when no music is playing (like all the other music/sfx stats which use -1 to indicate nothing is playing)? Instead it returns 0, which makes it impossible to differentiate from when music pattern 0 is actually playing :O

(There is technically a workaround, i.e. other stats can be used to check the current note numbers on the channels, which return -1 when nothing is playing, which I am using for now, but this really feels like it should not be necessary... :)

P.S.
Thank you for adding those new music pattern-related stat numbers recently! They are very useful and I am getting a lot of benefit from them in my current project :D

3
3 comments



Screenshots/gifs
https://imgur.com/a/bWMw3

== Old Screens ==

Souls-like, Bloodborne style game for the PICO-8. Navigate your way through insanity as you unlock your mind and free yourself.

Save your mind from the grasp of great insanity. Gather your treasured memories to increase your stamina and keep yourself moving while you expand and unlock your twisted mind.

Discover the 2 different endings...if you can survive your own psyche and make it out alive!

Explore the procedurally-generated maze that changes around you, every minute. Destroy you inner demons, only to see them reborn along with the maze. Luckily the exit, items and treasures stay put...as do your enemies corpses, scarring your soul.

For fans of Rogue-like and Souls-like games, with a fair but challenging difficulty, requiring skill and timing.

[u]Tips:

[ Continue Reading.. ]

14
6 comments




Top    Load More Posts ->