Tutorial 00002: Respawn with contents.

Otherwise it's very easy to lose your shovel in the acid lake and fail.

(You can still fail by throwing it in though)
shapetextures
Sven Eberhardt 2015-09-13 12:53:06 -04:00
parent eb9e640b67
commit 889a8dbdf9
1 changed files with 3 additions and 0 deletions

View File

@ -472,6 +472,9 @@ global func FxClonkRestoreStop(object target, effect, int reason, bool temporar
SetCursor(plr, clonk);
clonk->DoEnergy(100000);
restorer->SetRestoreObject(clonk, nil, to_x, to_y, 0, "ClonkRestore");
// Transfer contents
var i = target->ContentsCount(), contents_obj;
while (i--) if (contents_obj = target->Contents(i)) contents_obj->Enter(clonk);
}
return FX_OK;
}