Capitalist Pig by Sander Alsema

Add to
My games
Add to
Wishlist
Save to
Collection
No reviews
Exceptional
Meh
Skip

About

--- Capitalist Pig ---

Written by Sander Alsema for the 10-liner competition 2021.

Language: Commodore 64 Basic v2

Category: PUR-80

--- Description & Instructions ---

On a farm in the poorest part of the country lives Francis the pig. By a

stroke of luck he has the opportunity to gather a decent amount of cash.

Usually farm animals don't know the value of money. This is where you come

in. Help Francis to bring home the bacon, and catch all the twenty-dollar

bills, which for some reason are blowing in the wind.

You do this by pressing:

 - "Q" to stretch his arm.

 - "A" to retract his arm.

Every time you catch a banknote, Francis will move to the right, making it

harder to catch the next one.

If you fail to catch a note, you will lose the game.

However, if you manage to catch twenty banknotes, you will win.

Unlike games that are in an infinite loop, where you just score points

until you die, this game actually has a victory condition.

This means you can win and feel really proud of what you have accomplished!

--- Code Explanation ---

Line 0: Read the data for the partial pig string, the paper money string

        and the victory text string.

        Make a string with quotation marks.

        Use this string to complete the pig string.

        In a loop, create the background string, which also doubles as a

        vertical orientation string.

Line 1: In this same loop, create the partial arm string.

        Complete the arm string with a hoof string.

        Set the background colour to black.

        Set the arm length variable.

Line 2: Clear the screen, display the dollar amount, the background and

        the pig.

        Randomly set the variable of the paper money altitude.

        Set the variable for the horizontal position of the paper money

        to the far right.

Line 3: Display the arm.

        Read the keyboard.

        If the key pressed was "Q" and the arm is not fully stretched,

        then stretch the arm.

Line 4: If the key pressed was "A" and the arm is not fully retracted,

        then retract the arm.

Line 5: Display the paper money.

        Move the paper money to the left.

        If the money has reached the far left side of the screen, then

        delete the victory text and jump to line 8.

Line 6: If the character in the position just in front of the paper money

        is NOT a pig's hoof, then jump to line 3.

Line 7: Display the "OINK" text balloon.

        Wait a short while.

        Move the pig to the right.

        If the pig has NOT yet reached the final position, then jump to

        line 2.

Line 8: Clear the screen, display the dollar amount, the "GAME OVER" text

        and the victory text (should this be the case).

        Wait for a key to be pressed.

Line 9: Restart the game.

        This line also contains data for the partial pig string, the paper

        money string and the victory text string.

Platforms
Genre
Release date
Developer
BASIC 10Liner
Age rating
Not rated

System requirements for PC

Read more...
Edit the game info
Last Modified: Mar 12, 2021

Where to buy

itch.io