⚒️How to do application or game?

In this page you will learn how to do application or game to Zephyr!

The applications or games are only in beta and for now it supports only specifed GUI modules (pygame), and is programmable only in python!

If you are developer, and you know with python, you have found your place!

To create application/game, the script needs to be in .py and to test it, you need to have Zephyr installed first, and runned it first time!

Now create script somewhere in your computer. We recommend using VS Code for programming the scripts.

Name the script, you want your application to be runned as.

Example: imdev.py

Equals to this command:

run imdev

Now open the script, and paste it there this first!

import pygame
import sys
import io

def run():
    original_stdout = sys.stdout
    sys.stdout = io.StringIO()

    pygame.init()


    ## here is your app/game main logic!


    sys.stdout = original_stdout

    pygame.quit()

The application/game needs to have 1 function that is "run"! The stdout is only for optimalisation and fixing original pygame logic.

After you have written your app/game logic, save the script and when you are on windows, go on this path: C:\Program Files\Zephyr\Apps

If it didnt found that path, run the Zephyr first!

... and paste the script in there. Now open the zephyr, get to the bash and write this command:

run <your_app_name_without_.py>

so if your script/app name is this: zephyr.py

Then run this command:

run zephyr

The app name is case sensitive!


Now when it is working, you have successfully created your first application or game to zephyr. Now share it and dont forget to write them how to add it to zephyr!

Last updated