All pastes #904438 Raw Edit

EiR.lua

public lua v1 · immutable
·published 2008-02-14 22:58 UTC
rendered paste body
-- Load overlay DLL and auxiliary Lua codeif not spooge then  loadfile("lua-spooge.dll", "luaopen_spooge")()endassert(loadfile [[EuropeInRuins\UI\window.lua]] )()-- Create new windowtest_window = window.new{width = 275, height = 275}OVERLAY:addChild(test_window)-- Helper function to create a buttonfunction add_btn(o)  o = o or {}  o.left = o.left or 5  o.top = o.top or 25  o.parent = o.parent or test_window  return button.new(o)end-- Helper function for resizing windowfunction adjustsize(x)  test_window:resize(test_window.width + x, test_window.height + x)end-- Create buttonsadd_btn{text = "Bigger" , top = 50, click = function() adjustsize( 5) end}add_btn{text = "Smaller", top = 25, click = function() adjustsize(-5) end}