Files
2018-06-07 00:32:29 +01:00

1860 lines
76 KiB
Java
Executable File

package script.conversation;
import script.library.ai_lib;
import script.library.chat;
import script.library.utils;
import script.*;
public class ep3_omwaan extends script.base_script
{
public ep3_omwaan()
{
}
public static String c_stringFile = "conversation/ep3_omwaan";
public boolean ep3_omwaan_condition__defaultCondition(obj_id player, obj_id npc) throws InterruptedException
{
return true;
}
public boolean ep3_omwaan_condition_doesnt_know_Shiryyywook(obj_id player, obj_id npc) throws InterruptedException
{
return utils.canSpeakWookiee(player, npc);
}
public void ep3_omwaan_action_grantSkill_Shiryyywook(obj_id player, obj_id npc) throws InterruptedException
{
playMusic(player, "sound/music_acq_academic.snd");
grantSkill(player, "social_language_wookiee_comprehend");
}
public int ep3_omwaan_handleBranch1(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_246"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_248");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_250");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_298");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_306");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 2);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_374"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_376");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_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_378");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 34);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch2(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_250"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_252");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_254");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_262");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_282");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 3);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_298"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_300");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_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_302");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 15);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_306"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_308");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_310");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_362");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 17);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch3(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_254"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_256");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_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_258");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 4);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_262"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_264");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_266");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_278");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 6);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_282"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_284");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_286");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_290");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_294");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 11);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch4(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_258"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_260");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch6(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_266"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_268");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_270");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_274");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 7);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_278"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_280");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch7(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_270"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_272");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_274"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_276");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch11(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_286"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_288");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_290"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_292");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_294"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_296");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch15(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_302"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_304");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch17(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_310"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_312");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_314");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_326");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_350");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 18);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_362"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_364");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_366");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_370");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 31);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch18(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_314"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_316");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_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_318");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 19);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_326"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_328");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_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_330");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 22);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_350"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_352");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_354");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_358");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 28);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch19(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_318"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_320");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_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_322");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 20);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch20(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_322"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_324");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch22(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_330"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_332");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_334");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_342");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 23);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch23(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_334"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_336");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_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_338");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 24);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_342"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
ep3_omwaan_action_grantSkill_Shiryyywook(player, npc);
string_id message = new string_id(c_stringFile, "s_344");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_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_346");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 26);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch24(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_338"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_340");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch26(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_346"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_348");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch28(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_354"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_356");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_358"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_360");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch31(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_366"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_368");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_370"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_372");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch34(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_378"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_380");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch36(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_384"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_386");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_388");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_392");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 37);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_396"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_398");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_400");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_440");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 40);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_444"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_446");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_404");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_420");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_436");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 41);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch37(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_388"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_390");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_392"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_394");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch40(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_400"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_402");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_404");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_420");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_436");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 41);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_440"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_442");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch41(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_404"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_406");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_408");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_412");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_416");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 42);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_420"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_422");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_424");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_428");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_432");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 46);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_436"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_438");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch42(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_408"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_410");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_412"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_414");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_416"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_418");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch46(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_424"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_426");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_428"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_430");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_432"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_434");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int ep3_omwaan_handleBranch52(obj_id player, obj_id npc, string_id response) throws InterruptedException
{
if (response.equals("s_404"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_406");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_408");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_412");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_416");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 42);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_420"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_422");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_424");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_428");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_432");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 46);
npcSpeak(player, message);
npcSetConversationResponses(player, responses);
}
else
{
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
}
return SCRIPT_CONTINUE;
}
}
if (response.equals("s_436"))
{
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_438");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
npcEndConversationWithMessage(player, message);
return SCRIPT_CONTINUE;
}
}
return SCRIPT_DEFAULT;
}
public int OnInitialize(obj_id self) throws InterruptedException
{
if ((!isMob(self)) || (isPlayer(self)))
{
detachScript(self, "conversation.ep3_omwaan");
}
setCondition(self, CONDITION_CONVERSABLE);
setCondition(self, CONDITION_INTERESTING);
setInvulnerable(self, true);
return SCRIPT_CONTINUE;
}
public int OnAttach(obj_id self) throws InterruptedException
{
setCondition(self, CONDITION_CONVERSABLE);
setCondition(self, CONDITION_INTERESTING);
setInvulnerable(self, true);
return SCRIPT_CONTINUE;
}
public int OnObjectMenuRequest(obj_id self, obj_id player, menu_info menuInfo) throws InterruptedException
{
int menu = menuInfo.addRootMenu(menu_info_types.CONVERSE_START, null);
menu_info_data menuInfoData = menuInfo.getMenuItemById(menu);
menuInfoData.setServerNotify(false);
setCondition(self, CONDITION_CONVERSABLE);
faceTo(self, player);
return SCRIPT_CONTINUE;
}
public int OnIncapacitated(obj_id self, obj_id killer) throws InterruptedException
{
clearCondition(self, CONDITION_CONVERSABLE);
detachScript(self, "conversation.ep3_omwaan");
return SCRIPT_CONTINUE;
}
public boolean npcStartConversation(obj_id player, obj_id npc, String convoName, string_id greetingId, prose_package greetingProse, string_id[] responses) throws InterruptedException
{
Object[] objects = new Object[responses.length];
System.arraycopy(responses, 0, objects, 0, responses.length);
return npcStartConversation(player, npc, convoName, greetingId, greetingProse, objects);
}
public int OnStartNpcConversation(obj_id self, obj_id player) throws InterruptedException
{
obj_id npc = self;
if (ai_lib.isInCombat(npc) || ai_lib.isInCombat(player))
{
return SCRIPT_OVERRIDE;
}
if (ep3_omwaan_condition_doesnt_know_Shiryyywook(player, npc))
{
string_id message = new string_id(c_stringFile, "s_244");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_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_246");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_374");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 1);
npcStartConversation(player, npc, "ep3_omwaan", message, responses);
}
else
{
chat.chat(npc, player, message);
}
return SCRIPT_CONTINUE;
}
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
string_id message = new string_id(c_stringFile, "s_382");
int numberOfResponses = 0;
boolean hasResponse = false;
boolean hasResponse0 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse0 = true;
}
boolean hasResponse1 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++numberOfResponses;
hasResponse = true;
hasResponse1 = true;
}
boolean hasResponse2 = false;
if (ep3_omwaan_condition__defaultCondition(player, npc))
{
++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_384");
}
if (hasResponse1)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_396");
}
if (hasResponse2)
{
responses[responseIndex++] = new string_id(c_stringFile, "s_444");
}
utils.setScriptVar(player, "conversation.ep3_omwaan.branchId", 36);
npcStartConversation(player, npc, "ep3_omwaan", message, responses);
}
else
{
chat.chat(npc, player, message);
}
return SCRIPT_CONTINUE;
}
chat.chat(npc, "Error: All conditions for OnStartNpcConversation were false.");
return SCRIPT_CONTINUE;
}
public int OnNpcConversationResponse(obj_id self, String conversationId, obj_id player, string_id response) throws InterruptedException
{
if (!conversationId.equals("ep3_omwaan"))
{
return SCRIPT_CONTINUE;
}
obj_id npc = self;
int branchId = utils.getIntScriptVar(player, "conversation.ep3_omwaan.branchId");
if (branchId == 1 && ep3_omwaan_handleBranch1(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 2 && ep3_omwaan_handleBranch2(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 3 && ep3_omwaan_handleBranch3(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 4 && ep3_omwaan_handleBranch4(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 6 && ep3_omwaan_handleBranch6(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 7 && ep3_omwaan_handleBranch7(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 11 && ep3_omwaan_handleBranch11(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 15 && ep3_omwaan_handleBranch15(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 17 && ep3_omwaan_handleBranch17(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 18 && ep3_omwaan_handleBranch18(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 19 && ep3_omwaan_handleBranch19(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 20 && ep3_omwaan_handleBranch20(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 22 && ep3_omwaan_handleBranch22(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 23 && ep3_omwaan_handleBranch23(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 24 && ep3_omwaan_handleBranch24(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 26 && ep3_omwaan_handleBranch26(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 28 && ep3_omwaan_handleBranch28(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 31 && ep3_omwaan_handleBranch31(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 34 && ep3_omwaan_handleBranch34(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 36 && ep3_omwaan_handleBranch36(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 37 && ep3_omwaan_handleBranch37(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 40 && ep3_omwaan_handleBranch40(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 41 && ep3_omwaan_handleBranch41(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 42 && ep3_omwaan_handleBranch42(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 46 && ep3_omwaan_handleBranch46(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
if (branchId == 52 && ep3_omwaan_handleBranch52(player, npc, response) == SCRIPT_CONTINUE)
{
return SCRIPT_CONTINUE;
}
chat.chat(npc, "Error: Fell through all branches and responses for OnNpcConversationResponse.");
utils.removeScriptVar(player, "conversation.ep3_omwaan.branchId");
return SCRIPT_CONTINUE;
}
}