aboutsummaryrefslogtreecommitdiff
path: root/engines/lastexpress/entities/entity.cpp
diff options
context:
space:
mode:
authorJulien2012-07-25 17:55:17 -0400
committerJulien2012-07-27 00:15:03 -0400
commit938961e23737e5ff19aee61e1ec6dd6e19ca0529 (patch)
treee17a171a96f9b781ed0b43f503e1c46ead9b3660 /engines/lastexpress/entities/entity.cpp
parentb6b98483c5117ee3cee0a52607e5f5f4acb7def7 (diff)
downloadscummvm-rg350-938961e23737e5ff19aee61e1ec6dd6e19ca0529.tar.gz
scummvm-rg350-938961e23737e5ff19aee61e1ec6dd6e19ca0529.tar.bz2
scummvm-rg350-938961e23737e5ff19aee61e1ec6dd6e19ca0529.zip
LASTEXPRESS: Remove TIME_CHECK_CALLBACK_1 macro
Diffstat (limited to 'engines/lastexpress/entities/entity.cpp')
-rw-r--r--engines/lastexpress/entities/entity.cpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/engines/lastexpress/entities/entity.cpp b/engines/lastexpress/entities/entity.cpp
index 48856a7bc4..9160b6db95 100644
--- a/engines/lastexpress/entities/entity.cpp
+++ b/engines/lastexpress/entities/entity.cpp
@@ -660,6 +660,30 @@ bool Entity::timeCheckCallback(TimeValue timeValue, uint &parameter, byte callba
return false;
}
+bool Entity::timeCheckCallback(TimeValue timeValue, uint &parameter, byte callback, const char *str, Common::Functor1<const char *, void> *function) {
+ if (getState()->time > timeValue && !parameter) {
+ parameter = 1;
+ setCallback(callback);
+ (*function)(str);
+
+ return true;
+ }
+
+ return false;
+}
+
+bool Entity::timeCheckCallback(TimeValue timeValue, uint &parameter, byte callback, bool check, Common::Functor1<bool, void> *function) {
+ if (getState()->time > timeValue && !parameter) {
+ parameter = 1;
+ setCallback(callback);
+ (*function)(check);
+
+ return true;
+ }
+
+ return false;
+}
+
bool Entity::timeCheckCallbackInventory(TimeValue timeValue, uint &parameter, byte callback, Common::Functor0<void> *function) {
if (getState()->time > timeValue && !parameter) {
parameter = 1;