disp in gui mode only, enter/entered in main

This commit is contained in:
p.kosyh 2010-07-12 08:20:41 +00:00
parent f5d7abc895
commit 0bf05ebd90
3 changed files with 13 additions and 2 deletions

2
debian/changelog vendored
View file

@ -24,6 +24,8 @@ instead (1.2.0) unstable; urgency=low
* visited() added;
* live() added;
* nameof() added;
* goback() added;
* disp attribute added;
* improved debugger;
* save vars in _G;
* no duplicated games while looking gamespaths;

View file

@ -204,6 +204,9 @@ end)
player = stead.inherit(player, function(v)
v.look = function(s)
if game._time == 0 then
return stead.goto(here(), false, false, true);
end
NEED_SCENE = true
end
return v

View file

@ -169,7 +169,10 @@ function list_str(self)
for i,o in opairs(self) do
o = ref(o);
if isObject(o) and not isDisabled(o) then
vv = call(o, 'disp');
vv = nil
if game.gui then
vv = call(o, 'disp');
end
if type(vv) ~= 'string' then
vv = call(o, 'nam');
end
@ -191,7 +194,10 @@ function obj_str(self)
for i,o in opairs(self.obj) do
o = ref(o);
if isObject(o) and not isDisabled(o) then
vv = call(o, 'disp');
vv = nil
if game.gui then
vv = call(o, 'disp');
end
if type(vv) ~= 'string' then
vv = call(o, 'nam');
end