Log In  
Follow
Guest122
[ :: Read More :: ]

Just a fun or education tool in Pico-8.
It is meant to mimic assembly (no particular version) and has by default 16 registers and 18 commands.
Registers aren't labelled, but they are 1-16.
It is easy to expand or reduce if you want to.
I think it is turing complete, although I am not sure.
To type use the keyboard (no support for mobile), enter to make a new line and right arrow to run.

Cart #assemblo8-1 | 2023-11-18 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

List of commands:


mov [reg_num] [dest_reg] - copies from [reg_num] to [dest_reg];

push [reg_num] [num] - copies [num] onto [reg_num]. If [reg_num]==NR, then modifies number of registers. If [num] is smaller then the current number of registers, the last ones will be deleted. Otherwise, registers will be appended to the end;

and [reg_num_1] [reg_num_2] [dest_reg] - performs logical AND on [reg_num_1] and [reg_num_2] and saves the value onto [dest_reg];

add [reg_num_1] [reg_num_2] [dest_reg] - adds [reg_num_1] and [reg_num_2] and saves the value onto [dest_reg];

sub [reg_num_1] [reg_num_2] [dest_reg] - subtracts [reg_num_2] from [reg_num_1] and saves the value onto [dest_reg];

mul [reg_num_1] [reg_num_2] [dest_reg] - multiplies [reg_num_1] and [reg_num_2] and saves the value onto [dest_reg];

div [reg_num_1] [reg_num_2] [dest_reg] - divides [reg_num_1] by [reg_num_2] and saves the value onto [dest_reg];

neg [reg_num] [dest_reg] - negates [reg_num] and saves it onto [dest_reg];

dec [reg_num] - decrements [reg_num] by 1;

inc [reg_num] - increments [reg_num] by 1;

or [reg_num_1] [reg_num_2] [dest_reg] - performs logical OR on [reg_num_1] and [reg_num_2] and saves the value onto [dest_reg];

xor [reg_num_1] [reg_num_2] [dest_reg] - performs logical XOR on [reg_num_1] and [reg_num_2] and saves the value onto [dest_reg];

shl [reg_num] [num] [dest_reg] - performs logical LEFT SHIFT on [reg_num] by [num] places and saves the value onto [dest_reg];

shr [reg_num] [num] [dest_reg] - performs logical RIGHT SHIFT on [reg_num] by [num] places and saves the value onto [dest_reg];

cmp [sign] [reg_num] [num]- compares [reg_num] to [num] using [sign]. If true, skips the following line. List of values for [sign]: 1-greater than; 2-equal to; 3-less than; 4-greater than or equal to; 5-less than or equal to; 6-not equal to;

cmpsb [sign] [reg_num_1] [reg_num_2] - compares [reg_num] to [reg_num_2] using [sign]. If true, skips the following line. List of values for [sign]: 1-greater than; 2-equal to; 3-less than; 4-greater than or equal to; 5-less than or equal to; 6-not equal to;

jmp [line_num] - jumps to [line_num] before or after this one, without triggering lines in between;

halt - stops the program. Required at the end of any program, or else, an error will appear.

P#137326 2023-11-12 19:10 ( Edited 2023-11-18 09:51)

[ :: Read More :: ]

After two months-ish of planning and coding....
I introduce to you...

SECS-OS!

SECS (Securely Encrypted Computer System, don't quote me on this) is a successor to my previous P8-DOS.
Featuring:
A GUI;
A terminal that is definitely not scuffed;
A text editor that is also not scuffed;
A calculator that is actually decent?;
And most importantly:

A login page!

SECS has a built-in weird hashing-like algorithm, to protect you and your system.

You are able to see any folder from within SECS (no idea why it works) and generate .txt files that you can later open.

To make a new line in the text editor, use the right arrow key.
To save the file, use the left arrow key.
To run a command, use the right arrow key.

Due to the high security of this project, the operating system can't be installed directly.
If you would like to give it a try, here it is:

Cart #secs_login-1 | 2023-10-17 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
2



P.S.: Most features require keyboard and mouse. SECS-OS wasn't designed for mobile.
Also, if you find a bug, please let me know!
P.P.S.: Ignore "the operating system can't be installed directly". This is false, I think.

P#136036 2023-10-17 19:25

[ :: Read More :: ]

Just the list of chr() numbers and corresponding outputs.
Some are invisible, like chr(8) since this is backspace or chr(129)(▒) for no reason (?).
https://www.lexaloffle.com/bbs/files/62268/testing.txt.
As the above file is weird, you can check it out on google drive:
https://drive.google.com/file/d/1DdpsxRyfPPM7pB-ukgd8aD_0eL-WqgrU/view.

P#134285 2023-09-13 18:49 ( Edited 2023-09-13 18:50)

[ :: Read More :: ]

Small circuit sim I made inspired by Virtual Circuit Board.
Includes wires, lights, switches, and gates and not gates.
Everything should feel intuitive.

If you find any bugs, please let me know!

Version 1.1 is here!

Changelog:


Added latches and delays.
Latches are dark orange when off and yellow when on.
They can store current.
E.g.:
If the grey part of the latch is powered by a wire, the latch will output what is on the purple part. However, if the purple and grey parts are on, and then the grey is turned off, the latch will still output what was on the purple part.
Delays are dark-grey when off and grey when on. They will, as the name suggests, delay the current from passing by one "visual tick".

Cart #circuitsim-5 | 2023-08-31 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

Mobile version:

Cart #circuitsimmobile-5 | 2023-08-31 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

Version 1.0:

Changelog:


Initial release.
Included wires, lights, switches, and gates and not gates.


Cart #circuitsim-2 | 2023-08-29 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3



As a challenge, try to make a smaller xor gate.
How tiles are counted:

In this image, you can see a channel down the middle.
This has an exit, so the channel isn't counted toward the total tiles.
Lower you will see four 1 by 1 empty areas.
These are counted because they are fully enclosed.
Any tiles you place, will also be counted toward the final score.


Xor gate list: (1.0+)

Score to beat: 34 units of enclosed area.

Solutions by thePixelXb_ and stadam (in order)

(also, for those of you who say stadam's solution is 35 tiles, stop, please)

https://www.lexaloffle.com/bbs/?uid=67356

https://www.lexaloffle.com/bbs/?uid=75813

thePixelXb_'s solution

stadam's solution

If you didn't understand any of these, here is an example:


Things I probably should add:

Another wire that doesn't interact with the red wire?
A built-in xor gate?
Some way to save circuits so that you can use them again as a tile.

P#133658 2023-08-28 16:23 ( Edited 2023-09-01 09:09)

[ :: Read More :: ]

Extremely simple password generator.
Before anything else, I want to say, that since it uses the built-in rnd() function, it will(more than probably)be insecure. If you want extra security, just don't... use it.
It features 7 character sets.
And that is pretty much it.

Cart #passwordgen-0 | 2023-08-13 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

P#133009 2023-08-13 14:06

[ :: Read More :: ]

Small cart that features simple encryption/decryption methods.

Cart #encryption-0 | 2023-08-09 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1



Scytale is kinda broken, sorry!

P#132908 2023-08-09 15:58

[ :: Read More :: ]

Hone your cart hacking abilities with this HackTheBox-like cart!

Simple premise:
You control a square which can move around the screen.
Your goal is to move out of the top left corner and after, without triggering btnp(), get back into the top left corner.
Sounds simple enough.
In fact, I will even let you look at the code!
It is very difficult, so I made an easier version of it for you to try out first.
You will need to download the cart to solve the challenge.

Have fun solving this challenge!

Easier version (try this one first!):

Cart #hacking4_1-0 | 2023-07-28 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
2

Solution:


Go to a different location, using the btnp() keys you have set;
Press esc, to enter the terminal;
Create a function which takes in an argument. Inside the function make p= the argument;
E.g.:

function t(k)
 p=k
end

Call the function and as the argument use the table:{x=0,y=0} or {y=0,x=0};
Modify the _draw() function like so:

function _draw()
 cls()
 move_pl(p)
end

Type resume and hit enter.

Hard (I may or may not have solved it):

Cart #hacking4_2-0 | 2023-07-28 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
2

Solution:


Make a table. In this example it is called p;
Set the table to:{x=0,y=0} or {y=0,x=0};
Modify the _draw() function like so:

function _draw()
 cls()
 if(btnp(⬆️)and p.y>0)then
   p.y=p.y-1
  elseif(btnp(⬇️)and p.y<15)then
   p.y=p.y+1
  elseif(btnp(⬅️)and p.x>0)then
   p.x=p.x-1
  elseif(btnp(➡️)and p.x<15)then
   p.x=p.x+1
  end
  spr(1,p.x*8,p.y*8)
end

Type resume and hit enter.

P#132496 2023-07-28 12:53 ( Edited 2023-07-30 09:47)

[ :: Read More :: ]

My submission for the Summer Slow Jams 2023: Idle

Mutation Mayhem (a prototype)
Its kinda like a base building/defense game.
I dunno anymore. You can play it yourself if you want.

Cart #mutation_nation-5 | 2023-06-26 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Available on itch: https://guest122ev.itch.io/mutation-nation

P#130899 2023-06-13 15:01 ( Edited 2023-06-26 08:43)

[ :: Read More :: ]

LIDA: the sequel

This is a better chatbot (i hope).
Same kind of idea: you write and Lida responds.
You will need to press ➡️ to make Lida respond.
Hopefully, it is less chatbot-y.
It saves your conversation in a p8l file called chatp.p8l.
Again, avoid using punctuation (?,.;!").
Colons and apostrophes should work.

Second version:

Small update with more prompts;
Removed spritesheet.

Cart #chatp-3 | 2023-04-13 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

First version:

Cart #chatp-2 | 2023-04-06 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Code is now much more readable and efficient.
Removed some prompts but added a lot more.
E.g.: removed "who is your creator" prompt;
removed "what came first: the chicken or the egg" prompt.

P#128219 2023-04-06 13:26 ( Edited 2023-04-13 19:47)

[ :: Read More :: ]

Maze solving algorithms

Random

Cart #randmaze-0 | 2023-02-05 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

Note:

Takes ages, so I made it faster

Rating:2/10

Breadth-First Search

Cart #bfsmaze-1 | 2023-02-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

Note:

Actually not bad, although will search a lot

Rating:4/10

Depth-First Search

Cart #dfsmaze-1 | 2023-02-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

Note:

Worse than BFS, because it misses nearby targets

Rating:3/10

Wall-Follower

Cart #wall_follower-0 | 2023-02-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

Note:

Might fail with loops

Rating:4/10

Dead-End Filling Algorithm

Cart #dead_end_filling-0 | 2023-02-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

Note:

Will fail with loops

Produces a path

Rating:5/10

A*

Too lazy to code my own.
Instead, check this one made by @dw817:

https://www.lexaloffle.com/bbs/?pid=115379#p

P#125359 2023-02-05 11:57 ( Edited 2023-02-27 21:36)

[ :: Read More :: ]

Program which tests every number from 2 to 0/0 for the collatz conjecture(yes, I know we already proved up to 2^68).
Makes a sound if the number does follow the conjecture.
To the right is the number it is testing, and to the left is the operation results.
Saves the results to a file.
And I didn't try to make memory efficient.

Cart #collatz-1 | 2023-01-14 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1


Fixed producing negative numbers.
Cart #collatz-0 | 2023-01-14 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1


Without the fix.

P#124294 2023-01-14 15:01 ( Edited 2023-01-14 18:54)

[ :: Read More :: ]

A small chatbot.
It uses a dictionary of text and responses, so it can't reply to everything.

Should work online.
Try to not use punctuation (?,.;!"), as that isn't something it understands too well. Apostrophes and colons should be fine though.
Please, leave any errors or suggestions below as I am trying to make it better.

Better version of the chatbot as it is a bit less chatbot-y.
You will need to press ➡️ to say what you wrote.

Cart #chatp-0 | 2023-04-06 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

Cart #chatbot-1 | 2022-12-10 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3


Note: It isn't an algorithm or loneliness defeating, Lida chose it's own name and doesn't understand these concepts.

P#122161 2022-12-10 17:33 ( Edited 2023-04-06 12:07)

[ :: Read More :: ]

In my code, I used menuitems as a way of interaction with the game.

When you run it, if you go to the command line, set items.planks to true and go back to the game and pause, press level 1 and then press move, it shows an error, about trying to call _superyield with flip().

I don't know if this is something bad or not, as I don't understand yield(), _superyield and flip() since I never used any of these.

The error:

The code (tried to remove the useless stuff):

function _init()
    menuitem(1,"level 1",level1)
    items={
        planks=false
    }
end

function _draw()
end

function level1()
    menuitem(1,"move",move)
end

function move()
    return true
end
P#120938 2022-11-18 19:23 ( Edited 2022-11-19 11:36)

[ :: Read More :: ]

A small simulator of Prey Vs Predator.

All creatures can only move in one of four directions: up, down, left, right.
Moving consumes an energy point.

If a prey runs out of energy, it can't move that turn.
It may choose to not move even with energy.
If any of these happen, then it gets 1 energy point.

Predators also can run out of energy. It they do, they die. To get energy, they need to eat prey. If they do, they get full energy and 2 more predators appear.

The objective of prey is to outlive the predator.
The objective of predator is to kill all prey (yes, I know that they die after that. Just ignore that for now).

If a prey is next to a predator (not diagonally), has energy and wishes to move, it will move away from the predator.
If a predator is next to a prey (not diagonally) and wishes to move, it will eat the prey, but if it had 1 energy before eating, the prey survives and the predator dies.

If none of the above are met, the creatures will move around randomly.

Pretty much everything is customisable, although it might run slower.

If you wish (or made a huge map), you can move the cam with the arrow keys.

Added prey splitting. They split every set amount of turns (configurable) and have a random chance of splitting (also configurable).

Cart #prey_vs_pred-5 | 2022-11-14 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
4

Doesn't need pico-8 terminal. Yay!

Without prey splitting version:

Cart #prey_vs_pred-4 | 2022-11-13 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
4

P#120621 2022-11-13 19:40 ( Edited 2022-11-14 19:18)

[ :: Read More :: ]

A sort of computer virus.
It is able to spread and has a maximum depth of 3.
It won't spread to other hosts but is able to travel up between folders (don't know why).

As soon as you run it, it begins the process, so be careful, I guess.

Cures

Deleting the cartridge,
Renaming everything important to you so that the name has a -(hyphen), including folders,
Or putting the cart in a folder with nothing in it.

Cart #cvirus-0 | 2022-11-12 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

UFNR doesn't (in this case) stand for anything.
Definition of computer virus (for the nerdy ones): a piece of code that can duplicate itself, with usually a harmful intention or effect. UFNR can spread but doesn't really do anything else.

P#120549 2022-11-12 17:55 ( Edited 2022-11-12 17:56)

[ :: Read More :: ]

Sorry, I guess? is a

file flooder.

And as usual, it needs to be executed in the app, otherwise it just displays Sorry, I guess?
This is because it uses ls().
It is my biggest cart ever with,

Drumroll please...

32875 characters

158% compressed size(almost).

10 file version:

Cart #flood_1-0 | 2022-11-12 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

64 file version:

Cart #flood-0 | 2022-11-11 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Sorry for any damage.
It is harmless and can be removed.

Btw, any way to make more efficient?

P#120495 2022-11-11 19:25 ( Edited 2022-11-12 11:05)

[ :: Read More :: ]

An edit of the Jelpi demo to showcase glitches and bring pain to all!

Cart #jelpipain-0 | 2022-11-10 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
2

P#120447 2022-11-10 16:04

[ :: Read More :: ]

Hone your cart hacking abilities with this HackTheBox like cart!
Your objective is to get to the hidden link using the terminal.
I suggest you don't look at the code before solving it as that will ruin the fun.
Also, you don't have to brute force the link. There is a genuine solution.

What you know:
All the links are stored in a table called links, but the links are local. What now? Hmm...

Have fun solving this challenge!

Cart #hacking2-0 | 2022-11-01 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

P#119938 2022-11-01 10:58

[ :: Read More :: ]

Discontinued

A MS-DOS inspired command line VM.

Features:
Check date and time,
View files,
Make new files,
Delete files,
Recycle bin so you don't accidentally lose your files,
Explore the virtual web, which may or may not delete all your files,
Make a custom website,
And a secret function which isn't documented.

There sadly isn't support for folders yet.
I tried to maintain the usual names, but I didn't want to mess around, changing built-in functions.
Remember h() for help!

V. 1.2:

Changes:
Added customweb()

Cart #p8dosv1_2-0 | 2022-11-01 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

V. 1.1:

Cart #p8dos-1 | 2022-10-30 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Note: When exploring the web, maybe protect your ears.
I am terribly sorry if the sounds cause some problems.
Also, don't store important data in the VM, because it may get deleted.
And as usual, you need to use the p8 terminal.

P#119865 2022-10-30 19:09 ( Edited 2022-11-28 16:17)

[ :: Read More :: ]

Hone your cart hacking abilities with this HackTheBox like cart!
Your objective is to get the admin password using the terminal.
I suggest you don't look at the code before solving it as that will ruin the fun.
Also, you don't have to brute force the password. There is a genuine solution.

What you know:
All the accounts and their passwords are stored in a table called users.

Have fun solving this challenge!

Cart #hacking1-0 | 2022-10-19 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

You will need to download the cart so you can use the terminal on it.

P#119318 2022-10-19 17:45 ( Edited 2022-10-19 17:45)

View Older Posts
Follow Lexaloffle:          
Generated 2024-03-28 16:48:27 | 0.146s | Q:107