From 3efc6b451c14ecb58e784f24adb74f9f0ee7a4f5 Mon Sep 17 00:00:00 2001 From: "p.kosyh" Date: Fri, 11 Jun 2010 09:12:19 +0000 Subject: [PATCH] check_version added --- stead/stead.lua | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/stead/stead.lua b/stead/stead.lua index 0152e41..c61dceb 100644 --- a/stead/stead.lua +++ b/stead/stead.lua @@ -2341,6 +2341,15 @@ function hook(o, f) end end +function check_version(v) + if not tostring(v) then + return + end + if stead.version < v then + error ([[The game requires instead engine of version ]] ..v.. [[ or higher. http://instead.googlecode.com]]) + end +end + --- here the game begins function stead_init() pl = player {