SmartlyDressedGames / Unturned-3.x-Community

Community portion of the Unturned-3.x repo. If you have access to the source code you can find it here:
https://github.com/SmartlyDressedGames/Unturned-3.x/
88 stars 18 forks source link

[NPC] Recognition Issue #1964

Closed INeedHelp225 closed 4 years ago

INeedHelp225 commented 4 years ago

Having more NPC issues unfortunately.

I'm trying to get the NPC to refuse the player if they have completed the opposite faction's quest, but he does not do it, rather, he just uses his normal neutral phrase to the player and nothing more. He uses his friendly phrase when allied, he uses his questionable phrase when weird reputation, and he even does his villain phrase, but not the enemy phrase. Mind you, most of this is WIP so there's gonna be some strangeness.

GUID 5181d8f7b9ed42729f70d6d769552747

Type Dialogue ID 30010

//remember use same rank flags as Nelson liberator

Messages 9

// Welcome neut no experience in faction Message_0_Pages 1 Message_0_Responses 1 Response_0_Dialogue 30014

// Ensign Message_1_Pages 1 Message_1_Responses 1 Message_1_Response_0 1 Message_1_Conditions 1 // Ensign Rank Checker Message_1_Condition_0_Type Flag_Short Message_1_Condition_0_ID 29 Message_1_Condition_0_Value 1 Message_1_Condition_0_Logic Equal

// Lieutenant Message_2_Pages 1 Message_2_Responses 1 Message_2_Response_0 1 Message_2_Conditions 1 // Lieutenant Rank Checker Message_2_Condition_0_Type Flag_Short Message_2_Condition_0_ID 29 Message_2_Condition_0_Value 2 Message_2_Condition_0_Logic Equal

// Major Message_3_Pages 1 Message_3_Responses 1 Message_3_Response_0 1 Message_3_Conditions 1 // Major Rank Checker Message_3_Condition_0_Type Flag_Short Message_3_Condition_0_ID 29 Message_3_Condition_0_Value 3 Message_3_Condition_0_Logic Equal

// Gone Bad Message_4_Pages 1 Message_4_Responses 1 Message_4_Response_0 2 Message_4_Conditions 1 Message_4_Condition_0_Type Reputation Message_4_Condition_0_Value -5 Message_4_Condition_0_Logic Less_Than_Or_Equal_To

// Questionable Message_5_Pages 1 Message_5_Responses 1 Message_5_Response_0 3 Message_5_Conditions 1 Message_5_Condition_0_Type Reputation Message_5_Condition_0_Value 3 Message_5_Condition_0_Logic Less_Than_Or_Equal_To

// Hero +5 rep (give when got citizenship flag) Message_6_Pages 1 Message_6_Responses 1 Message_6_Response_0 1

//other faction Message_7_Pages 1 Message_7_Responses 1 Message_7_Response_0 4 Message_7_Conditions 1 Message_7_Condition_0_Type Quest Message_7_Condition_0_Logic Equal Message_7_Condition_0_ID 50958 Message_7_Condition_0_Status Completed

//apart of faction Message_8_Pages 1 Message_8_Responses 1 Message_8_Response_0 1 Message_8_Conditions 1 Message_8_Condition_0_Type Flag_Short Message_8_Condition_0_ID 3000 Message_8_Condition_0_Value 2 Message_8_Condition_0_Logic Greater_Than Message_8_Condition_0_Allow_Unset

Responses 5

English:

Message_0_Page_0 Stand back there! Message_1_Page_0 Good to see you Ensign ! Message_2_Page_0 Good to see you Lieutenant ! Message_3_Page_0 Good to see you Major ! Message_4_Page_0 You were so good once, what happened ? Message_5_Page_0 Feelin' awfully uneasy around you, newbie. Behave. Message_6_Page_0 Good to see you ! Message_7_Page_0 Get out now Remnant filth. Message_8_Page_0 Howdy there .

Response_0 Whoa, where am I? Response_1 You too ! Response_2 I'm in a phase. Response_3 I'm not here to cause trouble, I'll do what you say. Response_4 Calm down, I'm leaving, I'm leaving!

iBowie commented 4 years ago

You need to change message order. Game checks conditions of all messages from top to bottom. Your first message does meet all the conditions, since there isn't any.

SDGNelson commented 4 years ago

@iBowie is correct, thanks for answering.

INeedHelp225 commented 4 years ago

@iBowie What do you mean? Change message order in what manner? Put message_7 in message 2's place or something?

iBowie commented 4 years ago

You just need to put all messages with conditions to the top, and one neutral message in the bottom

INeedHelp225 commented 4 years ago

@iBowie you have no idea about how much this has helped me! The whole guard script and his runoffs dialogues all work perfectly, thank you!