mirror of
https://github.com/SWG-Source/dsrc.git
synced 2026-08-28 17:56:25 -04:00
719 lines
21 KiB
Plaintext
719 lines
21 KiB
Plaintext
// ======================================================================
|
|
//
|
|
// station_indie_slaver.script
|
|
//
|
|
//
|
|
//
|
|
// Created with SwgConversationEditor 1.30 - DO NOT EDIT THIS AUTO-GENERATED FILE!
|
|
//
|
|
// ======================================================================
|
|
|
|
// ======================================================================
|
|
// Library Includes
|
|
// ======================================================================
|
|
|
|
include library.ai_lib;
|
|
include library.chat;
|
|
include library.groundquests;
|
|
include library.space_battlefield;
|
|
include library.space_combat;
|
|
include library.space_content;
|
|
include library.space_crafting;
|
|
include library.space_flags;
|
|
include library.space_quest;
|
|
include library.space_transition;
|
|
include library.utils;
|
|
|
|
// ======================================================================
|
|
// Script Constants
|
|
// ======================================================================
|
|
|
|
string c_stringFile = "conversation/station_indie_slaver";
|
|
|
|
// ======================================================================
|
|
// Script Conditions
|
|
// ======================================================================
|
|
|
|
boolean station_indie_slaver_condition__defaultCondition (obj_id player, obj_id npc)
|
|
{
|
|
return true;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
boolean station_indie_slaver_condition_hasWon_assassinations (obj_id player, obj_id npc)
|
|
{
|
|
// Has the player won any of the three ASSASSINATION missions he can take at this point?
|
|
return ( space_quest.hasReceivedReward(player, "assassinate", "ep3_kash_station_assassinate_neutral") ||
|
|
space_quest.hasReceivedReward(player, "assassinate", "ep3_kash_station_assassinate_rebel") ||
|
|
space_quest.hasReceivedReward(player, "assassinate", "ep3_kash_station_assassinate_imperial"));
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
boolean station_indie_slaver_condition_isTooFar (obj_id player, obj_id npc)
|
|
{
|
|
space_combat.playCombatTauntSound( player );
|
|
obj_id containingShip = space_transition.getContainingShip(player);
|
|
return ( getDistance( npc, containingShip ) > space_transition.STATION_COMM_MAX_DISTANCE );
|
|
}
|
|
|
|
// ======================================================================
|
|
// Script Actions
|
|
// ======================================================================
|
|
|
|
void station_indie_slaver_action_grantduty_recovery (obj_id player, obj_id npc)
|
|
{
|
|
space_quest.grantQuest(player, "recovery_duty", "ep3_indie_slavers_recovery");
|
|
}
|
|
|
|
// ======================================================================
|
|
// Script %TO Tokens
|
|
// ======================================================================
|
|
|
|
// ======================================================================
|
|
// Script %DI Tokens
|
|
// ======================================================================
|
|
|
|
// ======================================================================
|
|
// Script %DF Tokens
|
|
// ======================================================================
|
|
|
|
// ======================================================================
|
|
// handleBranch<n> Functions
|
|
// ======================================================================
|
|
|
|
int station_indie_slaver_handleBranch2 (obj_id player, obj_id npc, string_id response)
|
|
{
|
|
//-- [BRANCH NOTE]
|
|
//-- NPC: What can I do for you, buddy?
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: I'm looking for work.
|
|
if (response == "s_180")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition_hasWon_assassinations (player, npc))
|
|
{
|
|
//-- NPC: I have some work you might be interested in. You see, we're trying to make a name for ourselves here in the Kashyyyk system... but the Trandoshans always show us up!
|
|
string_id message = new string_id (c_stringFile, "s_185");
|
|
int numberOfResponses = 0;
|
|
|
|
boolean hasResponse = false;
|
|
|
|
//-- PLAYER: What do you mean?
|
|
boolean hasResponse0 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse0 = true;
|
|
}
|
|
|
|
if (hasResponse)
|
|
{
|
|
int responseIndex = 0;
|
|
string_id responses [] = new string_id [numberOfResponses];
|
|
|
|
if (hasResponse0)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_186");
|
|
|
|
utils.setScriptVar (player, "conversation.station_indie_slaver.branchId", 3);
|
|
|
|
npcSpeak (player, message);
|
|
npcSetConversationResponses (player, responses);
|
|
}
|
|
else
|
|
{
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: Wish I could help you. Right now we've got our hands full just trying to make ends meet. Have you talked to the Civilian Protection guild yet?
|
|
string_id message = new string_id (c_stringFile, "s_199");
|
|
int numberOfResponses = 0;
|
|
|
|
boolean hasResponse = false;
|
|
|
|
//-- PLAYER: Who are they?
|
|
boolean hasResponse0 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse0 = true;
|
|
}
|
|
|
|
if (hasResponse)
|
|
{
|
|
int responseIndex = 0;
|
|
string_id responses [] = new string_id [numberOfResponses];
|
|
|
|
if (hasResponse0)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_200");
|
|
|
|
utils.setScriptVar (player, "conversation.station_indie_slaver.branchId", 9);
|
|
|
|
npcSpeak (player, message);
|
|
npcSetConversationResponses (player, responses);
|
|
}
|
|
else
|
|
{
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
return SCRIPT_DEFAULT;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
int station_indie_slaver_handleBranch3 (obj_id player, obj_id npc, string_id response)
|
|
{
|
|
//-- [BRANCH NOTE]
|
|
//-- NPC: I have some work you might be interested in. You see, we're trying to make a name for ourselves here in the Kashyyyk system... but the Trandoshans always show us up!
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: What do you mean?
|
|
if (response == "s_186")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: The Trandos are pulling in Krayt bellies full of credits every day with their... um... operation. We don't have the time or the resources to compete with them legitimately!
|
|
string_id message = new string_id (c_stringFile, "s_188");
|
|
int numberOfResponses = 0;
|
|
|
|
boolean hasResponse = false;
|
|
|
|
//-- PLAYER: Where do I come in?
|
|
boolean hasResponse0 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse0 = true;
|
|
}
|
|
|
|
if (hasResponse)
|
|
{
|
|
int responseIndex = 0;
|
|
string_id responses [] = new string_id [numberOfResponses];
|
|
|
|
if (hasResponse0)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_190");
|
|
|
|
utils.setScriptVar (player, "conversation.station_indie_slaver.branchId", 4);
|
|
|
|
npcSpeak (player, message);
|
|
npcSetConversationResponses (player, responses);
|
|
}
|
|
else
|
|
{
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
return SCRIPT_DEFAULT;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
int station_indie_slaver_handleBranch4 (obj_id player, obj_id npc, string_id response)
|
|
{
|
|
//-- [BRANCH NOTE]
|
|
//-- NPC: The Trandos are pulling in Krayt bellies full of credits every day with their... um... operation. We don't have the time or the resources to compete with them legitimately!
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: Where do I come in?
|
|
if (response == "s_190")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: I want you to disable Trandoshan slaver transports en route to the Avatar platform. When you do this, we can send a high-frequency slicing signal to their navicomputer. In a few seconds, that transport will become ours!
|
|
string_id message = new string_id (c_stringFile, "s_193");
|
|
int numberOfResponses = 0;
|
|
|
|
boolean hasResponse = false;
|
|
|
|
//-- PLAYER: And then?
|
|
boolean hasResponse0 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse0 = true;
|
|
}
|
|
|
|
if (hasResponse)
|
|
{
|
|
int responseIndex = 0;
|
|
string_id responses [] = new string_id [numberOfResponses];
|
|
|
|
if (hasResponse0)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_31");
|
|
|
|
utils.setScriptVar (player, "conversation.station_indie_slaver.branchId", 5);
|
|
|
|
npcSpeak (player, message);
|
|
npcSetConversationResponses (player, responses);
|
|
}
|
|
else
|
|
{
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
return SCRIPT_DEFAULT;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
int station_indie_slaver_handleBranch5 (obj_id player, obj_id npc, string_id response)
|
|
{
|
|
//-- [BRANCH NOTE]
|
|
//-- NPC: I want you to disable Trandoshan slaver transports en route to the Avatar platform. When you do this, we can send a high-frequency slicing signal to their navicomputer. In a few seconds, that transport will become ours!
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: And then?
|
|
if (response == "s_31")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: And then you lead the transport back here for processing. Don't get me wrong - the Trandoshans aren't going to just let you do this. Expect a lot of resistance.
|
|
string_id message = new string_id (c_stringFile, "s_32");
|
|
int numberOfResponses = 0;
|
|
|
|
boolean hasResponse = false;
|
|
|
|
//-- PLAYER: I'm ready!
|
|
boolean hasResponse0 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse0 = true;
|
|
}
|
|
|
|
//-- PLAYER: No thanks.
|
|
boolean hasResponse1 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse1 = true;
|
|
}
|
|
|
|
if (hasResponse)
|
|
{
|
|
int responseIndex = 0;
|
|
string_id responses [] = new string_id [numberOfResponses];
|
|
|
|
if (hasResponse0)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_33");
|
|
|
|
if (hasResponse1)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_36");
|
|
|
|
utils.setScriptVar (player, "conversation.station_indie_slaver.branchId", 6);
|
|
|
|
npcSpeak (player, message);
|
|
npcSetConversationResponses (player, responses);
|
|
}
|
|
else
|
|
{
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
return SCRIPT_DEFAULT;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
int station_indie_slaver_handleBranch6 (obj_id player, obj_id npc, string_id response)
|
|
{
|
|
//-- [BRANCH NOTE]
|
|
//-- NPC: And then you lead the transport back here for processing. Don't get me wrong - the Trandoshans aren't going to just let you do this. Expect a lot of resistance.
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: I'm ready!
|
|
if (response == "s_33")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
station_indie_slaver_action_grantduty_recovery (player, npc);
|
|
|
|
//-- NPC: Good luck!
|
|
string_id message = new string_id (c_stringFile, "s_34");
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: No thanks.
|
|
if (response == "s_36")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: Are you kidding? This is good money I'm paying here!
|
|
string_id message = new string_id (c_stringFile, "s_38");
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
return SCRIPT_DEFAULT;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
int station_indie_slaver_handleBranch9 (obj_id player, obj_id npc, string_id response)
|
|
{
|
|
//-- [BRANCH NOTE]
|
|
//-- NPC: Wish I could help you. Right now we've got our hands full just trying to make ends meet. Have you talked to the Civilian Protection guild yet?
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: Who are they?
|
|
if (response == "s_200")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: Well, why don't you check in with them and find out for yourself. Go do the Kashyyyk space station. Talk to the gal they have running the place. She'll get you started.
|
|
string_id message = new string_id (c_stringFile, "s_201");
|
|
int numberOfResponses = 0;
|
|
|
|
boolean hasResponse = false;
|
|
|
|
//-- PLAYER: Then what?
|
|
boolean hasResponse0 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse0 = true;
|
|
}
|
|
|
|
if (hasResponse)
|
|
{
|
|
int responseIndex = 0;
|
|
string_id responses [] = new string_id [numberOfResponses];
|
|
|
|
if (hasResponse0)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_203");
|
|
|
|
utils.setScriptVar (player, "conversation.station_indie_slaver.branchId", 10);
|
|
|
|
npcSpeak (player, message);
|
|
npcSetConversationResponses (player, responses);
|
|
}
|
|
else
|
|
{
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
return SCRIPT_DEFAULT;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
int station_indie_slaver_handleBranch10 (obj_id player, obj_id npc, string_id response)
|
|
{
|
|
//-- [BRANCH NOTE]
|
|
//-- NPC: Well, why don't you check in with them and find out for yourself. Go do the Kashyyyk space station. Talk to the gal they have running the place. She'll get you started.
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: Then what?
|
|
if (response == "s_203")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: Then you give it some time! Work for the Civilian Protectors. Get your bearings. Learn the ins and outs. Come back and see me when you're ready.
|
|
string_id message = new string_id (c_stringFile, "s_207");
|
|
int numberOfResponses = 0;
|
|
|
|
boolean hasResponse = false;
|
|
|
|
//-- PLAYER: I will.
|
|
boolean hasResponse0 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse0 = true;
|
|
}
|
|
|
|
if (hasResponse)
|
|
{
|
|
int responseIndex = 0;
|
|
string_id responses [] = new string_id [numberOfResponses];
|
|
|
|
if (hasResponse0)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_209");
|
|
|
|
utils.setScriptVar (player, "conversation.station_indie_slaver.branchId", 11);
|
|
|
|
npcSpeak (player, message);
|
|
npcSetConversationResponses (player, responses);
|
|
}
|
|
else
|
|
{
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
return SCRIPT_DEFAULT;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
int station_indie_slaver_handleBranch11 (obj_id player, obj_id npc, string_id response)
|
|
{
|
|
//-- [BRANCH NOTE]
|
|
//-- NPC: Then you give it some time! Work for the Civilian Protectors. Get your bearings. Learn the ins and outs. Come back and see me when you're ready.
|
|
|
|
//-- [RESPONSE NOTE]
|
|
//-- PLAYER: I will.
|
|
if (response == "s_209")
|
|
{
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: Fine. I'll talk to you later.
|
|
string_id message = new string_id (c_stringFile, "s_211");
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
chat.chat (npc, player, message);
|
|
npcEndConversation (player);
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
}
|
|
|
|
return SCRIPT_DEFAULT;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
// ======================================================================
|
|
// User Script Triggers
|
|
// ======================================================================
|
|
|
|
trigger OnInitialize ()
|
|
{
|
|
setCondition (self, CONDITION_CONVERSABLE);
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
trigger OnAttach ()
|
|
{
|
|
setCondition (self, CONDITION_CONVERSABLE);
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
trigger OnObjectMenuRequest (obj_id player, menu_info menuInfo)
|
|
{
|
|
int menu = menuInfo.addRootMenu (menu_info_types.CONVERSE_START, null);
|
|
menu_info_data menuInfoData = menuInfo.getMenuItemById (menu);
|
|
menuInfoData.setServerNotify (false);
|
|
setCondition (self, CONDITION_CONVERSABLE);
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
trigger OnIncapacitated (obj_id killer)
|
|
{
|
|
clearCondition (self, CONDITION_CONVERSABLE);
|
|
detachScript (self, "conversation.station_indie_slaver");
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
// ======================================================================
|
|
// Script Triggers
|
|
// ======================================================================
|
|
|
|
//-- This function should move to base_class.java
|
|
boolean npcStartConversation(obj_id player, obj_id npc, string convoName, string_id greetingId, prose_package greetingProse, string_id[] responses)
|
|
{
|
|
Object[] objects = new Object[responses.length];
|
|
System.arraycopy(responses, 0, objects, 0, responses.length);
|
|
return npcStartConversation(player, npc, convoName, greetingId, greetingProse, objects);
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
trigger OnStartNpcConversation (obj_id player)
|
|
{
|
|
obj_id npc = self;
|
|
|
|
if (ai_lib.isInCombat (npc) || ai_lib.isInCombat (player))
|
|
return SCRIPT_OVERRIDE;
|
|
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition_isTooFar (player, npc))
|
|
{
|
|
//-- NPC: Come closer. Stupid low-range comm system! I'm only getting every other word...
|
|
string_id message = new string_id (c_stringFile, "s_204");
|
|
chat.chat (npc, player, message);
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
//-- [NOTE]
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
//-- NPC: What can I do for you, buddy?
|
|
string_id message = new string_id (c_stringFile, "s_578");
|
|
int numberOfResponses = 0;
|
|
|
|
boolean hasResponse = false;
|
|
|
|
//-- PLAYER: I'm looking for work.
|
|
boolean hasResponse0 = false;
|
|
if (station_indie_slaver_condition__defaultCondition (player, npc))
|
|
{
|
|
++numberOfResponses;
|
|
hasResponse = true;
|
|
hasResponse0 = true;
|
|
}
|
|
|
|
if (hasResponse)
|
|
{
|
|
int responseIndex = 0;
|
|
string_id responses [] = new string_id [numberOfResponses];
|
|
|
|
if (hasResponse0)
|
|
responses [responseIndex++] = new string_id (c_stringFile, "s_180");
|
|
|
|
utils.setScriptVar (player, "conversation.station_indie_slaver.branchId", 2);
|
|
|
|
npcStartConversation (player, npc, "station_indie_slaver", message, responses);
|
|
}
|
|
else
|
|
{
|
|
chat.chat (npc, player, message);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
chat.chat (npc, "Error: All conditions for OnStartNpcConversation were false.");
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
// ----------------------------------------------------------------------
|
|
|
|
trigger OnNpcConversationResponse (string conversationId, obj_id player, string_id response)
|
|
{
|
|
if (conversationId != "station_indie_slaver")
|
|
return SCRIPT_CONTINUE;
|
|
|
|
obj_id npc = self;
|
|
|
|
int branchId = utils.getIntScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
if (branchId == 2 && station_indie_slaver_handleBranch2 (player, npc, response) == SCRIPT_CONTINUE)
|
|
return SCRIPT_CONTINUE;
|
|
|
|
if (branchId == 3 && station_indie_slaver_handleBranch3 (player, npc, response) == SCRIPT_CONTINUE)
|
|
return SCRIPT_CONTINUE;
|
|
|
|
if (branchId == 4 && station_indie_slaver_handleBranch4 (player, npc, response) == SCRIPT_CONTINUE)
|
|
return SCRIPT_CONTINUE;
|
|
|
|
if (branchId == 5 && station_indie_slaver_handleBranch5 (player, npc, response) == SCRIPT_CONTINUE)
|
|
return SCRIPT_CONTINUE;
|
|
|
|
if (branchId == 6 && station_indie_slaver_handleBranch6 (player, npc, response) == SCRIPT_CONTINUE)
|
|
return SCRIPT_CONTINUE;
|
|
|
|
if (branchId == 9 && station_indie_slaver_handleBranch9 (player, npc, response) == SCRIPT_CONTINUE)
|
|
return SCRIPT_CONTINUE;
|
|
|
|
if (branchId == 10 && station_indie_slaver_handleBranch10 (player, npc, response) == SCRIPT_CONTINUE)
|
|
return SCRIPT_CONTINUE;
|
|
|
|
if (branchId == 11 && station_indie_slaver_handleBranch11 (player, npc, response) == SCRIPT_CONTINUE)
|
|
return SCRIPT_CONTINUE;
|
|
|
|
chat.chat (npc, "Error: Fell through all branches and responses for OnNpcConversationResponse.");
|
|
|
|
utils.removeScriptVar (player, "conversation.station_indie_slaver.branchId");
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
// ======================================================================
|
|
|