Files
dsrc/sku.0/sys.server/compiled/game/script/conversation/quharek_phase_3.script
T

3106 lines
93 KiB
Plaintext

// ======================================================================
//
// quharek_phase_3.script
// Copyright 2003, Sony Online Entertainment
//
//
// DO NOT EDIT THIS AUTO-GENERATED FILE. PLEASE USE THE CONVERATION EDITOR!
//
// ======================================================================
// ======================================================================
// Library Includes
// ======================================================================
include library.ai_lib;
include library.chat;
include library.community_crafting;
include library.fs_dyn_village;
include library.fs_quests;
include library.fs_quests_cc;
include library.quests;
include library.sui;
include library.utils;
// ======================================================================
// Script Constants
// ======================================================================
string c_stringFile = "conversation/quharek_phase_3";
// ======================================================================
// Script Conditions
// ======================================================================
boolean quharek_phase_3_condition__defaultCondition (obj_id player, obj_id npc)
{
return true;
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_isPlayerCommunityCrafting (obj_id player, obj_id npc)
{
obj_id craftingTracker = utils.getObjIdScriptVar(npc, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER);
if (isIdValid(craftingTracker))
{
if (community_crafting.isSessionActive(craftingTracker) &&
community_crafting.isPlayerCrafting(craftingTracker, player))
{
return true;
}
}
return false;
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_isCommunityCraftingEnabled (obj_id player, obj_id npc)
{
return fs_quests_cc.testCommunityCraftingEnabled (npc, 3);
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_canAddPlayer (obj_id player, obj_id npc)
{
obj_id craftingTracker = utils.getObjIdScriptVar(npc, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER);
if (isIdValid(craftingTracker))
{
if (community_crafting.isSessionActive(craftingTracker) &&
getIntObjVar(craftingTracker, OBJVAR_CRAFTERS_COUNT) < community_crafting.getMaxPlayersPerProject() &&
!community_crafting.isPlayerCrafting(player))
{
return true;
}
}
return false;
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_isTrackingQuality (obj_id player, obj_id npc)
{
return utils.getBooleanScriptVar(npc, fs_quests_cc.SCRIPTVAR_TRACKING_QUALITY);
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_isTrackingQuantity (obj_id player, obj_id npc)
{
return utils.getBooleanScriptVar(npc, fs_quests_cc.SCRIPTVAR_TRACKING_QUANTITY);
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_isTrackingSlots (obj_id player, obj_id npc)
{
return utils.getBooleanScriptVar(npc, fs_quests_cc.SCRIPTVAR_TRACKING_SLOTS);
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_isPlayerCraftingOrQuesting (obj_id player, obj_id npc)
{
if (!isGod(player) && !fs_quests.isVillageEligible(player))
return true;
boolean result = quharek_phase_3_condition_isPlayerCommunityCrafting(player, npc);
if (result)
return true;
if (quests.isActive(QUEST_MAIN, player) || quests.isComplete(QUEST_MAIN, player))
return true;
if (fs_quests.hasQuestAccepted(player))
return true;
return false;
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_isPlayerSkilled (obj_id player, obj_id npc)
{
return hasSkill(player, "crafting_artisan_novice");
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_canAddPlayerAndIsSkilled (obj_id player, obj_id npc)
{
return quharek_phase_3_condition_canAddPlayer(player, npc) && quharek_phase_3_condition_isPlayerSkilled(player, npc);
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_hasPlayerFinishedQuestAndIsCrafting (obj_id player, obj_id npc)
{
return isQuestComplete(player, quests.getQuestId(QUEST_STEP_02)) &&
quharek_phase_3_condition_isPlayerCommunityCrafting(player, npc);
}
// ----------------------------------------------------------------------
boolean quharek_phase_3_condition_hasPlayerFinishedQuestAndNotCrafting (obj_id player, obj_id npc)
{
return isQuestComplete(player, quests.getQuestId(QUEST_STEP_02)) &&
!quharek_phase_3_condition_isPlayerCommunityCrafting(player, npc);
}
// ======================================================================
// Script Actions
// ======================================================================
void quharek_phase_3_action_showPlayerSlot1Quality (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 1, true, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerProjectAttributes (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectAttribs(npc, player, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot2Quality (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 2, true, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot4Quality (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 4, true, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot5Quality (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 5, true, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot6Quality (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 6, true, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot7Quality (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 7, true, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerProjectQuality (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 0, true, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot3Quality (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 3, true, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot1Quantity (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 1, false, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot2Quantity (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 2, false, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot4Quantity (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 4, false, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot5Quantity (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 5, false, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot6Quantity (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 6, false, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot7Quantity (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 7, false, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerProjectQuantity (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 0, false, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_showPlayerSlot3Quantity (obj_id player, obj_id npc)
{
fs_quests_cc.showPlayerProjectStats(npc, player, 3, false, 3);
}
// ----------------------------------------------------------------------
void quharek_phase_3_action_grantPlayerQuest (obj_id player, obj_id npc)
{
quests.activate(QUEST_MAIN, player, npc);
attachScript(player, QUEST_CLEANUP);
fs_quests.setQuestAccepted(player);
obj_id craftingTracker = utils.getObjIdScriptVar(npc, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER);
if (isIdValid(craftingTracker))
{
int currentCrafters = getIntObjVar(craftingTracker, OBJVAR_CRAFTERS_COUNT);
setObjVar(craftingTracker, OBJVAR_CRAFTERS_COUNT, currentCrafters + 1);
}
if (utils.hasWaypoint(player, "@npc_name:qtqc") == null)
{
obj_id waypoint = createWaypointInDatapad(player, utils.getObjIdScriptVar(npc, SCRIPTVAR_QTQC));
if (isIdValid(waypoint))
{
setWaypointName(waypoint, "@npc_name:qtqc");
setWaypointColor(waypoint, "yellow");
setWaypointActive(waypoint, true);
}
}
}
// ======================================================================
// Script %TO Tokens
// ======================================================================
// ======================================================================
// Script %DI Tokens
// ======================================================================
int quharek_phase_3_tokenDI_minIngredientsRequired (obj_id player, obj_id npc)
{
return utils.getIntScriptVar(npc, fs_quests_cc.SCRIPTVAR_MIN_INGREDIENTS);
}
// ======================================================================
// Script %DF Tokens
// ======================================================================
// ======================================================================
// User Script Triggers
// ======================================================================
/*********************************************************************************/
// Constants
const string QUEST_MAIN = "fs_phase_3_craft_shields_main";
const string QUEST_STEP_01 = "fs_phase_3_craft_shields_01";
const string QUEST_STEP_02 = "fs_phase_3_craft_shields_02";
const string QUEST_CLEANUP = "quest.force_sensitive.fs_craft_village_shields";
const string DATATABLE_CRAFTING_QUESTS = "datatables/quest/force_sensitive/community_crafting.iff";
const string DATATABLE_CQ_PHASE = "phase";
const string DATATABLE_CQ_SCHEMATIC = "schematic";
const string DATATABLE_CQ_PRIZE = "prize";
const string DATATABLE_CQ_TRACK_QUANTITY = "track_quantity";
const string DATATABLE_CQ_TRACK_QUALTITY = "track_quality";
const string DATATABLE_CQ_TRACK_SLOTS = "track_slots";
const string DATATABLE_CQ_MIN_INGREDIENTS = "min_ingredients";
const string OBJVAR_CRAFTERS_COUNT = community_crafting.OBJVAR_COMMUNITY_CRAFTING_BASE + ".numCrafters";
const string OBJVAR_LAST_PHASE = community_crafting.OBJVAR_COMMUNITY_CRAFTING_BASE + ".lastPhase";
const string SCRIPTVAR_QTQC = "community_crafting.qtqc";
const string SCRIPT_INVENTORY = "systems.crafting.community_crafting.npc_inventory";
/*********************************************************************************/
// Triggers
trigger OnInitialize ()
{
if ((!isMob (self)) || (isPlayer (self)))
detachScript(self, "conversation.quharek_phase_3");
setCondition (self, CONDITION_CONVERSABLE);
initializeMe(self);
return SCRIPT_CONTINUE;
}
trigger OnAttach ()
{
setCondition (self, CONDITION_CONVERSABLE);
initializeMe(self);
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.quharek_phase_3");
return SCRIPT_CONTINUE;
}
/*********************************************************************************/
// Utility functions
void initializeMe (obj_id self)
{
// see if we know about the master village object, and ask for it if we don't
if (!utils.hasScriptVar(self, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER))
{
debugServerConsoleMsg(self, "initMe asking for village manager");
requestVillageMaster(self);
}
else
{
debugServerConsoleMsg(self, "initMe found village manager");
if (initializeCraftingQuest(self))
cacheProjectData(self);
}
}
void requestVillageMaster(obj_id self)
{
if (!utils.hasScriptVar(self, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER))
{
debugServerConsoleMsg(self, "requestVillageMaster asking for village manager");
messageTo(self, "handleRetryGetVillageManager", null, 60.0f, false);
fs_dyn_village.getRegisteredObjIdFromClusterWideData(
fs_dyn_village.CLUSTER_OBJID_KEY_MASTER, "handleGetVillageManager", self);
}
}
messageHandler handleGetVillageManager()
{
boolean rslt = false;
string key = "";
if (params.containsKey("key"))
{
key = params.getString("key");
}
if (params.containsKey("success"))
{
rslt = params.getBoolean("success");
}
if (rslt && key != null && key.length() > 0)
{
obj_id id = null;
if (params.containsKey(key))
{
id = params.getObjId(key);
if (isIdValid(id))
{
utils.setScriptVar(self, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER, id);
debugServerConsoleMsg(self, "Object key '" + key + "' was registered as " + id);
if (initializeCraftingQuest(self))
cacheProjectData(self);
return SCRIPT_CONTINUE;
}
}
}
debugServerConsoleMsg(self, "Failed to find obj id '" + key + "' cluster wide data. Id might not have been registered yet.");
messageTo(self, "handleRetryGetVillageManager", null, 30, false);
return SCRIPT_CONTINUE;
}
messageHandler handleRetryGetVillageManager()
{
requestVillageMaster(self);
return SCRIPT_CONTINUE;
}
boolean initializeCraftingQuest(obj_id self)
{
if (!utils.hasScriptVar(self, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER))
{
debugServerConsoleMsg(null, "WARNING: initializeCraftingQuest no crafting tracker");
return false;
}
obj_id villageId = utils.getObjIdScriptVar(self, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER);
if (!isIdValid(villageId))
{
debugServerConsoleMsg(null, "WARNING: initializeCraftingQuest no village");
return false;
}
if (!villageId.isInitialized())
{
messageTo(self, "handleReinitialize", null, 5, false);
return false;
}
if (!utils.hasScriptVar(villageId, SCRIPTVAR_QTQC))
{
messageTo(self, "handleReinitialize", null, 15, false);
return false;
}
utils.setScriptVar(self, SCRIPTVAR_QTQC, utils.getObjIdScriptVar(villageId, SCRIPTVAR_QTQC));
int currentPhase = getIntObjVar(villageId, fs_dyn_village. OBJVAR_CURRENT_PHASE);
int lastPhase = getIntObjVar(villageId, OBJVAR_LAST_PHASE);
utils.setScriptVar(self, fs_quests_cc.SCRIPTVAR_VILLAGE_PHASE, currentPhase);
debugServerConsoleMsg(null, "Quharek current phase = " + currentPhase + ", last phase = " + lastPhase);
if ((currentPhase != lastPhase && currentPhase != 0) ||
(!quharek_phase_3_condition_isCommunityCraftingEnabled(obj_id.NULL_ID, self) &&
currentPhase == 3))
{
if (currentPhase == 3)
{
// we are just starting phase 3, set up the system
// grab the attributes for the village shields and store them
// on the master village object
community_crafting.finalizeItem(villageId, true);
Vector defenseNames = new Vector();
Vector defenseValues = new Vector();
if (community_crafting.getProjectAttributes(villageId, defenseNames, defenseValues))
{
for (int i = 0; i < defenseNames.size(); ++i)
{
setObjVar(villageId, fs_dyn_village.OBJVAR_VILLAGE_DEFENSES + "." +
((string_id)(defenseNames.get(i))).getAsciiId(),
((Float)(defenseValues.get(i))).floatValue());
}
}
else
{
CustomerServiceLog("fs_village", "WARNING: unable to get final "+
"attributes for the phase 2 community crafting quest");
}
// clean up the previous session
community_crafting.cleanup(villageId);
removeObjVar(villageId, fs_dyn_village.OBJVAR_VILLAGE_SHIELDS);
int row = dataTableSearchColumnForInt(3, DATATABLE_CQ_PHASE, DATATABLE_CRAFTING_QUESTS);
if (row < 0)
{
CustomerServiceLog("fs_village", "WARNING: initializeCraftingQuest could not find datatable entry for phase 3");
return false;
}
string schematic = dataTableGetString(DATATABLE_CRAFTING_QUESTS, row, DATATABLE_CQ_SCHEMATIC);
if (schematic == null || schematic.length() == 0)
{
CustomerServiceLog("fs_village", "WARNING: initializeCraftingQuest could not find schematic entry for phase 3");
return false;
}
string prize = dataTableGetString(DATATABLE_CRAFTING_QUESTS, row, DATATABLE_CQ_PRIZE);
boolean trackQuantity = dataTableGetInt(DATATABLE_CRAFTING_QUESTS, row, DATATABLE_CQ_TRACK_QUANTITY) != 0;
boolean trackQuality = dataTableGetInt(DATATABLE_CRAFTING_QUESTS, row, DATATABLE_CQ_TRACK_QUALTITY) != 0;
boolean trackSlots = dataTableGetInt(DATATABLE_CRAFTING_QUESTS, row, DATATABLE_CQ_TRACK_SLOTS) != 0;
boolean result = community_crafting.setMasterSchematic(villageId,
schematic, trackQuantity, trackQuality, trackSlots, prize);
if (!result)
{
CustomerServiceLog("fs_village", "WARNING: initializeCraftingQuest error creating phase 3 crafting quest");
return false;
}
int minIngredients = dataTableGetInt(DATATABLE_CRAFTING_QUESTS, row, DATATABLE_CQ_MIN_INGREDIENTS);
debugServerConsoleMsg(null, "Initialized crafting quest for phase 3, setting min ingredient count to " + minIngredients);
community_crafting.setMinimumQuantity(villageId, minIngredients);
setObjVar(villageId, OBJVAR_CRAFTERS_COUNT, 0);
setObjVar(villageId, OBJVAR_LAST_PHASE, currentPhase);
}
}
return currentPhase == 3;
}
messageHandler handleReinitialize()
{
if (initializeCraftingQuest(self))
cacheProjectData(self);
return SCRIPT_CONTINUE;
}
void cacheProjectData (obj_id self)
{
debugServerConsoleMsg(null, "cacheProjectData enter");
obj_id craftingTracker = utils.getObjIdScriptVar(self, fs_quests_cc.SCRIPTVAR_CRAFTING_TRACKER);
if (!isIdValid(craftingTracker))
return;
if (!community_crafting.isSessionActive(craftingTracker))
return;
// there's a bug somewhere that's detaching the crafting scripts from the
// master object; reattach them
string[] scripts = community_crafting.getSchematicScripts(craftingTracker);
if (scripts != null)
{
for ( int i = 0; i < scripts.length; ++i )
{
if ( scripts[i] != null && !hasScript(craftingTracker, scripts[i]) )
attachScript(craftingTracker, scripts[i]);
}
}
// sanity check the OBJVAR_CRAFTERS_COUNT objvar
int myCrafters = getIntObjVar(craftingTracker, OBJVAR_CRAFTERS_COUNT);
int registeredCrafters = community_crafting.getNumPlayersCrafting(craftingTracker);
if (registeredCrafters > myCrafters)
{
setObjVar(craftingTracker, OBJVAR_CRAFTERS_COUNT, registeredCrafters);
}
debugServerConsoleMsg(null, "cacheProjectData caching data");
utils.setScriptVar(self, fs_quests_cc.SCRIPTVAR_TRACKING_QUALITY, community_crafting.getIsTrackingQuality(craftingTracker));
utils.setScriptVar(self, fs_quests_cc.SCRIPTVAR_TRACKING_QUANTITY, community_crafting.getIsTrackingQuantity(craftingTracker));
utils.setScriptVar(self, fs_quests_cc.SCRIPTVAR_TRACKING_SLOTS, community_crafting.getIsTrackingSlots(craftingTracker));
utils.setScriptVar(self, fs_quests_cc.SCRIPTVAR_TRACKING_NUM_SLOTS, community_crafting.getNumSlots(craftingTracker));
utils.setScriptVar(self, fs_quests_cc.SCRIPTVAR_MIN_INGREDIENTS, community_crafting.getMinimumQuantity(craftingTracker));
debugServerConsoleMsg(null, "Caching min ingredient count to " + community_crafting.getMinimumQuantity(craftingTracker));
}
int getNumSlots(obj_id self)
{
return utils.getIntScriptVar(self, fs_quests_cc.SCRIPTVAR_TRACKING_NUM_SLOTS);
}
// ======================================================================
// 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)
{
if (ai_lib.isInCombat (self) || ai_lib.isInCombat (player))
return SCRIPT_OVERRIDE;
//-- [NOTE]
if (quharek_phase_3_condition_hasPlayerFinishedQuestAndIsCrafting (player, self))
{
//-- NPC: Thanks for helping out with the shields. You can still supply more ingredients if you'd like.
string_id message = new string_id (c_stringFile, "s_be53a473");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I hear you're looking for crafters.
boolean hasResponse0 = false;
if (!quharek_phase_3_condition_isPlayerCraftingOrQuesting (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to get the status of the village shields.
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++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_955b2ddb");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_c266e38f");
setObjVar (player, "conversation.quharek_phase_3.branchId", 3);
npcStartConversation (player, self, "quharek_phase_3", message, responses);
}
else
{
chat.chat (self, message);
}
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (quharek_phase_3_condition_hasPlayerFinishedQuestAndNotCrafting (player, self))
{
//-- NPC: Thanks for helping out with the shields.
string_id message = new string_id (c_stringFile, "s_ed69bd0c");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I hear you're looking for crafters.
boolean hasResponse0 = false;
if (!quharek_phase_3_condition_isPlayerCraftingOrQuesting (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to get the status of the village shields.
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++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_955b2ddb");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_c266e38f");
setObjVar (player, "conversation.quharek_phase_3.branchId", 3);
npcStartConversation (player, self, "quharek_phase_3", message, responses);
}
else
{
chat.chat (self, message);
}
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (quharek_phase_3_condition_isCommunityCraftingEnabled (player, self))
{
//-- NPC: How may I help you?
string_id message = new string_id (c_stringFile, "s_c1dac897");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I hear you're looking for crafters.
boolean hasResponse0 = false;
if (!quharek_phase_3_condition_isPlayerCraftingOrQuesting (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to get the status of the village shields.
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++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_955b2ddb");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_c266e38f");
setObjVar (player, "conversation.quharek_phase_3.branchId", 3);
npcStartConversation (player, self, "quharek_phase_3", message, responses);
}
else
{
chat.chat (self, message);
}
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (!quharek_phase_3_condition_isCommunityCraftingEnabled (player, self))
{
//-- NPC: There is no crafting project currently being run. Please come back later.
string_id message = new string_id (c_stringFile, "s_bc2ccc0e");
chat.chat (self, message);
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnStartNpcConversation were false.");
return SCRIPT_CONTINUE;
}
// ----------------------------------------------------------------------
trigger OnNpcConversationResponse (string conversationId, obj_id player, string_id response)
{
if (conversationId != "quharek_phase_3")
return SCRIPT_CONTINUE;
int branchId = getIntObjVar (player, "conversation.quharek_phase_3.branchId");
//-- [BRANCH NOTE]
//-- NPC: Thanks for helping out with the shields. You can still supply more ingredients if you'd like.
//-- [RESPONSE NOTE]
//-- PLAYER: I hear you're looking for crafters.
if (branchId == 1 && response == "s_955b2ddb")
{
//-- [NOTE]
if (quharek_phase_3_condition_canAddPlayerAndIsSkilled (player, self))
{
//-- NPC: Yes, we need people to help create energy shields for the village. You'll need to contribute at least %DI ingredients to the project. If you do, it will help you gain insight into how the Force can be used to improve your crafting experimentation. We're also giving awards to whoever brings the most or best ingredients. Are you interested?
string_id message = new string_id (c_stringFile, "s_6c81c99f");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: Yes, I'd like to help out.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: No, I can't help you.
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++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_99347a8f");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_e25e215d");
setObjVar (player, "conversation.quharek_phase_3.branchId", 4);
prose_package pp = new prose_package ();
pp.stringId = message;
pp.actor.set (player);
pp.target.set (self);
pp.digitInteger = quharek_phase_3_tokenDI_minIngredientsRequired (player, self);
npcSpeak (player, pp);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
prose_package pp = new prose_package ();
pp.stringId = message;
pp.actor.set (player);
pp.target.set (self);
pp.digitInteger = quharek_phase_3_tokenDI_minIngredientsRequired (player, self);
npcSpeak (player, pp);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (!quharek_phase_3_condition_isPlayerSkilled (player, self))
{
//-- NPC: Yes, but I'm afraid you don't have the even the most basic skills needed to help out. Perhaps you should see if someone else needs assistance.
string_id message = new string_id (c_stringFile, "s_ef01f5ee");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (!quharek_phase_3_condition_canAddPlayer (player, self))
{
//-- NPC: I was, but I've got plenty of people helping me at the moment. Perhaps you should see if someone else needs assistance.
string_id message = new string_id (c_stringFile, "s_a1a54741");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Thanks for helping out with the shields. You can still supply more ingredients if you'd like.' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Thanks for helping out with the shields. You can still supply more ingredients if you'd like.
//-- [RESPONSE NOTE]
//-- PLAYER: I'd like to get the status of the village shields.
if (branchId == 1 && response == "s_c266e38f")
{
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Thanks for helping out with the shields. You can still supply more ingredients if you'd like.' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Thanks for helping out with the shields.
//-- [RESPONSE NOTE]
//-- PLAYER: I hear you're looking for crafters.
if (branchId == 2 && response == "s_955b2ddb")
{
//-- [NOTE]
if (quharek_phase_3_condition_canAddPlayerAndIsSkilled (player, self))
{
//-- NPC: Yes, we need people to help create energy shields for the village. You'll need to contribute at least %DI ingredients to the project. If you do, it will help you gain insight into how the Force can be used to improve your crafting experimentation. We're also giving awards to whoever brings the most or best ingredients. Are you interested?
string_id message = new string_id (c_stringFile, "s_6c81c99f");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: Yes, I'd like to help out.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: No, I can't help you.
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++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_99347a8f");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_e25e215d");
setObjVar (player, "conversation.quharek_phase_3.branchId", 4);
prose_package pp = new prose_package ();
pp.stringId = message;
pp.actor.set (player);
pp.target.set (self);
pp.digitInteger = quharek_phase_3_tokenDI_minIngredientsRequired (player, self);
npcSpeak (player, pp);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
prose_package pp = new prose_package ();
pp.stringId = message;
pp.actor.set (player);
pp.target.set (self);
pp.digitInteger = quharek_phase_3_tokenDI_minIngredientsRequired (player, self);
npcSpeak (player, pp);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (!quharek_phase_3_condition_isPlayerSkilled (player, self))
{
//-- NPC: Yes, but I'm afraid you don't have the even the most basic skills needed to help out. Perhaps you should see if someone else needs assistance.
string_id message = new string_id (c_stringFile, "s_ef01f5ee");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (!quharek_phase_3_condition_canAddPlayer (player, self))
{
//-- NPC: I was, but I've got plenty of people helping me at the moment. Perhaps you should see if someone else needs assistance.
string_id message = new string_id (c_stringFile, "s_a1a54741");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Thanks for helping out with the shields.' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Thanks for helping out with the shields.
//-- [RESPONSE NOTE]
//-- PLAYER: I'd like to get the status of the village shields.
if (branchId == 2 && response == "s_c266e38f")
{
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Thanks for helping out with the shields.' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: How may I help you?
//-- [RESPONSE NOTE]
//-- PLAYER: I hear you're looking for crafters.
if (branchId == 3 && response == "s_955b2ddb")
{
//-- [NOTE]
if (quharek_phase_3_condition_canAddPlayerAndIsSkilled (player, self))
{
//-- NPC: Yes, we need people to help create energy shields for the village. You'll need to contribute at least %DI ingredients to the project. If you do, it will help you gain insight into how the Force can be used to improve your crafting experimentation. We're also giving awards to whoever brings the most or best ingredients. Are you interested?
string_id message = new string_id (c_stringFile, "s_6c81c99f");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: Yes, I'd like to help out.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: No, I can't help you.
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++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_99347a8f");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_e25e215d");
setObjVar (player, "conversation.quharek_phase_3.branchId", 4);
prose_package pp = new prose_package ();
pp.stringId = message;
pp.actor.set (player);
pp.target.set (self);
pp.digitInteger = quharek_phase_3_tokenDI_minIngredientsRequired (player, self);
npcSpeak (player, pp);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
prose_package pp = new prose_package ();
pp.stringId = message;
pp.actor.set (player);
pp.target.set (self);
pp.digitInteger = quharek_phase_3_tokenDI_minIngredientsRequired (player, self);
npcSpeak (player, pp);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (!quharek_phase_3_condition_isPlayerSkilled (player, self))
{
//-- NPC: Yes, but I'm afraid you don't have the even the most basic skills needed to help out. Perhaps you should see if someone else needs assistance.
string_id message = new string_id (c_stringFile, "s_ef01f5ee");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
//-- [NOTE]
if (!quharek_phase_3_condition_canAddPlayer (player, self))
{
//-- NPC: I was, but I've got plenty of people helping me at the moment. Perhaps you should see if someone else needs assistance.
string_id message = new string_id (c_stringFile, "s_a1a54741");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'How may I help you?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: How may I help you?
//-- [RESPONSE NOTE]
//-- PLAYER: I'd like to get the status of the village shields.
if (branchId == 3 && response == "s_c266e38f")
{
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'How may I help you?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Yes, we need people to help create energy shields for the village. You'll need to contribute at least %DI ingredients to the project. If you do, it will help you gain insight into how the Force can be used to improve your crafting experimentation. We're also giving awards to whoever brings the most or best ingredients. Are you interested?
//-- [RESPONSE NOTE]
//-- PLAYER: Yes, I'd like to help out.
if (branchId == 4 && response == "s_99347a8f")
{
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: Ok. You should know that if you help out with the defenses, you won't be able to do any other work here in the village until later. Is that ok?
string_id message = new string_id (c_stringFile, "s_a9474f4a");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: That's no problem.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: Oh. Maybe I'd better do something else then.
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++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_4f68f375");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_f9d5461c");
setObjVar (player, "conversation.quharek_phase_3.branchId", 5);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Yes, we need people to help create energy shields for the village. You'll need to contribute at least %DI ingredients to the project. If you do, it will help you gain insight into how the Force can be used to improve your crafting experimentation. We're also giving awards to whoever brings the most or best ingredients. Are you interested?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Yes, we need people to help create energy shields for the village. You'll need to contribute at least %DI ingredients to the project. If you do, it will help you gain insight into how the Force can be used to improve your crafting experimentation. We're also giving awards to whoever brings the most or best ingredients. Are you interested?
//-- [RESPONSE NOTE]
//-- PLAYER: No, I can't help you.
if (branchId == 4 && response == "s_e25e215d")
{
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: I'm sorry you can't help out. May the Force be with you.
string_id message = new string_id (c_stringFile, "s_6f1f7b10");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Yes, we need people to help create energy shields for the village. You'll need to contribute at least %DI ingredients to the project. If you do, it will help you gain insight into how the Force can be used to improve your crafting experimentation. We're also giving awards to whoever brings the most or best ingredients. Are you interested?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Ok. You should know that if you help out with the defenses, you won't be able to do any other work here in the village until later. Is that ok?
//-- [RESPONSE NOTE]
//-- PLAYER: That's no problem.
if (branchId == 5 && response == "s_4f68f375")
{
quharek_phase_3_action_grantPlayerQuest (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: Excellent! The binary load lifter droid QT-QC has the schematics you'll need for the project. You'll also give it the ingredients you make. You can check the status of the defenses and how well you're contributing to the project at any time. May the Force be with you!
string_id message = new string_id (c_stringFile, "s_e0c642e");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Ok. You should know that if you help out with the defenses, you won't be able to do any other work here in the village until later. Is that ok?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Ok. You should know that if you help out with the defenses, you won't be able to do any other work here in the village until later. Is that ok?
//-- [RESPONSE NOTE]
//-- PLAYER: Oh. Maybe I'd better do something else then.
if (branchId == 5 && response == "s_f9d5461c")
{
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: I'm sorry you can't help out. May the Force be with you.
string_id message = new string_id (c_stringFile, "s_6f1f7b10");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Ok. You should know that if you help out with the defenses, you won't be able to do any other work here in the village until later. Is that ok?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: What would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: I'd like to see the project's current attributes.
if (branchId == 10 && response == "s_ff02a401")
{
quharek_phase_3_action_showPlayerProjectAttributes (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'What would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: What would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
if (branchId == 10 && response == "s_39019ea3")
{
//-- [NOTE]
if (quharek_phase_3_condition_isTrackingSlots (player, self))
{
//-- NPC: Which ingredient would you like to know about?
string_id message = new string_id (c_stringFile, "s_4ccd023a");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: Endrost Alloy
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: Shield Housing
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: Power Supply
boolean hasResponse2 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
//-- PLAYER: Unit Computer
boolean hasResponse3 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse3 = true;
}
//-- PLAYER: Regulator
boolean hasResponse4 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse4 = true;
}
//-- PLAYER: Shield Connections
boolean hasResponse5 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse5 = true;
}
//-- PLAYER: Primary Computer
boolean hasResponse6 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse6 = true;
}
//-- PLAYER: The overall project.
boolean hasResponse7 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse7 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_f580c83d");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_b200fa3f");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c61bebb1");
if (hasResponse3)
responses [responseIndex++] = new string_id (c_stringFile, "s_75024256");
if (hasResponse4)
responses [responseIndex++] = new string_id (c_stringFile, "s_10aecfa1");
if (hasResponse5)
responses [responseIndex++] = new string_id (c_stringFile, "s_1ccf69c4");
if (hasResponse6)
responses [responseIndex++] = new string_id (c_stringFile, "s_e9fef768");
if (hasResponse7)
responses [responseIndex++] = new string_id (c_stringFile, "s_a489b2f6");
setObjVar (player, "conversation.quharek_phase_3.branchId", 11);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'What would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: What would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
if (branchId == 10 && response == "s_c57c793")
{
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: Which ingredient would you like to know about?
string_id message = new string_id (c_stringFile, "s_4ccd023a");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: Endrost Alloy
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: Shield Housing
boolean hasResponse1 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: Power Supply
boolean hasResponse2 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
//-- PLAYER: Unit Computer
boolean hasResponse3 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse3 = true;
}
//-- PLAYER: Regulator
boolean hasResponse4 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse4 = true;
}
//-- PLAYER: Shield Connections
boolean hasResponse5 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse5 = true;
}
//-- PLAYER: Primary Computer
boolean hasResponse6 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse6 = true;
}
//-- PLAYER: The overall project
boolean hasResponse7 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse7 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_f580c83d");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_b200fa3f");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c61bebb1");
if (hasResponse3)
responses [responseIndex++] = new string_id (c_stringFile, "s_75024256");
if (hasResponse4)
responses [responseIndex++] = new string_id (c_stringFile, "s_10aecfa1");
if (hasResponse5)
responses [responseIndex++] = new string_id (c_stringFile, "s_1ccf69c4");
if (hasResponse6)
responses [responseIndex++] = new string_id (c_stringFile, "s_e9fef768");
if (hasResponse7)
responses [responseIndex++] = new string_id (c_stringFile, "s_212d314f");
setObjVar (player, "conversation.quharek_phase_3.branchId", 12);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'What would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Endrost Alloy
if (branchId == 11 && response == "s_f580c83d")
{
quharek_phase_3_action_showPlayerSlot1Quality (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Shield Housing
if (branchId == 11 && response == "s_b200fa3f")
{
quharek_phase_3_action_showPlayerSlot2Quality (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Power Supply
if (branchId == 11 && response == "s_c61bebb1")
{
quharek_phase_3_action_showPlayerSlot3Quality (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Unit Computer
if (branchId == 11 && response == "s_75024256")
{
quharek_phase_3_action_showPlayerSlot4Quality (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Regulator
if (branchId == 11 && response == "s_10aecfa1")
{
quharek_phase_3_action_showPlayerSlot5Quality (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Shield Connections
if (branchId == 11 && response == "s_1ccf69c4")
{
quharek_phase_3_action_showPlayerSlot6Quality (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Primary Computer
if (branchId == 11 && response == "s_e9fef768")
{
quharek_phase_3_action_showPlayerSlot7Quality (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: The overall project.
if (branchId == 11 && response == "s_a489b2f6")
{
quharek_phase_3_action_showPlayerProjectQuality (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Endrost Alloy
if (branchId == 12 && response == "s_f580c83d")
{
quharek_phase_3_action_showPlayerSlot1Quantity (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Shield Housing
if (branchId == 12 && response == "s_b200fa3f")
{
quharek_phase_3_action_showPlayerSlot2Quantity (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Power Supply
if (branchId == 12 && response == "s_c61bebb1")
{
quharek_phase_3_action_showPlayerSlot3Quantity (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Unit Computer
if (branchId == 12 && response == "s_75024256")
{
quharek_phase_3_action_showPlayerSlot4Quantity (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Regulator
if (branchId == 12 && response == "s_10aecfa1")
{
quharek_phase_3_action_showPlayerSlot5Quantity (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Shield Connections
if (branchId == 12 && response == "s_1ccf69c4")
{
quharek_phase_3_action_showPlayerSlot6Quantity (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: Primary Computer
if (branchId == 12 && response == "s_e9fef768")
{
quharek_phase_3_action_showPlayerSlot7Quantity (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
//-- [BRANCH NOTE]
//-- NPC: Which ingredient would you like to know about?
//-- [RESPONSE NOTE]
//-- PLAYER: The overall project
if (branchId == 12 && response == "s_212d314f")
{
quharek_phase_3_action_showPlayerProjectQuantity (player, self);
//-- [NOTE]
if (quharek_phase_3_condition__defaultCondition (player, self))
{
//-- NPC: What would you like to know about?
string_id message = new string_id (c_stringFile, "s_261bbc0d");
int numberOfResponses = 0;
boolean hasResponse = false;
//-- PLAYER: I'd like to see the project's current attributes.
boolean hasResponse0 = false;
if (quharek_phase_3_condition__defaultCondition (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
//-- PLAYER: I'd like to know about the quality of the ingredients people are giving.
boolean hasResponse1 = false;
if (quharek_phase_3_condition_isTrackingQuality (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
//-- PLAYER: I'd like to know about the amount of ingredients people are giving.
boolean hasResponse2 = false;
if (quharek_phase_3_condition_isTrackingQuantity (player, self))
{
++numberOfResponses;
hasResponse = true;
hasResponse2 = true;
}
if (hasResponse)
{
int responseIndex = 0;
string_id responses [] = new string_id [numberOfResponses];
if (hasResponse0)
responses [responseIndex++] = new string_id (c_stringFile, "s_ff02a401");
if (hasResponse1)
responses [responseIndex++] = new string_id (c_stringFile, "s_39019ea3");
if (hasResponse2)
responses [responseIndex++] = new string_id (c_stringFile, "s_c57c793");
setObjVar (player, "conversation.quharek_phase_3.branchId", 10);
npcSpeak (player, message);
npcSetConversationResponses (player, responses);
}
else
{
removeObjVar (player, "conversation.quharek_phase_3.branchId");
npcSpeak (player, message);
npcEndConversation (player);
}
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: All conditions for OnNpcConversationResponse for branch 'Which ingredient would you like to know about?' were false.");
return SCRIPT_CONTINUE;
}
chat.chat (self, "Error: Fell through all branches and responses for OnNpcConversationResponse.");
removeObjVar (player, "conversation.quharek_phase_3.branchId");
return SCRIPT_CONTINUE;
}
// ======================================================================