Skip to content

Commit

Permalink
Added mission Wrapper/Group/600-Respawn
Browse files Browse the repository at this point in the history
  • Loading branch information
kaltokri committed Feb 27, 2024
1 parent 2ed935f commit 75c22e2
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions Wrapper/Group/600-Respawn/GRP-600-Respawn.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
-- Author: FlightControl
-- Created: 01.03.2018
-- Contributors: kaltokri
-- Modified: 27.02.2024
--
-- # Documentation:
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Wrapper.Group.html
-- https://flightcontrol-master.github.io/MOOSE_DOCS_DEVELOP/Documentation/Core.Timer.html
--
-- # Description:
-- In this mission a vehicle will be damaged by Explode and then respawned with full health.
--
-- # Guide:
-- 1. Start the mission and wait 10 seconds.
-- 2. The Vehicle will be damaged.
-- 3. Wait additional 10 seconds and the Vehicle will be respawned with full health.

-- Find the Vehicle and create a GROUP object.
Vehicle = GROUP:FindByName( "Vehicle" )

-- Damage the vehicle with a delay of 10 seconds.
Vehicle:Explode( 1, 10 )
MESSAGE:New( "Vehicle will be damaged in 10 seconds and respawn in 20 seconds!", 10 ):ToAll():ToLog()

-- Respawn the vehicle 20 seconds after mission start.
TIMER:New(
function()
Vehicle:Respawn()
end
):Start( 20 )
Binary file added Wrapper/Group/600-Respawn/GRP-600-Respawn.miz
Binary file not shown.

0 comments on commit 75c22e2

Please sign in to comment.