onexit/onenter actions
This commit is contained in:
parent
59604c4a8a
commit
5146a50899
|
@ -120,7 +120,8 @@ int main(int argc, char **argv)
|
|||
p = games_sw;
|
||||
else
|
||||
p = game_local_games_path(1);
|
||||
setup_zip(file, p);
|
||||
if (setup_zip(file, p))
|
||||
exit(1);
|
||||
}
|
||||
#endif
|
||||
} else if (!strcmp(argv[i], "-quit")) {
|
||||
|
@ -136,7 +137,8 @@ int main(int argc, char **argv)
|
|||
p = games_sw;
|
||||
else
|
||||
p = game_tmp_path();
|
||||
setup_zip(argv[i], p);
|
||||
if (setup_zip(argv[i], p))
|
||||
exit(1);
|
||||
clean_tmp = 1;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -1114,12 +1114,17 @@ function go(self, where, back)
|
|||
res = par('^^',res,v);
|
||||
if not back then
|
||||
ref(where).__from__ = deref(self.where);
|
||||
end
|
||||
end
|
||||
|
||||
v = call(ref(was), 'onexit', deref(where));
|
||||
res = par('^^',res,v);
|
||||
self.where = deref(where);
|
||||
v = call(ref(where), 'onenter', deref(was));
|
||||
res = par('^^',res,v);
|
||||
|
||||
if need_scene then -- or isForcedsc(ref(where)) then -- i'am not sure...
|
||||
self.where = deref(where);
|
||||
return par('^^',res,ref(where):scene());
|
||||
end
|
||||
self.where = deref(where);
|
||||
return res;
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue