Skip to content

ClientScript Compiler - v1.0.0

Latest
Compare
Choose a tag to compare
@Joshua-F Joshua-F released this 08 Jan 00:34
· 3 commits to master since this release
179d178

The first open source version of the compiler.

There have been a number of changes since the initial Public Snapshot 1 release, some of which are breaking changes.

For help or questions join our discord.

Breaking changes

Trigger types renamed

trigger_45 -> updateobjstack
trigger_78 -> onclickloc
trigger_79 -> onclickobj
trigger_80 -> onclicknpc
trigger_81 -> onclickplayer

graphic and fontmetrics types relationship

Previously assigning a graphic to a fontmetrics type was allowed. At some point it was figured out that this is not actually a valid conversion based on enums existing to convert between the two.

Require empty parameter list

Previously parameter lists were not required, but now if a script returns something then the parameter list must still be defined, even if it is just ().

// Previously allowed
[proc,some_script](int)

// Must now be
[proc,some_script]()(int)

Configuration file (neptune.toml) changes

The excluded property was renamed to libraries.

Identifier token rules change

The identifier token rule has been changed to be more in line with how it is for RuneScape. This change removed the special case allowing the : (colon) character to only appear between other non-: characters. What this means is that a space is required after a case value.

// Previously allowed
switch_int ($x) {
    case 1: ....
}

// Must now be (note the space after the case 1)
switch_int ($x) {
    case 1 : ....
}

String literals no longer allow multi-line

This was never really intended and support for multi-line strings was removed.

Features

Fixes

Full Changelog: cs2-0.0.1-PUBLIC-SNAPSHOT1...cs2-1.0.0