1.0.12 • Published 5 years ago

@onfire-network/onset-typescript-api v1.0.12

Weekly downloads
13
License
ISC
Repository
github
Last release
5 years ago

OnsetTypescriptAPI

Typescript API Wrapper for the Onset API

Description

This framework allows you to develop gamemodes in typescript. It contains definitions for all Onset api functions and wraps them with a nice object-oriented api. It also comes with a build-script to automatically compile all source files into just 2 lua files.

Usage

First make sure you have node installed. Running the following commands will initialize a new gamemode project for you.

mkdir YOUR_PROJECT_NAME
cd YOUR_PROJECT_NAME
npm init
npm install @onfire-network/onset-typescript-builder --save
npx otb init

If your project is not a gamemode, but a library to use in another gamemode run init-lib instead of init. The scaffoling will include 3 folders (client, server, common) which are used to seperate code by execution side. The client and server folder will each contain an init.js which will be the entrypoint of your gamemode.

To build your gamemode just run:

npx otb

This will create a target folder containing a client and server folder with your lua scripts. These scripts are already kind of optimized, but not minified. If you wish to minify them just run:

npx otb prod

Other Libraries to use with OnsetTypescriptAPI

1.0.12

5 years ago

1.0.11

5 years ago

1.0.10

5 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago