mirror of
https://github.com/stevenhowes/CTheEscape.git
synced 2026-05-26 15:53:29 +01:00
Event scheduling
This commit is contained in:
@@ -96,6 +96,28 @@
|
||||
$eventactions[] = array("Event"=>$inevent,"Action"=>3,"ActionValue"=>255,"ActionTarget"=>$target);
|
||||
}
|
||||
break;
|
||||
case "Schedule":
|
||||
if($inevent < 0)
|
||||
{
|
||||
echo " Invalid outside event\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
$csv = str_getcsv($split[1]);
|
||||
|
||||
$target = -1;
|
||||
foreach($events as $eventid=>$event)
|
||||
{
|
||||
if($event['Name'] == $csv[0])
|
||||
$target = $eventid;
|
||||
}
|
||||
|
||||
if($target < 0)
|
||||
echo " Unknown target: " . $csv[0] . "\n";
|
||||
else
|
||||
$eventactions[] = array("Event"=>$inevent,"Action"=>4,"ActionValue"=>$target,"ActionTarget"=>$csv[1]);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
echo " Unknown command: " . $split[0] . "\n";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user