﻿# Introduction
It's very easy to make and add missions to NOOSE mod. I included a coordinate recorder activated by NumPad Dot (Decimal) which will create a file in NOOSEMissions\Coordinates.txt
The missions have a XML syntax. All of the elements must be wrapped in a root tag, <Mission></Mission>.
Then we have 4 elements inside: MetaInfo, EntryPoints, Enemies and DecorativeVehicles.

# MetaInfo
This is the section which contains data about the mission itself (metadata).
Things like
* Name
* Info
* Enabled (true/false)
* CameraPos - defines the camera position when selecting the missions.
* RequiredIPL - if your mission needs any IPL to load. This is optional.
<RequiredIPL>
	<IPL remove="true">cargoboat</IPL> <- This IPL will be removed while the mission is active, and then re-added when the mission ends.
	<IPL>anotherOne</IPL>
</RequiredIPL>

# EntryPoints
This section defines the entry points of the mission. You can have as many entry points as you want.
There are 3 types of entry points:
 - teleport: Instantly teleports the player to the coordinates.
 - rappel: Player spawns in a helicopter and then flies to the coordinates and rappels down.
 - plane: Player spawns in a plane and gets flown to the destination, landing the plane.
Every type has their own arguments but they all share one: the Name.

# teleport EntryPoint
- Name
- Position with x,y,z and heading attributes
<EntryPoint type="teleport">
  <Name>Front</Name>
  <Position x="81.6684" y="3596.262" z="39.72292" heading="5.505774"/>
</EntryPoint>

# rappel EntryPoint
- Name
- Destination (of the helicopter)
- Helipads (list)
-- 2 of Helipad with attributes x,y,z
<EntryPoint type="rappel">
    <Name>Helicopter</Name>
    <Helipads>
		<Helipad x="1770.297" y="3238.947" z="41.6537"/>
		<Helipad x="1775.372" y="3275.426" z="41.18471"/>
    </Helipads>
    <Destination x="-23.28014" y="3666.868" z="54.55974"/>
</EntryPoint>

# plane EntryPoint
- Name
- PlaneSpawn: has attributes x,y,z, this is where the plane spawns.
- PlaneHeading: plane heading when it spawns.
- Approach: x,y,z of the position where the landing begins. This is generally in front of the airport, high in the air.
- RunwayStart: start of the runway.
- RunwayEnd: end of the runway. If the pilot overflies the runway, make the RunwayEnd in the middle of your runway.
<EntryPoint type="plane">
	<Name>Plane</Name>
	<PlaneSpawn x="1775.372" y="3275.426" z="41.18471"/>
	<PlaneHeading>180</PlaneHeading>
	<Approach x="1775.372" y="3275.426" z="41.18471"/>
	<RunwayStart x="1775.372" y="3275.426" z="41.18471"/>
	<RunwayEnd x="1775.372" y="3275.426" z="41.18471"/>
</EntryPoint>

# Enemies
This is where you define your enemies. Each line represents one enemy and has attributes x,y,z, and heading.
<Enemies>
	<Enemy x="96.46419" y="3750.036" z="40.71968" heading="70.04143"/>
</Enemies>

# DecorativeVehicles
This section is optional, but you have to include it, even if empty. Defines empty vehicles to spawn in the world.
The spawn attribute indicates whether to spawn always (-1) or when the player chooses a specific entry point (0,1,2, etc).

This vehicle will always spawn:
<Vehicle model="Police" x="7.751782" y="3601.629" z="40.11242" heading="174.1431" spawn="-1"/>

This vehicle will only spawn when the player chooses the first entry point:
<Vehicle model="Dinghy2" x="181.5672" y="3660.32" z="30.12024" heading="45.93738" spawn="0"/>

There are also optional attributes for your vehicles:
- siren: true/false whether the siren should be on
- doors: bitmask for which doors to open. the order is left-front, right-front, left-rear, right-rear
	ex: "0011" would open the back doors, "1010" would open left doors and "1111" would open all doors.

See BikersHideout.xml for an example reference.