The Driver Syndicate/Scripting/Mission Scripting: Difference between revisions

From Equilibrium Engine Wiki
Jump to navigation Jump to search
(Created page with "== Overview == There are almost endless possibilities to create missions. As an example you can look at the default missions (located in: GameData\scripts\missions\story_demo) == Missions == ToDo: == Minigames == You can check "GameData\scripts\missions\minigame" for reference === Checkpoint === ToDo: === Gates === These ara simple to create: # Start Freeride mode on the level you want to create the minigame. # Drive to your desired starting point. Open the consol...")
 
Line 53: Line 53:
</syntaxhighlight>After this you only need to add the minigame in your ModInit file
</syntaxhighlight>After this you only need to add the minigame in your ModInit file


see  
Also see [[The Driver Syndicate/Addon System]]


=== Getaway ===
=== Getaway ===

Revision as of 12:42, 25 January 2025

Overview

There are almost endless possibilities to create missions. As an example you can look at the default missions (located in: GameData\scripts\missions\story_demo)

Missions

ToDo:

Minigames

You can check "GameData\scripts\missions\minigame" for reference

Checkpoint

ToDo:

Gates

These ara simple to create:

  1. Start Freeride mode on the level you want to create the minigame.
  2. Drive to your desired starting point. Open the console with the key below escape key.
  3. Then type "trailbrazer_gates_record" and press enter and drive your route. when the counter reaches 100 the script is saved in "GameData/trailblazer_generated.txt".
  4. Now you can rename the file as you desire and move it into "scripts\trailblazer\gates" of your mod/Addon. (remember the filename for next step)
  5. In "scripts\missions\minigame\gates" you need a .lua file with following content:
--//////////////////////////////////////////////////////////////////////////////////
--// Copyright � Inspiration Byte
--// 2009-2017
--//////////////////////////////////////////////////////////////////////////////////

--------------------------------------------------------------------------------
-- Mission script for trail blazer/gates
--------------------------------------------------------------------------------
-- By Shurumov Ilya
-- 11 Sep 2018
--------------------------------------------------------------------------------

world:SetLevelName("default") --set levelname here
world:SetEnvironmentName("dawn_clear") --set weather here

MISSION.MusicScript = "nyc_day" -- set music here
MISSION.Hud = TrailblazerGame.GatesHud

----------------------------------------------------------------------------------------------
-- Mission initialization
----------------------------------------------------------------------------------------------

function MISSION.Init()
	local playerCar = gameses:CreateCar("mustang_f", CAR_TYPE_NORMAL) --set car here
	playerCar:Spawn()
	playerCar:SetColorScheme( 2 )
	gameses:SetPlayerCar( playerCar )

	-- init game mode
	TrailblazerGame.Init( "gates/gt01", true ) -- replace gt01 with your filename (point 5)
end

After this you only need to add the minigame in your ModInit file

Also see The Driver Syndicate/Addon System

Getaway

ToDo:

Pursuit

ToDo:

Survival

ToDo:

Trailblazer

ToDo: