Giter VIP home page Giter VIP logo

gate's Introduction

GATE

โš  Warning! GATE is currently undergoing heavy development and is not yet production-ready! An engine integration will soon follow.

GATE is a GDScript superset for the Godot Engine that adds extra features while compiling down to native GDScript.

Table of Content

Usage

Download the latest build for your OS from here and use it as follows:

# --input, -i
#    Path to the input `.gate` file/directory.
#    Note: Only `.gate` files are read.
#
# --output, -i
#    Path to the output directory.
#    Note: The output directory respects the input layout.

./gate --input ./path/to/myFile.gate --output ./output

Features

Dynamic Variable Decorator $$

The $$ decorator automates signal, setter, getter, and connection creation.

Example
class_name Test extends Label

$$count = 0

func _ready() -> void:
    count += 1

func count_changed(value: int) -> void:
  text = "Count is %s" % value

Optional Operator ?.

The ?. (optional) operator allows you to check for null in a chain of properties. Note: This currently only works with variable!

Example
func _ready() -> void:
    # In this case `text` is either `null` or the
    # expected value of `myProp`
    var text = $MyNode?.myObject?.myProp

Upcoming features

  • Loop ranges 2..15
    • for i in 2..15:
  • Spread operator ...
    • var arr = [0, 1, 2]
      var numbers = [...arr, 3, 4, 5]
  • Rest operator ...
    • myFunction(a, b, c, d, e)
      func myFunction(first, second, ...rest)
  • Destructuring [_, _]
    • var [parm1, param2] = myFunction()
  • Inline templates
    • var x = `${player1} killed ${player2}`
  • Optional chaining ?.
    • var x = $node.?thing.?deeper1.?deeper2

Contributing

GATE is made using Bun with TypeScript.

To install dependencies:

bun install

To run:

bun run dev

To build:

bun run build
# or
bun run build:win
bun run build:linux
bun run build:mac

gate's People

Contributors

blade67 avatar

Stargazers

oyin avatar Duncan Beevers avatar Leonardo Amaro avatar SonNH avatar  avatar Anthony Froissant avatar  avatar  avatar Dan Peavey avatar Jonas Reitan avatar Quentium avatar bbb651 ๐Ÿ‡ฎ๐Ÿ‡ฑ avatar Tibi avatar  avatar

Watchers

 avatar lena avatar

Forkers

zackeryrsmith

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.