Log In  
Follow
lulublululu
Follow

Cart #16355 | 2015-11-07 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

i don't really want to work on this anymore

let me know if you like what i was getting at

feel welcome to hacking it up and putting something together yourself, the game engine is relatively complete

P#16356 2015-11-07 15:49 ( Edited 2015-11-09 06:52)

Cart #14069 | 2015-09-12 | Code ▽ | Embed ▽ | No License
4

Game I created as my submission for Pico Zine #3 with a couple extra embellishments. Haven't had a chance to playtest it with a pal yet, but it seems like its definitely good fun :)

P#14070 2015-09-12 17:54 ( Edited 2015-09-13 15:16)

Cart #13377 | 2015-08-31 | Code ▽ | Embed ▽ | No License
6

This has been my little baby over the past week or so. It started with jotting down the train game by @PROGRAM_IX from the Pico-8 zine #1, and then making it my own. I ended up using over half my tokens, two sprite banks, and the entire map space. I will leave it to you to discover its mysteries. Playing alongside a warm beverage recommended.

v1.1: Small update to effectively double the rate you gain resources.

P#13307 2015-08-30 12:16 ( Edited 2017-01-17 03:09)

function mchk(x, y)
 return mget(flr(x/8),flr(y/8))
end

function move(x, y, w, h, dx, dy, col)
 w-=1
 h-=1
 if dx < 0
 and mchk(x+dx, y) != col
 and mchk(x+dx, y+h) != col
  then x += dx
 elseif dx > 0
 and mchk(x+w+dx, y) != col
 and mchk(x+w+dx, y+h) != col
  then x += dx end

 if dy < 0
 and mchk(x, y+dy) != col
 and mchk(x+w, y+dy) != col
  then y += dy
 elseif dy > 0
 and mchk(x, y+h+dy) != col
 and mchk(x+w, y+h+dy) != col
  then y += dy end

 return x, y
end

As an exercise, I wrote a small general-purpose collision script and thought I'd offer it up for folks new to P8 or relatively inexperienced with programming.

This is purposefully not a one-stop solution, but it may get you going. It is probably more in the spirit of PICO-8 to come up with specified collision routines yourself. At the very least, there's some study value here.

Things to consider:

  • This was built to collide bodies <= 8 pixels wide and tall. With some thoughtful fiddling you can get it to accommodate bodies of any size, but I kept it this way for brevity.
  • It takes up 226 memory.
  • This is made for colliding against maps only.
P#13111 2015-08-24 22:27 ( Edited 2016-07-25 02:23)

Follow Lexaloffle:        
Generated 2019-12-11 13:18 | 0.078s | 2097k | Q:45