Dialogue System for Unity with plyGame
-
- Posts: 57
- Joined: Sun Feb 12, 2017 2:11 pm
Re: Dialogue System for Unity with plyGame
Is there a way that I could sort by ID inside the group quest all the quest in the complete quest log?
Re: Dialogue System for Unity with plyGame
Hi David,
You can also use the "Debug" block to print the current state to the Console window to double-check that it's the state you expect.
Try converting "Get the state of quest" and "Get the state of quest...entry" to Strings, such as:davidsibya08 wrote:I have a quest item that will be disabled if a certain quest entry is not yet active,
but when it is active it does not become active though I think I provided the right
set of codes/blocks. When I paused the game and set the object to active then plays
the game back, it does not set any quest/quest entry state to its expected state.
It says:
[Flow/Comparison/a = b] in [Hermit Fendrel's Hammer/State 0/On AreaTrigger Enter]: Could not compare the values.
Why are these not function so well?
The On Start is working good.
The Update is not at all.
The AreaTriggerEnter Event is not working well also.
These are the blocks I made.
You can also use the "Debug" block to print the current state to the Console window to double-check that it's the state you expect.
Not without customizing the quest log window script. By default, they're sorted alphabetically by name.davidsibya08 wrote:Is there a way that I could sort by ID inside the group quest all the quest in the complete quest log?
-
- Posts: 57
- Joined: Sun Feb 12, 2017 2:11 pm
Re: Dialogue System for Unity with plyGame
Sir Tony,
You haven't read my previous post Sir Tony,
Is that possible to fix sir? Or should just number my quests arrangements?
You haven't read my previous post Sir Tony,
As a String works for me now, thanks Sir Tony.Sir Tony,
It still doesn't add anything to my attributes. I wonder what is causing the problem.
I tried all things possible but it still remain as it is. -_-
My option is do do scripting in terms of rewarding the player, I wanted to execute the script after completing the quest.
But is that possible? After I complete the conversation I execute the script that rewards item and attributes.
If so, you know exactly what I need to do. Thank you Sir Tony.
Is that possible to fix sir? Or should just number my quests arrangements?
Re: Dialogue System for Unity with plyGame
Put the script in the dialogue entry node where the player completes the quest. The plyGameBridge component will apply the changes to your player at the end of the conversation.davidsibya08 wrote:My option is do do scripting in terms of rewarding the player, I wanted to execute the script after completing the quest.
But is that possible? After I complete the conversation I execute the script that rewards item and attributes.
For example:
- Dialogue Text: "Thank you for completing my quest."
- Script: Actor["Player"].Experience_CurrentValue = Actor["Player"].Experience_CurrentValue + 50;
ShowAlert("Gained 50 experience")
Yes. Inspect each quest. Use numbers in the Name field to specify how to sort the quests. For example:davidsibya08 wrote:Is that possible to fix sir? [Quest order]
- Name: 02 Forge Sword
- Name: 01 Mine Iron
- Name: 03 Defeat Dragon
- 01 Mine Iron
- 02 Forge Sword
- 03 Defeat Dragon
- Name: 02 Forge Sword, Display Name: Forge a Magical Sword
- Name: 01 Mine Iron, Display Name: Mine Iron Ore for a Sword
- Name: 03 Defeat Dragon, Display Name: Defeat the Evil Dragon with your Sword
- Mine Iron Ore for a Sword
- Forge a Magical Sword
- Defeat the Evil Dragon with your Sword
-
- Posts: 57
- Joined: Sun Feb 12, 2017 2:11 pm
Re: Dialogue System for Unity with plyGame
Hello Sir Tony,
First of all, Thank you very much for all your untiring support.
In regards with the script, what I meant back there is the C# Scripts.
Because I really don't get why my attributes in not updating so I wonder If I
could add a C# after the end of the dialogue node entry that will reward the Player.
Therefore, in that script I will set the rewards of the Player ( Maybe I would just make
a generic script for all).
By the way, the quest log window works great for sorting the Quest Titles.
Thank you very much Sir Tony.
First of all, Thank you very much for all your untiring support.
In regards with the script, what I meant back there is the C# Scripts.
Because I really don't get why my attributes in not updating so I wonder If I
could add a C# after the end of the dialogue node entry that will reward the Player.
Therefore, in that script I will set the rewards of the Player ( Maybe I would just make
a generic script for all).
By the way, the quest log window works great for sorting the Quest Titles.
Thank you very much Sir Tony.
Re: Dialogue System for Unity with plyGame
If you want to add a C# script, you can add one with an OnConversationEnd method. Look at plyGameBridge.cs's SyncLuaToPlyGame() method for an example of how to change plyGame values in your own scripts.
However, I recommend changing the values inside a conversation, since plyGameBridge does a lot of this work for you.
However, I recommend changing the values inside a conversation, since plyGameBridge does a lot of this work for you.
-
- Posts: 57
- Joined: Sun Feb 12, 2017 2:11 pm
Re: Dialogue System for Unity with plyGame
Hi Sir Tony,
I don't really why it doesn't work on the Script field of the conversation but I figured out something worth trying for.
I just set up an empty game object on the radius of my NPC ( Hermit Fendrel) and provided a OnTriggerEnter and on LateUpdate condition which
states that if the Player completed the quest it will be rewarded with the following according to it's quest completed. It will be destroyed once all conditions inside the object are true.
I will ask you later if there are some errors or malfunctioning codes. Thank you Sir Tony!
I don't really why it doesn't work on the Script field of the conversation but I figured out something worth trying for.
I just set up an empty game object on the radius of my NPC ( Hermit Fendrel) and provided a OnTriggerEnter and on LateUpdate condition which
states that if the Player completed the quest it will be rewarded with the following according to it's quest completed. It will be destroyed once all conditions inside the object are true.
I will ask you later if there are some errors or malfunctioning codes. Thank you Sir Tony!
-
- Posts: 57
- Joined: Sun Feb 12, 2017 2:11 pm
Re: Dialogue System for Unity with plyGame
Hi Sir Tony,
Sir how do I put in my C# a method that identifies that the conversation started?
Sir how do I put in my C# a method that identifies that the conversation started?
Re: Dialogue System for Unity with plyGame
Hi David,
Add a method named "OnConversationStart". Your script must be on the Dialogue Manager or the conversation's Actor or Conversant. Here's an example:
LogConversationStart.cs
There is also a plyGame Event for OnConversationStart.
Add a method named "OnConversationStart". Your script must be on the Dialogue Manager or the conversation's Actor or Conversant. Here's an example:
LogConversationStart.cs
Code: Select all
using UnityEngine;
using PixelCrushers.DialogueSystem;
public class LogConversationStart : MonoBehaviour {
void OnConversationStart(Transform actor) {
Debug.Log("Conversation started: " + DialogueManager.LastConversationStarted);
}
}
-
- Posts: 57
- Joined: Sun Feb 12, 2017 2:11 pm
Re: Dialogue System for Unity with plyGame
Hi Sir Tony,
Sir how can I make this kind of dialogue/conversation?
Something like in this game, wherein the actor is the last giving the convo and when I clicked continue
it will show all my UIs that were hidden.
https://www.youtube.com/watch?v=qYOv_rw ... cBma7tDLQE
In addition, is it possible that a Unity GUI Button can be used to skip/continue conversation using plyBlox?
Sir how can I make this kind of dialogue/conversation?
Something like in this game, wherein the actor is the last giving the convo and when I clicked continue
it will show all my UIs that were hidden.
https://www.youtube.com/watch?v=qYOv_rw ... cBma7tDLQE
In addition, is it possible that a Unity GUI Button can be used to skip/continue conversation using plyBlox?