From dc202d0fa7f1986127c59ddbb488bbfb998efcb0 Mon Sep 17 00:00:00 2001 From: Josh Goldberg Date: Sat, 27 Feb 2016 18:46:19 -0800 Subject: [PATCH] Added TS compilation to settings files in grunt Updated GameStartr to make it work. --- Gruntfile.js | 10 ++++++++-- Source/References/GameStartr-0.2.0.ts | 8 ++++++-- Source/settings/menus.ts | 6 +++--- 3 files changed, 17 insertions(+), 7 deletions(-) diff --git a/Gruntfile.js b/Gruntfile.js index b4cc5dba..6e857622 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -21,10 +21,16 @@ module.exports = function (grunt) { }, "typescript": { "base": { - "src": "<%= meta.paths.source %>/<%= pkg.name %>.ts" + "src": [ + "<%= meta.paths.source %>/<%= pkg.name %>.ts", + "<%= meta.paths.source %>/settings/**/*.ts" + ] }, "distribution": { - "src": "<%= meta.paths.source %>/<%= pkg.name %>.ts", + "src": [ + "<%= meta.paths.source %>/<%= pkg.name %>.ts", + "<%= meta.paths.source %>/settings/**/*.ts" + ], "dest": "<%= meta.paths.dist %>/<%= pkg.name %>-<%= pkg.version %>.js" } }, diff --git a/Source/References/GameStartr-0.2.0.ts b/Source/References/GameStartr-0.2.0.ts index f7a7cf5b..bf19dacf 100644 --- a/Source/References/GameStartr-0.2.0.ts +++ b/Source/References/GameStartr-0.2.0.ts @@ -397,11 +397,15 @@ declare module GameStartr { /** * Function for when a PreThing is to be spawned. + * + * @param prething A PreThing entering the map. */ onSpawn?: (prething: MapsCreatr.IPreThing) => void; /** * Function for when a PreThing is to be un-spawned. + * + * @param prething A PreThing leaving the map. */ onUnspawn?: (prething: MapsCreatr.IPreThing) => void; @@ -425,12 +429,12 @@ declare module GameStartr { /** * If stretches exists, a Function to add stretches to an Area. */ - stretchAdd: AreaSpawnr.ICommandAdder; + stretchAdd?: AreaSpawnr.ICommandAdder; /** * If afters exists, a Function to add afters to an Area. */ - afterAdd: AreaSpawnr.ICommandAdder; + afterAdd?: AreaSpawnr.ICommandAdder; /** * Macro functions to create PreThings, keyed by String alias. diff --git a/Source/settings/menus.ts b/Source/settings/menus.ts index 29ffbe28..ea8b4373 100644 --- a/Source/settings/menus.ts +++ b/Source/settings/menus.ts @@ -209,7 +209,7 @@ module FullScreenPokemon { } } }, - { + { "type": "menu", "name": "PokedexNumbers" }], @@ -255,7 +255,7 @@ module FullScreenPokemon { "textSpeed": 0, "textPaddingY": 4 }, - "PokedexOptions": { + "PokedexOptions": { "size": { "width": 21.5, "height": 37 @@ -276,7 +276,7 @@ module FullScreenPokemon { "textXOffset": 4, "textYOffset": 5 }, - "PokedexListing": { + "PokedexListing": { "size": { "width": 80, "height": 72