How to make Achievements?
Re: How to make Achievements?
Glad to know that you have a clear idea about the implementation... I was thinking about how to do it with the save system and I was even considering to have 2 different saving systems.
Re: How to make Achievements?
Hi,
Here's an early release copy of the Visual Novel Framework 2.0.3:
VisualNovelFramework_2_0_3b2.unitypackage
It has these improvements:
Here's an early release copy of the Visual Novel Framework 2.0.3:
VisualNovelFramework_2_0_3b2.unitypackage
It has these improvements:
- Added Achievements.
- Added Quest Log button.
- Added background fading.
- Updated VNLoadLevel() sequencer command to support Save System.
- Panels now support open/close animations.
Re: How to make Achievements?
Awesome! I will play with it during the weekend. I'll let you know how it goes.
Thanks a lot Tony!!!
Thanks a lot Tony!!!
Re: How to make Achievements?
Hi Tony,
It has been a while since I started my project from the Start scene, and I'm getting a few issues before installing the update:
1) Error in the "Load Typewriter Speed" script:
2) Save Helper script doesn't have any conversation and I cannot select any. I thought it might be missing the dialogue database, but it seems correct...
I'm running version VN2.0.2 using DS 2.0.5
It has been a while since I started my project from the Start scene, and I'm getting a few issues before installing the update:
1) Error in the "Load Typewriter Speed" script:
I checked my Visual Novel Menu Canvas and it has attached the "Load Typewriter Speed" script. I even replaced the script for a fresh copy just in case was corrupted, but no luck. The only way to bypass the error is disabling the script.NullReferenceException: Object reference not set to an instance of an object
PixelCrushers.DialogueSystem.VisualNovelFramework.LoadTypewriterSpeed.Start () (at Assets/Dialogue System Extras/Visual Novel Framework/Scripts/LoadTypewriterSpeed.cs:19)
2) Save Helper script doesn't have any conversation and I cannot select any. I thought it might be missing the dialogue database, but it seems correct...
I'm running version VN2.0.2 using DS 2.0.5
Re: How to make Achievements?
Hi,
Please try this version:
VisualNovelFramework_2_0_3b3.unitypackage
If the Save Helper's conversation dropdown isn't working, you can now assign the dialogue database to the Save Helper so it knows what database to get conversation titles from.
Please try this version:
VisualNovelFramework_2_0_3b3.unitypackage
If the Save Helper's conversation dropdown isn't working, you can now assign the dialogue database to the Save Helper so it knows what database to get conversation titles from.
Re: How to make Achievements?
I think I know why the Save Helper wasn't working properly:
I had disabled the Dialogue Manager by default and I enabled through playmaker. That was causing me a lot of weird behaviors in some scripts. Now seems to be fine.
A few questions more:
1) Does the system allow to have more than one page of achievements?
2) I was thinking to create a sort of album where you can have different characters pictures and clicking on them, the player would access to a gallery of achievements you unlocked with them. Is this something I could achieve with the current system?
3) It could be a good idea to have the achievements panel accessible through the start scene as well.
4) How the localization work with the achievements names and descriptions? I noticed that the name is always displayed so the variable cannot change when I call the UnlockAchievement.
5) The LUA code through an exception when I don't start the game from the start scene. I guess because the Visual Novel Menu Canvas is not loaded in the gameplay scene. Is there a work around?
I had disabled the Dialogue Manager by default and I enabled through playmaker. That was causing me a lot of weird behaviors in some scripts. Now seems to be fine.
A few questions more:
1) Does the system allow to have more than one page of achievements?
2) I was thinking to create a sort of album where you can have different characters pictures and clicking on them, the player would access to a gallery of achievements you unlocked with them. Is this something I could achieve with the current system?
3) It could be a good idea to have the achievements panel accessible through the start scene as well.
4) How the localization work with the achievements names and descriptions? I noticed that the name is always displayed so the variable cannot change when I call the UnlockAchievement.
5) The LUA code through an exception when I don't start the game from the start scene. I guess because the Visual Novel Menu Canvas is not loaded in the gameplay scene. Is there a work around?
But so far the system seems to be working fine!Dialogue System: Lua code 'UnlockAchievement("achievementName")
' threw exception 'Tried to invoke a function call on a non-function value. If you're calling a function, is it registered with Lua?'
Last edited by Alatriste on Sun Nov 11, 2018 6:24 am, edited 1 time in total.
Backgrounds Scene Transition
I saw that the Standard Scene transition is also included. However, I couldn't make it work for the background transition (it works when changing the scenes).
In the manual said:
In the manual said:
But I couldn't find the "Fade duration field".You can use the Dialogue Manager’s Scene Transition Manager to fade to black before changing
backgrounds and then fade back in after changing backgrounds. To do this, set the Background
Manager component’s Fade Duration field or use the Lua function BackgroundFadeDuration:
Re: How to make Achievements?
It's not designed that way. Maybe it could be extended. What about using a scroll rect?
Good idea. I'll do that. In the meantime, you can add a button to the Start scene yourself. Configure its OnClick() event to call the Visual Novel Menu Canvas's Menus.ShowAchievements.
If a translation exists in the Text Table that's assigned to the Dialogue Manager, it will use the translation. In the example scene, there is an achievement named "Creep". If the Text Table has a field named "Creep", it will use the translation.
Add the Achievements component to the Gameplay scene's Dialogue Manager. In fact, in the Start scene you can move the Achievements component to the Dialogue Manager and save it as a prefab so your testing Dialogue Manager in the Gameplay scene will receive the same changes.
The Fade Duration field should be on the Background Manager component in the Gameplay scene. This component is on Background Canvas > Images > Background.Alatriste wrote: ↑Sun Nov 11, 2018 6:03 amI saw that the Standard Scene transition is also included. However, I couldn't make it work for the background transition (it works when changing the scenes).
In the manual said:
But I couldn't find the "Fade duration field".You can use the Dialogue Manager’s Scene Transition Manager to fade to black before changing
backgrounds and then fade back in after changing backgrounds. To do this, set the Background
Manager component’s Fade Duration field or use the Lua function BackgroundFadeDuration:
Re: How to make Achievements?
That would work.It's not designed that way. Maybe it could be extended. What about using a scroll rect?
Fount it. However, the value resets to 0 as soon as I press the start button.The Fade Duration field should be on the Background Manager component in the Gameplay scene. This component is on Background Canvas > Images > Background.
Sorry, I don't think I explain myself properly. The thing is that I have to define the Name (for instance, "C1_Actor1Item1") of the achievement and the Description. The name is displayed during the alert, no matter the description, therefore, I cannot use the name convention or the player will see something like: "Achievement unlocked: C1_Actor1Item1"If a translation exists in the Text Table that's assigned to the Dialogue Manager, it will use the translation. In the example scene, there is an achievement named "Creep". If the Text Table has a field named "Creep", it will use the translation.
Re: How to make Achievements?
Sounds like a bug. I'll double check this and fix it if necessary.
I understand now. I'll make it so you can show the name and/or description, but neither will be required. You will be able to use {0} for the name and {1} for the description. So if you do this:Alatriste wrote: ↑Sun Nov 11, 2018 11:08 amSorry, I don't think I explain myself properly. The thing is that I have to define the Name (for instance, "C1_Actor1Item1") of the achievement and the Description. The name is displayed during the alert, no matter the description, therefore, I cannot use the name convention or the player will see something like: "Achievement unlocked: C1_Actor1Item1"If a translation exists in the Text Table that's assigned to the Dialogue Manager, it will use the translation. In the example scene, there is an achievement named "Creep". If the Text Table has a field named "Creep", it will use the translation.
Code: Select all
Achievement unlocked: {1}