check_version is now do require 'goto'
This commit is contained in:
parent
a6b4794e13
commit
40aed624e5
|
@ -45,24 +45,23 @@ go = function (self, where, back)
|
||||||
self.where = deref(where);
|
self.where = deref(where);
|
||||||
end
|
end
|
||||||
|
|
||||||
if not back or not isDialog(ref(self.where)) or isDialog(ref(where)) then
|
v, r = call(ref(where), 'enter', deref(was));
|
||||||
v, r = call(ref(where), 'enter', deref(was));
|
if r == false then
|
||||||
if r == false then
|
self.where = was;
|
||||||
self.where = was;
|
return par('^^', res, v), ret(r)
|
||||||
return par('^^', res, v), ret(r)
|
|
||||||
end
|
|
||||||
need_scene = true;
|
|
||||||
if ref(where) ~= ref(self.where) then -- jump !!!
|
|
||||||
need_scene = false;
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
need_scene = true;
|
||||||
|
if ref(where) ~= ref(self.where) then -- jump !!!
|
||||||
|
need_scene = false;
|
||||||
|
end
|
||||||
|
|
||||||
res = par('^^',res,v);
|
res = par('^^',res,v);
|
||||||
|
|
||||||
if not back then
|
if not back then
|
||||||
ref(where).__from__ = deref(was);
|
ref(where).__from__ = deref(was);
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
ret()
|
ret()
|
||||||
|
|
||||||
if not stead.in_goto_call then
|
if not stead.in_goto_call then
|
||||||
|
@ -82,7 +81,6 @@ go = function (self, where, back)
|
||||||
res = par('^^',res,v);
|
res = par('^^',res,v);
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
if need_scene then -- or isForcedsc(ref(where)) then -- i'am not sure...
|
if need_scene then -- or isForcedsc(ref(where)) then -- i'am not sure...
|
||||||
return par('^^',res,ref(where):scene());
|
return par('^^',res,ref(where):scene());
|
||||||
end
|
end
|
||||||
|
|
|
@ -2409,6 +2409,9 @@ function check_version(v)
|
||||||
if stead.version < v then
|
if stead.version < v then
|
||||||
error ([[The game requires instead engine of version ]] ..v.. [[ or higher. http://instead.googlecode.com]])
|
error ([[The game requires instead engine of version ]] ..v.. [[ or higher. http://instead.googlecode.com]])
|
||||||
end
|
end
|
||||||
|
if v >= "1.2.0" then
|
||||||
|
require ("goto")
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
--- here the game begins
|
--- here the game begins
|
||||||
|
|
Loading…
Reference in a new issue