<?lua
  include("overlay/hudtemplates3.oxo")
  include("overlay/stats.oxo")
  include("levels/templates/spaceship_assff.oxt")
?>

<NotificationQueue
	name  = "notification"
	position = "1.0, 1.0"
	targets = "all"
/>

<Level
 name         = "Questsystem"
 description  = "Just a few tests"
>
    <Scene
    ambientlight = "0.5, 0.5, 0.5"
    skybox       = "Orxonox/Starbox"
    >

        <GlobalQuest id="b80c2c60-e62c-4637-80f8-5aa18dc93b34">
            <QuestDescription title="The Main QUest" description="This is the main quest hooray. Solve it!" failMessage="You fail. Looser." completeMessage="You Win." />
            <hints>
                <QuestHint id="022a859d-08dd-4eac-a085-c28c29c06d48">
                    <QuestDescription title="The super Hint." description="Be proud of yourself." />
                </QuestHint>
            </hints>
        </GlobalQuest>

				<ParticleSpawner position="0,0,100" source="Orxonox/BigExplosion1part3" lifetime=2.0 loop=0 autostart=0>
				  <events>
				    <spawn>
				      <EventTrigger delay=1>
				        <events>
				          <trigger>
				            <SpawnPoint position="0,0,100" spawnclass=SpaceShip pawndesign=spaceshipassff />
				          </trigger>
				        </events>
				      </EventTrigger>
				    </spawn>
				  </events>
				</ParticleSpawner>

        <QuestEffectBeacon position="0,0,100" times=-1>
            <effects>
                <AddQuest questId="b80c2c60-e62c-4637-80f8-5aa18dc93b34" />
            </effects>
            <events>
                <execute>
                    <EventListener event=qebdt1 />
                </execute>
            </events>
            <attached>
                <Billboard position="0,0,0" colour="1.0,1.0,1.0" material="Examples/Flare" />
                <DistanceTrigger name=qebdt1 position="0,0,0" distance=10 target="ControllableEntity" />
            </attached>
        </QuestEffectBeacon>

        <QuestEffectBeacon position="-100,0,0" times=-1>
            <effects>
                <FailQuest questId="b80c2c60-e62c-4637-80f8-5aa18dc93b34" />
            </effects>
            <events>
                <execute>
                    <EventListener event=qebdt2 />
                </execute>
            </events>
            <attached>
                <Billboard position="0,0,0" colour="1.0,0,0" material="Examples/Flare" />
                <DistanceTrigger name=qebdt2 position="0,0,0" distance=10 target="ControllableEntity" />
            </attached>
        </QuestEffectBeacon>

        <QuestEffectBeacon position="100,0,0" times=-1>
            <effects>
                <CompleteQuest questId="b80c2c60-e62c-4637-80f8-5aa18dc93b34" />
            </effects>
            <events>
                <execute>
                    <EventListener event=qebdt3 />
                </execute>
            </events>
            <attached>
                <Billboard position="0,0,0" colour="0,1.0,0" material="Examples/Flare" />
                <DistanceTrigger name=qebdt3 position="0,0,0" distance=10 target="ControllableEntity" />
            </attached>
        </QuestEffectBeacon>

        <QuestEffectBeacon position="0,100,0" times=-1>
            <effects>
                <AddQuestHint hintId="022a859d-08dd-4eac-a085-c28c29c06d48" />
            </effects>
            <events>
                <execute>
                    <EventListener event=qebdt4 />
                </execute>
            </events>
            <attached>
                <Billboard position="0,0,0" colour="0,0,1.0" material="Examples/Flare" />
                <DistanceTrigger name=qebdt4 position="0,0,0" distance=10 target="ControllableEntity" />
            </attached>
        </QuestEffectBeacon>

        <ParticleEmitter name=firecenter position="0,0,0" source="Orxonox/fire3" active=false>
            <events>
                <activity>
                    <QuestListener questId="b80c2c60-e62c-4637-80f8-5aa18dc93b34" mode="complete" />
                </activity>
            </events>
        </ParticleEmitter>

    </Scene>
</Level>

