- Joined
- Apr 14, 2012
- Messages
- 2,906
I'm having a little difficulty when it comes to quests that needs items to be acquired in order for it to be complete. For example, a quest states that the player gets those two items, and when the player picks up one of those items, a text would say "you have picked up + (string(item_counter) + /2", but in my trigger when the player picks up one item no text shows, nor is the quest description showing that the player has picked up an item change.
-
Villager Jack Give Quest
-

Events
-


Unit - A unit Sells an item (from shop)
-
-

Conditions
-


(Selling unit) Equal to NPC[4]
-
-

Actions
-


Set Quest_scroll = (Sold Item)
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




Quest_Count Less than or equal to 2
-
-



Then - Actions
-




If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-





If - Conditions
-






VillagerJack_Boolean Equal to True
-
-





Then - Actions
-






Item - Remove Quest_scroll
-






Game - Display to (All players) the text: You cannot take the...
-
-





Else - Actions
-






Set VillagerJack_Boolean = True
-






Special Effect - Destroy NPC_SFX[4]
-






Item - Remove Quest_scroll
-






Quest - Create a Optional quest titled Lumber is Needed with the description [GRADE D] Collect ..., using icon path ReplaceableTextures\CommandButtons\BTNHumanLumberMill.blp
-






Set Quest[5] = (Last created quest)
-






Quest - Mark Quest[5] as Discovered
-






Quest - Create a quest requirement for Quest[5] with the description Collected Lumber: 0...
-






Set Quest_Requirement[5] = (Last created quest requirement)
-






Quest - Mark Quest_Requirement[5] as Incomplete
-






Wait 0.30 seconds
-






Quest - Display to (All players) the Quest Discovered message: Quest Discovered: C...
-






Quest - Flash the quest dialog button
-






Wait 4.00 seconds
-






Cinematic - Clear the screen of text messages for (All players)
-






Set Quest_Count = (Quest_Count + 1)
-






Set Temp_Point = (Center of Lumber 1 <gen>)
-






Item - Create Construction Lumber at Temp_Point
-






Set Wood[1] = (Last created item)
-






Custom script: call RemoveLocation(udg_Temp_Point)
-






Set Temp_Point = (Center of Lumber 2 <gen>)
-






Item - Create Construction Lumber at Temp_Point
-






Set Wood[2] = (Last created item)
-






Custom script: call RemoveLocation(udg_Temp_Point)
-
-
-
-



Else - Actions
-




Item - Remove Quest_scroll
-




Game - Display to (All players) the text: You can only take t...
-
-
-
-
-
Lumber Aquire
-

Events
-


Unit - A unit Acquires an item
-
-

Conditions
-


((Item being manipulated) Equal to Wood[1]) or ((Item being manipulated) Equal to Wood[2])
-
-

Actions
-


Set Wood_Counter = (Wood_Counter + 1)
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




Wood_Counter Equal to 2
-
-



Then - Actions
-




Quest - Change the description of Quest_Requirement[5] to (Collected Lumber: + ((String(Wood_Counter)) + /2))
-




Quest - Mark Quest_Requirement[5] as Completed
-




Quest - Display to (All players) the Quest Update message: Quest Update: Requi...
-
-



Else - Actions
-




Quest - Change the description of Quest_Requirement[5] to (Collected Lumber: + ((String(Wood_Counter)) + /2))
-




Game - Display to (All players) the text: (You have collected + ((String(Wood_Counter)) + Piece(s) of Lumber))
-
-
-
-
Last edited:




