aboutsummaryrefslogtreecommitdiff
path: root/engines/tinsel/actors.cpp
diff options
context:
space:
mode:
authorMax Horn2008-07-24 08:59:17 +0000
committerMax Horn2008-07-24 08:59:17 +0000
commit69dac1d4f22f9a63a5a9030d4405ba071e5e8b89 (patch)
tree82f7bd95c3a03b3d4e363e26eecdc36fe3e8b600 /engines/tinsel/actors.cpp
parent627e0c277426b02153b79c82616ae7f351ad5bc3 (diff)
downloadscummvm-rg350-69dac1d4f22f9a63a5a9030d4405ba071e5e8b89.tar.gz
scummvm-rg350-69dac1d4f22f9a63a5a9030d4405ba071e5e8b89.tar.bz2
scummvm-rg350-69dac1d4f22f9a63a5a9030d4405ba071e5e8b89.zip
Moved scheduler / process managment code into a new class Scheduler
svn-id: r33259
Diffstat (limited to 'engines/tinsel/actors.cpp')
-rw-r--r--engines/tinsel/actors.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/engines/tinsel/actors.cpp b/engines/tinsel/actors.cpp
index 7ea2da28f6..5e4a17fb65 100644
--- a/engines/tinsel/actors.cpp
+++ b/engines/tinsel/actors.cpp
@@ -174,14 +174,14 @@ struct ATP_INIT {
/**
* Runs actor's glitter code.
*/
-static void ActorTinselProcess(CORO_PARAM) {
+static void ActorTinselProcess(CORO_PARAM, const void *param) {
// COROUTINE
CORO_BEGIN_CONTEXT;
PINT_CONTEXT pic;
CORO_END_CONTEXT(_ctx);
// get the stuff copied to process when it was created
- ATP_INIT *atp = (ATP_INIT *)ProcessGetParamsSelf();
+ ATP_INIT *atp = (ATP_INIT *)param;
CORO_BEGIN_CODE(_ctx);
@@ -207,14 +207,14 @@ struct RATP_INIT {
int id; // Actor number
};
-static void ActorRestoredProcess(CORO_PARAM) {
+static void ActorRestoredProcess(CORO_PARAM, const void *param) {
// COROUTINE
CORO_BEGIN_CONTEXT;
PINT_CONTEXT pic;
CORO_END_CONTEXT(_ctx);
// get the stuff copied to process when it was created
- RATP_INIT *r = (RATP_INIT *)ProcessGetParamsSelf();
+ RATP_INIT *r = (RATP_INIT *)param;
CORO_BEGIN_CODE(_ctx);
@@ -230,7 +230,7 @@ static void ActorRestoredProcess(CORO_PARAM) {
void RestoreActorProcess(int id, PINT_CONTEXT pic) {
RATP_INIT r = { pic, id };
- ProcessCreate(PID_TCODE, ActorRestoredProcess, &r, sizeof(r));
+ g_scheduler->createProcess(PID_TCODE, ActorRestoredProcess, &r, sizeof(r));
}
/**
@@ -247,7 +247,7 @@ void actorEvent(int ano, USER_EVENT event, BUTEVENT be) {
atp.id = ano;
atp.event = event;
atp.bev = be;
- ProcessCreate(PID_TCODE, ActorTinselProcess, &atp, sizeof(atp));
+ g_scheduler->createProcess(PID_TCODE, ActorTinselProcess, &atp, sizeof(atp));
}
}