Log In  

BBS > Community Superblog
All | Following | GIFs | Off-site

Cart #rotating_triangle-0 | 2020-05-10 | Code ▽ | Embed ▽ | No License
1

Hello

I'm in the process of making a triangle-based game. I'm looking for some advice on how to achieve this as I have been banging my head off a wall with it for about a week now. I'm probably doing this a really dumb way.

I've posted a small cart with an extrapolation of the sections I'm having difficulty with.

I'm trying to get the triangle in the centre of the screen to rotate towards the player (in this case the player is a green cross moved with the arrow buttons). The rotation should not be instantaneous - the enemy triangle in the centre must turn towards the player at the speed defines as enemy.turnspeed - I have some (quite messy) code that turns the triangle towards the player but it breaks down at a couple of points.

The main problem is when the player passes the enemy's y-coordinate on the left side the triangle starts turning the other way. This seems to be due to the way the angles are calculated as this seems to be the point where the target angle wraps past 0.

The other problem is probably related - if the player object goes around the enemy quickly enough it will continue turning one direction even if it would be more optimal to turn the other direction.

This all seems to be stemming from my use of the target angle and calculating whether it is greater or less than the enemy's aim direction.

So in short, I am trying to work out a better way to do this that actually works.

Apologies if this seems vague or messy - I'm pretty new to all of this stuff and there's no doubt a bunch of stuff that's pretty wrong with what I'm doing...

1
2 comments


Cart #woolcat_3d-1 | 2020-12-15 | Code ▽ | Embed ▽ | No License
30

WoolCat! Now in 3D!

Remade using Instant 3D (Modified to work with the original 64px resolution).

How to play

Keep Woolly's spirits up on his way home, be careful and keep an eye on his happiness meter, collect all the balls of wool to keep him moving forward.

  • Run around with the arrow keys.
  • Collect all the wool to move to the next level.
  • Collecting wool refills the happiness meter a little bit.
  • Touching water or oil removes some happiness and restarts the area.
  • There are 15 new levels for a total of 81.
  • To move diagonally, press two directions at the same time.

[ Continue Reading.. ]

30
9 comments


Cart #kadubosebu-0 | 2020-05-10 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
2

2
0 comments


@zep I've noticed that the pal() function returns values > 15 when the c0 parameter is 0
such as:

pal(0, 5)

I'm running 0.2.0I linux 64 bit, ubuntu 20.04

I've attached a simple cart that demonstrates the problem.

Thanks.

Cart #palbug-0 | 2020-05-10 | Code ▽ | Embed ▽ | No License
1

1
11 comments


I'm seeing some new people picking up PICO-8 with the 0.2 release announcements (welcome!) and some discussion of the new visible tabs feature is giving the config.txt workflow some attention. People are tripping on the fact that PICO-8 overwrites config.txt on exit without testing for changes.

I'd like a smarter merge of in-memory and on-disk properties. The app should remember last loaded properties so it can calculate "dirty in memory" and "dirty on disk." DiM only? Update disk. DiD only? Update memory. Both DiM and DiD? Tricky, but maybe this is avoidable if PICO-8 always merges on every in-memory change.

I assume PICO-8 already has logic for preserving comments and resolving weird cases like a property appearing more than once, or not at all, in the file. :)

3
1 comment


I like how I can indent/dedent a block selection with tab/shift-tab, and I like the behavior where it operates on every line with at least one character selected. I notice an edge case that should be addressed: if the first line is indented and I have the intend spaces selected, when I dedent the space goes away but my selection start moves up to the previous line. If I dedent further now the previous line is getting included in the dedent.

6
1 comment


I like the new feature where shift-enter auto-indents. It also adds an "end" statement which is useful for closing blocks.

I'm wondering if it should always do this, or if it could do something more context sensitive. A full IDE would be running a full parser in the background which is probably overkill. A simpler behavior would just scan the current line for block starter keywords and only indent+end if it finds one.

I'd prefer this because I'm likely to get into the habit of shift+enter, enough to do it by accident, and if it always does what I want that'd be better than having to undo and try again.

3
1 comment


[sfx]

For fairly whimsical reasons, I decided to write a four-part crab canon in PICO-8. Tenor and soprano channels play the melody forwards, bass and alto channels play the melody backwards.

If anyone wants to use it for anything, feel free to ask - but given that it uses all 64 SFX slots and all four sound channels for eighty seconds of music, I don't expect it to be useful to anyone in particular. It was fun to break out some of the partwriting skills from community college music theory classes again, though.

2
0 comments


Cart #ultrapeeks_upsnake_v1_00-0 | 2020-05-09 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

I was introduced to PICO-8 a week ago and couldn't really stop coding since.
So this is my first project. It is yet another snake game but a good opportunity to learn about the diffrent aspects of PICO-8.

The game features 4 snake velocities, 8 stages, persistent highscores, and somewhat forgiving gameplay if you happen to bump into a wall or yourself and manage to turn immediatly.
Higher speed and more complex mazes will grant you more points to beat the highscore.
It also has background music, but activate at own risk. It get's pretty annoying in my opinion.

Controls:
❎: select, continue, confirm
🅾️: back, hide/show game over pop-up
Use the arrow keys to move the snake, change options and enter your name

[ Continue Reading.. ]

3
0 comments


Cart #pixelmaze-1 | 2020-05-09 | Code ▽ | Embed ▽ | No License
4

Hello! For my first game, I created a very difficult little game! You have to pick up the key to get to the next level, but be careful! If you hit red, you start the level all over again.
New levels will be coming up in the next few days.

4
6 comments


New API pack() returns a table with an "n" field of always 0?

?pack(1,2).n -- 0 (expected: 2)
?pack(1,2,nil,3,nil).n -- 0 (expected: 5)

table.pack works as expected in lua.

2
2 comments


Cart #fruitsnake-0 | 2020-05-09 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

3
0 comments


Cart #newtonvsaristotle-0 | 2020-05-09 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
4

4
1 comment


Cart #turnover-0 | 2020-05-09 | Code ▽ | Embed ▽ | No License
11

Here's my 7th Pico-8 game.

A Pico-8 version of Turnabout, a PSX game from 2000.

It's a puzzle with 100 levels.

The goal is to get all the colored pieces to disappear.

Controls: L/R to rotate board

11
2 comments


Larkstongue v.0.0.1-alpha

Larkstongue is an asset packer, written in Python. It can extract raw cart data from a .p8 file, compress and pack assets into the cart data of a .p8 cart, and generate code for unpacking that data.

Current features:

  • Extracts any cart data area
  • Special extract function for bitmaps with automatic cropping
  • Generates loader code according to the user's specifications
  • Hilbert curve mapping for bitmaps
  • Run length encoding
  • Huffman coding

Larkstongue is currently in early public alpha, so there will probably be a lot of quirks still. Remember to keep backups of any carts you use it on!

Get it on GitHub and give it a try! Do try to break it and tell me how you broke it :)

6
0 comments


Variable inspector window

Debugging carts with "print" and "printh" can be cumbersome, so I made a little snippet to help.
It adds a little window where you can view variables and drill down into them.

To use it, add the snippet somewhere into your program:

dbg=(function()

	poke(0x5f2d, 1)

	-- watched variables
	local vars,emp={},true

	-- window state
	local exp=false

	-- text cursor
	local x,y

	-- scrollbar
	local sy=0 
	local sdrag

	-- mouse state
	local mx,my,mb,pb,click,mw

	function clicked(x,y,w,h)
		return click and mx>=x and mx<x+w and my>=y and my<y+h
	end

	function butn(txt,x,y,c)
		print(txt,x,y,c)
		return clicked(x,y,4,6)
	end

	-- convert value into something easier to traverse and inspect
	function inspect(v,d)
		d=d or 0
		local t=type(v)	 
		if t=="table" then
			if(d>5)return "[table]"
			local props={}
			for key,val in pairs(v) do

[ [size=16][color=#ffaabb] [ Continue Reading.. ] [/color][/size] ](/bbs/?pid=76213#p)
13
2 comments


mini, a short game i made.

Cart #wuyuziribo-0 | 2020-05-09 | Embed ▽ | No License

0 comments


How come the Voxatron cartridges are laggier then plain old PICO-8 cartridges and when you move its slow af. Whenever I look at the GIF's of Voxatron, they look perfectly fine, but when I play a Voxatron cartridge, It's slow. Like my internet is perfectly fine, yet Voxatron STILL LAGS. Please let me know if you know why and how to fix it if you know either of those. Or at least how to stop the lag. Thank you. :)

1 comment


Cart #liberator-0 | 2020-05-08 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3


Save the slaves!
Use arrow keys to move
TIP: look at your shadow to keep track of where you are.

3
0 comments


Download 0.2.0i at lexaloffle or via Humble, or for PocketCHIP.

Alright, let's do this! PICO-8's core specification is complete, and it appears to do what it says on the tin. So I'm calling it:

PICO-8 is in Beta!

The main purpose of 0.2 is to finish freezing the core of PICO-8 -- the api, cpu counting, specs, cart format, memory layout, program behavior, backwards and future-compatibility should no longer change.

Earlier attempts at settling on a fixed core in 0.1.11 and 0.1.12 failed because of technical issues creeping in and also some design decisions that just didn't sit right. It has only been due to the ongoing process of users like @Felice, @electricgryphon, @jobe, @freds72, @Eniko, @samhocevar, and many others prodding at the boundary of what PICO-8 can do -- and what it should do -- that all of those nooks and corners finally took shape. I'm really happy with the way the last pieces of PICO-8 have snapped together, and I think it has reached a point where it feels not only like it should never need to change, but that it never could have been any other way.

[ Continue Reading.. ]

63
25 comments




Top    Load More Posts ->