version 1.61 | | version 1.62 |
---|
| | |
/* | | /* |
* static char *rcsid_time_c = | | * static char *rcsid_time_c = |
* "$Id: time.c,v 1.61 2004/04/10 03:18:54 temitchell Exp $"; | | * "$Id: time.c,v 1.62 2004/05/14 05:55:56 mwedel Exp $"; |
*/ | | */ |
| | |
/* | | /* |
| | |
void move_teleporter(object *op) { | | void move_teleporter(object *op) { |
object *tmp, *head=op; | | object *tmp, *head=op; |
event *evt; | | event *evt; |
| | |
/* if this is a multipart teleporter, handle the other parts | | /* if this is a multipart teleporter, handle the other parts |
* The check for speed isn't strictly needed - basically, if | | * The check for speed isn't strictly needed - basically, if |
* there is an old multipart teleporter in which the other parts | | * there is an old multipart teleporter in which the other parts |
| | |
if (!tmp) return; | | if (!tmp) return; |
| | |
if(EXIT_PATH(head)) { | | if(EXIT_PATH(head)) { |
if(op->above->type==PLAYER) | | if(op->above->type==PLAYER) { |
{ | | |
/* GROS: Handle for plugin TRIGGER event */ | | /* GROS: Handle for plugin TRIGGER event */ |
if ((evt = find_event(op, EVENT_TRIGGER)) != NULL) | | if ((evt = find_event(op, EVENT_TRIGGER)) != NULL) { |
{ | | |
CFParm CFP; | | CFParm CFP; |
CFParm* CFR; | | CFParm* CFR; |
int k, l, m; | | int k, l, m; |
| | |
CFP.Value[8] = &l; | | CFP.Value[8] = &l; |
CFP.Value[9] = evt->hook; | | CFP.Value[9] = evt->hook; |
CFP.Value[10]= evt->options; | | CFP.Value[10]= evt->options; |
if (findPlugin(evt->plugin)>=0) | | if (findPlugin(evt->plugin)>=0) { |
{ | | |
CFR = (PlugList[findPlugin(evt->plugin)].eventfunc) (&CFP); | | CFR = (PlugList[findPlugin(evt->plugin)].eventfunc) (&CFP); |
rtn_script = *(int *)(CFR->Value[0]); | | rtn_script = *(int *)(CFR->Value[0]); |
} | | } |
| | |
} | | } |
transfer_ob(tmp,EXIT_X(head),EXIT_Y(head),0,head); | | transfer_ob(tmp,EXIT_X(head),EXIT_Y(head),0,head); |
} | | } |
else | | else { |
{ | | |
/* Random teleporter */ | | /* Random teleporter */ |
/* GROS: Handle for plugin TRIGGER event */ | | /* GROS: Handle for plugin TRIGGER event */ |
if ((evt = find_event(op, EVENT_TRIGGER)) != NULL) | | if ((evt = find_event(op, EVENT_TRIGGER)) != NULL) { |
{ | | |
CFParm CFP; | | CFParm CFP; |
CFParm* CFR; | | CFParm* CFR; |
int k, l, m; | | int k, l, m; |
| | |
CFP.Value[8] = &l; | | CFP.Value[8] = &l; |
CFP.Value[9] = evt->hook; | | CFP.Value[9] = evt->hook; |
CFP.Value[10]= evt->options; | | CFP.Value[10]= evt->options; |
if (findPlugin(evt->plugin)>=0) | | if (findPlugin(evt->plugin)>=0) { |
{ | | |
CFR = (PlugList[findPlugin(evt->plugin)].eventfunc) (&CFP); | | CFR = (PlugList[findPlugin(evt->plugin)].eventfunc) (&CFP); |
rtn_script = *(int *)(CFR->Value[0]); | | rtn_script = *(int *)(CFR->Value[0]); |
} | | } |