How can I change the demo menu?
-
- Posts: 12
- Joined: Sun Aug 06, 2023 7:43 pm
How can I change the demo menu?
I added a demo menu to the scene, but I don't understand how I can add a new button to this menu or remove a button? how can I change the appearance of the menu?
Re: How can I change the demo menu?
Hi,
The DemoMenu script is only designed to run the Dialogue System's demo scene. However, you can adapt it for your own use if you want. To change the look, create and assign a new GUI Skin. To add or remove buttons, you'll need to modify the script. If you do this, I recommend making a copy of the script and using & modifying the copy. That way you won't accidentally overwrite your customizations when you update the Dialogue System.
The DemoMenu script is only designed to run the Dialogue System's demo scene. However, you can adapt it for your own use if you want. To change the look, create and assign a new GUI Skin. To add or remove buttons, you'll need to modify the script. If you do this, I recommend making a copy of the script and using & modifying the copy. That way you won't accidentally overwrite your customizations when you update the Dialogue System.
-
- Posts: 12
- Joined: Sun Aug 06, 2023 7:43 pm
Re: How can I change the demo menu?
yes, but I don't understand how I can remove the buttons because the demo menu of the script is empty. I can't work with the GUI. I want to create my own menu with a user interface, which I will do. How can I add to the buttons the method of saving the game or loading the game and other methods that are in the demo menu?
if the image dont loading:
Demo menu script:
// Copyright (c) Pixel Crushers. All rights reserved.
using UnityEngine;
namespace PixelCrushers.DialogueSystem.Demo.Wrappers
{
/// <summary>
/// This wrapper class keeps references intact if you switch between the
/// compiled assembly and source code versions of the original class.
/// </summary>
[AddComponentMenu("Pixel Crushers/Dialogue System/Actor/Demo/Demo Menu")]
public class DemoMenu : PixelCrushers.DialogueSystem.Demo.DemoMenu
{
}
}
if the image dont loading:
Demo menu script:
// Copyright (c) Pixel Crushers. All rights reserved.
using UnityEngine;
namespace PixelCrushers.DialogueSystem.Demo.Wrappers
{
/// <summary>
/// This wrapper class keeps references intact if you switch between the
/// compiled assembly and source code versions of the original class.
/// </summary>
[AddComponentMenu("Pixel Crushers/Dialogue System/Actor/Demo/Demo Menu")]
public class DemoMenu : PixelCrushers.DialogueSystem.Demo.DemoMenu
{
}
}
Re: How can I change the demo menu?
Hi,
You're looking at the wrapper class, as explained in the comment at the top of the script. Please open the other DemoMenu.cs, which is located in Plugins > Pixel Crushers > Dialogue System > Scripts > Demo Scripts.
You're looking at the wrapper class, as explained in the comment at the top of the script. Please open the other DemoMenu.cs, which is located in Plugins > Pixel Crushers > Dialogue System > Scripts > Demo Scripts.
-
- Posts: 12
- Joined: Sun Aug 06, 2023 7:43 pm
Re: How can I change the demo menu?
Thank you so much!
Re: How can I change the demo menu?
Glad to help!