[Add] Allow Draktharr to get cargo missions, but with 50% frequency.
This commit is contained in:
parent
571b801a49
commit
517a9dd0e8
@ -17,6 +17,7 @@
|
||||
<faction>Independent</faction>
|
||||
<faction>Empire</faction>
|
||||
<faction>Soromid</faction>
|
||||
<faction>Draktharr</faction>
|
||||
</avail>
|
||||
</mission>
|
||||
<mission name="Empire Recruitment">
|
||||
|
@ -39,10 +39,16 @@ end
|
||||
|
||||
-- Create the mission.
|
||||
function create()
|
||||
local landed = space.getPlanet() -- Get landed planet.
|
||||
landed = space.getPlanet() -- Get landed planet.
|
||||
|
||||
-- Only 50% chance of appearing on Draktharr systems.
|
||||
dv = faction.get("Draktharr")
|
||||
if landed:faction() == dv and rnd.int(1) == 0 then
|
||||
misn.finish(false)
|
||||
end
|
||||
|
||||
-- Target destination.
|
||||
local i = 0
|
||||
i = 0
|
||||
repeat
|
||||
planet, system = space.getPlanet(misn.factions())
|
||||
i = i + 1
|
||||
@ -147,7 +153,7 @@ end
|
||||
|
||||
-- Land hook.
|
||||
function land()
|
||||
local landed = space.getPlanet()
|
||||
landed = space.getPlanet()
|
||||
if landed == planet then
|
||||
if player.rmCargo(carg_id) then
|
||||
player.pay( reward )
|
||||
|
Loading…
Reference in New Issue
Block a user