forked from Mirrors/openclonk
Remove Rule_Restart
parent
dcc240e01a
commit
db6047c22a
|
@ -1,7 +0,0 @@
|
|||
[DefCore]
|
||||
id=Rule_Restart
|
||||
Version=8,0
|
||||
Category=C4D_StaticBack|C4D_Rule
|
||||
Width=32
|
||||
Height=32
|
||||
Offset=-16,-16
|
Binary file not shown.
Before Width: | Height: | Size: 5.2 KiB |
|
@ -1,39 +0,0 @@
|
|||
/*-- Restart --*/
|
||||
|
||||
local remove_contents;
|
||||
|
||||
protected func Initialize()
|
||||
{
|
||||
// Contents are removed
|
||||
remove_contents = true;
|
||||
return;
|
||||
}
|
||||
|
||||
public func Activate(int plr)
|
||||
{
|
||||
// Notify scenario.
|
||||
if (GameCall("OnPlayerRestart", plr))
|
||||
return;
|
||||
// Remove the player's clonk, including contents.
|
||||
var clonk = GetCrew(plr);
|
||||
if (clonk && clonk->GetCrewEnabled())
|
||||
{
|
||||
// Remove contents only if the Base Respawn Rule isn't there otherwise it will handle inventory
|
||||
if (!ObjectCount(Find_ID(Rule_BaseRespawn)) && remove_contents)
|
||||
while (clonk->Contents())
|
||||
clonk->Contents()->RemoveObject();
|
||||
clonk->Kill(clonk, true);
|
||||
clonk->RemoveObject();
|
||||
}
|
||||
}
|
||||
|
||||
public func SetRemoveContents(bool do_removal)
|
||||
{
|
||||
remove_contents = do_removal;
|
||||
return;
|
||||
}
|
||||
|
||||
local Name = "$Name$";
|
||||
local Description = "$Description$";
|
||||
local Visibility = VIS_Editor;
|
||||
local EditorPlacementLimit = 1; // Rules are to be placed only once
|
|
@ -1,2 +0,0 @@
|
|||
Name=Neu starten
|
||||
Description=Diese Spielregel erlaubt dem Spieler nochmal von vorne zu beginnen.
|
|
@ -1,2 +0,0 @@
|
|||
Name=Restart
|
||||
Description=This rule allows the player to start again.
|
Loading…
Reference in New Issue