Skip to content

kingpvz/Koula

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

52 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

QUICK LINKS: WIKI | CUSTOM LEVELS | CHANGELOG

HOW TO PLAY?

JUMP TO DOWNLOAD INSTRUCTIONS

REQUIREMEMNTS

These are the minimum requirements to run the game:

  • Python 3.8 or later
  • 256MB RAM or better
  • 2.7GHz CPU or faster
  • 8MB free memory
  • 450x700 pixel monitor or bigger
  • Keyboard

These are reccomended specifications to run the game:

  • Python 3.11
  • 512MB RAM or more
  • 2.7GHz CPU or faster
  • 10MB free memory
  • 1280x720, 1600x900 or 1920x1080 pixel monitor

Step 1: Download

Basically download the entire repository.

Step 2: Open run.py

Double click run.py to open it.

Step 3: Play

Ignore the console window popping up and wait for the tkinter window to open.
Enjoy playing! You can get more insights on how to play in-game by pressing H to open help, or by simply reading the key binds at the bottom of the screen.

HOW TO CREATE CUSTOM LEVELS?

!!! NEW WAY COMING: THE IN-GAME LEVEL EDITOR WILL SOON BE ABLE TO EXPORT LEVELS !!!
Old way:

Step 1: Open gamedata folder

This folder is located in the same directory as run.py. Inside, you can find levels.py, which stores nearly all the level data, except for non-random levels, whose data is located in _leveldata.py.

Step 2: Open levels.py in edit mode

Ignore all the code besides the DATA list.

Step 2: Add a new level to the DATA list

Simply add a comma and add a new entry. The entry needs to follow this syntax: {"KEY": VALUE, "KEY2": VALUE2}
In the entry, replace all KEYs with data you want to change and VALUEs with the values you want to assign them.
"pts" is the only required key. Here are all keys with exaplanation:

  • "pts" = This is the amount of points required to win the level.
  • "blue" = Specifies the amount of blue balls to spawn. Default = 0
  • "black" = Specifies the amount of black balls to spawn. Default = 0
  • "mblue" = Specifies the amount of moving blue balls to spawn. Default = 0
  • "mred" = Specifies the amount of moving red balls to spawn. Default = 0
  • "pos" = Specifies the spawn position of player. Default = (20,20)
  • "data" = Custom level data. READ MORE HERE

Example: {"blue": 10, "black": 3, "pts": 8, "pos": (10,17)} creates a level with 10 blue balls and 3 black balls. You need to get 8 points to win this level. You start at coordinates X:10;Y:17
Note: The example is actually level 3 from the game.

Step 3: Save and Play

Save levels.py and launch the game. In game, press S to skip the levels until you reach yours.

WHAT IS THE PURPOSE OF THIS?

School.

CUSTOM LEVEL DATA

Custom level data is a multiline string that uses a modified SIMPLE QUERY syntax to edit level data.
When you include this key, level settings such as amount of blue balls, amount of black balls, etc. will be ignored.

DOCUMENTATION

Syntax

The syntax is very simple. Every command needs to be on a new line or separated by semicolons.
Every command is made out of multiple statements and values separated by spaces. Since different commands can have different statements, each command in this documentation will be accompanied with its statement syntax.

put/at Command

This is the only command at this time. You can use it to put a ball at a specified coordinate.
Syntax: put BALLTYPE at X Y     Example: put blue at 5 17

Syntax Explanation:

  • put = label to begin this command
  • BALLTYPE = type of ball to put on set coordinates
  • at = label to separate entries
  • X = X coordinate (0<=X<=39)
  • Y = Y coordinate (0<=Y<=39)

Ball Types

  • blue = Blue Ball, White Outline (+1 Point)
  • black = Black Ball, Red Outline (-1 Point)
  • mblue = Moving Blue Ring (+3 Points)
    • You can add an optional speed parameter by including parenthesis with a number in between.
    • Example: mblue(7)
    • If no parameter is provided (mblue), the speed is 10
    • It is not recommended to add a speed greater than 100, as it will most likely lag the game a lot.
  • mred = Moving Red Ring (-3 Points)
    • Same parameters as mblue (mred(7))

Script Example

This script:

put blue at 7 15; put blue at 8 15;
put blue at 9 15
put black at 16 35; put blue at 15 27; put black at 38 39
put blue at 30 10

Would produce this output:

About

Best game frfr

Resources

Stars

Watchers

Forks

Languages