[Fix] Mission stuff.

This commit is contained in:
Allanis 2013-06-22 19:14:38 +01:00
parent fc41a1789e
commit badce25b9b
2 changed files with 16 additions and 1 deletions

View File

@ -20,13 +20,23 @@ You aren't too sure of what to make of your encounter with the Empire, only time
end end
function create() function create()
-- Target destination.
local i = 0
repeat
dest = space.getPlanet(misn.factions())
i = i+1
until dest ~= space.landName() or i > 10
-- Infinate loop protection.
if i > 10 then
misn.finish(false)
end
-- Intro text. -- Intro text.
tk.msg(title[1], text[1]) tk.msg(title[1], text[1])
if tk.yesno(title[1], text[2]) if tk.yesno(title[1], text[2])
then then
misn.accept() misn.accept()
dest = space.getPlanet("Empire");
-- Mission details. -- Mission details.
reward = 3000 reward = 3000
misn.setTitle(misn_title) misn.setTitle(misn_title)

View File

@ -23,6 +23,11 @@ else -- Default english.
end end
function create() function create()
-- Requirements.
if var.peek("es_cargo") ~= true then
misn.finish(false)
end
-- Intro text. -- Intro text.
if tk.yesno(title[1], string.format(text[1], player.name())) if tk.yesno(title[1], string.format(text[1], player.name()))
then then