Skip to main content

A simple interpreter for Fluxel scripts

Project description

Fluxel Interpreter

Fluxel is a simple, user-friendly scripting language and interpreter designed for creating interactive applications with ease. It provides a range of features for building GUI applications, handling user input, and even integrating with AI models.

Updates

0.3.0 Added "blast" blast is a fun little minigame. Press enter to shoot. just make a new line in your code and put "blast" (without the "").

0.2.4 Fixed accidentally deleted interpreter

0.2.3 Added "typewriteask" Litteraly just typewriter + ask. example: [typewriteask "Hows your day today?" 3 remember userDay typewrite "You're having a " + userDay + " today? Nice."]

0.2.2 Added "typewriter" example: [typewriter "Hello!" 3] Types each letter out and takes 3 seconds to finish.

0.2.0 Added "wait" example: [wait 3] waits 3 seconds.

Installation

Install Fluxel using pip:

pip install fluxel text

Usage

Run a Fluxel script using the command:

fluxel Script.flux text

Features

Variables and Input

  • Variable Declaration: var name = value
  • User Input: ask "Question?"
  • Remember User Input: remember variable_name

Output and Interaction

  • Print to Console: say "Message" + variable
  • Pause Execution: pause

GUI Elements

  • Create Window: window "Window Title"
  • Set Window Size: windowsize "width,height"
  • Add Button: button "Button Text" "Command"
  • Add Label: label "Label Text"
  • Show Window: show window
  • Display Message Box: message "Message Text"

GUI Input Elements

  • Create Entry Field: var entry_name = entry
  • Create Text Area: var text_name = text
  • Get Entry Value: get entry variable_name entry_name

AI Integration (Google Gemini) (unfinished)

  • Configure Gemini: configure_gemini "API_KEY"
  • Generate Content: generate_content "Prompt"

Text Manipulation

  • Append Text: append_text variable_name "Text to append"

Advanced GUI Features

  • Button with Custom Location:

button "Button Text" "Command" objectLocation = x,y text

Example Script

window "My First Fluxel App" windowsize "300,200" label "Welcome to Fluxel!" var name_entry = entry button "Say Hello" "get entry name name_entry message "Hello, " + name + "!" " show window text

Notes

  • The interpreter automatically adds a pause at the end of each script execution.
  • GUI elements are packed vertically by default unless a specific location is provided.
  • The Gemini AI integration requires a valid API key from Google.

Contributing

Contributions to Fluxel are welcome! Please feel free to submit a Pull Request.

License

This project is licensed under the GNU GENERAL PUBLIC License - see the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fluxel-0.3.0.tar.gz (6.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fluxel-0.3.0-py3-none-any.whl (6.4 kB view details)

Uploaded Python 3

File details

Details for the file fluxel-0.3.0.tar.gz.

File metadata

  • Download URL: fluxel-0.3.0.tar.gz
  • Upload date:
  • Size: 6.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for fluxel-0.3.0.tar.gz
Algorithm Hash digest
SHA256 1978a7e54d3d665822f0b9e8accc037d98ccf2f2d4fb1e168573fb0ee2a3b084
MD5 173833cb0e5a4ea0bc1e082c5e8a352f
BLAKE2b-256 f517aa86770b412a892da597bfba9e9cd5209fa5a7b3818fff6b4316a2ebb341

See more details on using hashes here.

File details

Details for the file fluxel-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: fluxel-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 6.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for fluxel-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fe38be3f987ceb8bf5d7f42720b358f4c3a352d17da3e86600f7567983c171e3
MD5 cb510a8fe796ce55dfa4b3d80642bbb0
BLAKE2b-256 8db278a2282e1d102fca2b01b7ed555175b0e1f316aa28392e607fe59c868106

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page