Skip to content

Instantly share code, notes, and snippets.

@DenisBelmondo
Last active February 1, 2023 02:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DenisBelmondo/e6423945692e0b15b1421f68faf819c6 to your computer and use it in GitHub Desktop.
Save DenisBelmondo/e6423945692e0b15b1421f68faf819c6 to your computer and use it in GitHub Desktop.
Test case for ZScript default and state block syntax highlighting
// observe that the highlighting for state blocks does not break when on top
// of default blocks and vice versa.
class SomeInventory : Inventory
{
default
{
// hopefully, "Inventory" here will be highlighted as "entity.name.class.zscript"
Inventory.PickupMessage "You will never see this message ingame!";
// same here:
+Inventory.QUIET;
-Inventory.INVBAR;
}
states // keyword.control.directive.zscript
{
Use: // entity.name.class.state.zscript
TNT1 A -1 A_StartSound("SomeSound", CHAN_AUTO);
stop; // keyword.control.states.zscript
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment