diff --git a/build.lua b/build.lua index fd32f8e..46aa4b8 100644 --- a/build.lua +++ b/build.lua @@ -3,7 +3,7 @@ return { name = 'Jeopardy', -- name of the game for your executable developer = 'Ryan Ward', -- dev name used in metadata of the file output = 'bin', -- output location for your game, defaults to $SAVE_DIRECTORY - version = '1.0.4', -- 'version' of your game, used to name the folder in output + version = '1.0.5', -- 'version' of your game, used to name the folder in output love = '11.5', -- version of LÖVE to use, must match github releases ignore = {'bin', 'love', 'server_test', '.gitignore', '.gitmodules', 'build.lua', 'login_dialog.yaml', 'package.bat', 'README.md'}, -- folders/files to ignore in your project icon = 'assets/icon.png', -- 256x256px PNG icon for game, will be converted for you diff --git a/gui b/gui index 27995af..351f276 160000 --- a/gui +++ b/gui @@ -1 +1 @@ -Subproject commit 27995af07f02c80cc99a0283f06d85a1bd2461f7 +Subproject commit 351f2762d5eaac8b63c3482e5bbb20bdecd1b58a diff --git a/menus/board.lua b/menus/board.lua index e4e7215..97ed021 100644 --- a/menus/board.lua +++ b/menus/board.lua @@ -171,6 +171,12 @@ function LoadTemplate(name, path) ALIGN_LEFT = gui.ALIGN_LEFT, ALIGN_RIGHT = gui.ALIGN_RIGHT, ALIGN_JUSTIFY = gui.ALIGN_JUSTIFY, + IMAGE = "image", + AUDIO = "audio", + VIDEO = "video", + TEXT = "text", + LIST = "list", + NUMBER = "number", -- Global vars color = color, error = multi.error, @@ -182,6 +188,7 @@ function LoadTemplate(name, path) -- love stuff newSource = love.audio.newSource, log = templateLog, + } env._G = env diff --git a/templates/imageword.lua b/templates/imageword.lua index 9347dea..3d7108e 100644 --- a/templates/imageword.lua +++ b/templates/imageword.lua @@ -44,6 +44,11 @@ local function index(window, q, callback) }, imageHolder, plusLabel, imageHolder2) useDefaultHandler(callback) + + return { + {imageA=IMAGE, description="First image to display"}, + {imageB=IMAGE, description="Second image to display"}, + } end local function update(dt) diff --git a/templates/multiplechoice.lua b/templates/multiplechoice.lua index c398292..c6cb600 100644 --- a/templates/multiplechoice.lua +++ b/templates/multiplechoice.lua @@ -84,6 +84,11 @@ local function index(window, q, callback) end end, },confirm) + + -- Return the expected types + return { + {choices=LIST, description="List of options"} + } end local function update(dt) -- time in seconds that has passed since diff --git a/templates/one-image.lua b/templates/one-image.lua index 68c4817..47dfc1f 100644 --- a/templates/one-image.lua +++ b/templates/one-image.lua @@ -29,6 +29,11 @@ local function index(window, q, callback) imageHolder:setDualDim(0,0,imageHolder.imageWidth,imageHolder.imageHeight) useDefaultHandler(callback) + + -- Return the expected types + return { + {image=IMGAE, description="Image the question is about"} + } end local function update(dt) -- time in seconds that has passed since diff --git a/templates/whatsound.lua b/templates/whatsound.lua index 31f7c6f..28157e8 100644 --- a/templates/whatsound.lua +++ b/templates/whatsound.lua @@ -44,6 +44,11 @@ local function index(window, q, callback) end) useDefaultHandler(callback) + + -- Return the expected types + return { + {sound=AUDIO, description="Sound that will be played"} + } end local function update(dt) -- time in seconds that has passed since diff --git a/templates/whatvideo.lua b/templates/whatvideo.lua index 66b6bb7..26b7a78 100644 --- a/templates/whatvideo.lua +++ b/templates/whatvideo.lua @@ -36,6 +36,11 @@ local function index(window, q, callback) video.XButton.visible = false useDefaultHandler(callback) + + -- Return the expected types + return { + {video=VIDEO, description="Video that will be played"} + } end local function update(dt) -- time in seconds that has passed since diff --git a/templates/zoom.lua b/templates/zoom.lua index 6418faa..e8992c6 100644 --- a/templates/zoom.lua +++ b/templates/zoom.lua @@ -73,6 +73,22 @@ local function index(window, q, callback) end) useDefaultHandler(callback) + + -- Return the expected types + return { + { + zoom=IMAGE, + description = "Full zoom in on an image" + }, + { + minzoom=IMAGE, + description = "Minimum zoom before the full image is revealed" + }, + { + fullimage=IMAGE, + description = "Full image to show" + } + } end local function update(dt) -- time in seconds that has passed since