Demo Spawner Missing

Announcements, support questions, and discussion for Quest Machine.
Gandoff
Posts: 20
Joined: Mon Jan 01, 2018 7:13 pm

Demo Spawner Missing

Post by Gandoff »

I recently purchased Quest Machine and I really like what I have seen so far. I have run into a problem. The spawner for the carrots and other quests are not spawning. Did I miss a guide telling me how to set up these quests?

I did get the Find Coins quest to work just fine.

Thanks.
Gandoff
User avatar
Tony Li
Posts: 20756
Joined: Thu Jul 18, 2013 1:27 pm

Re: Demo Spawner Missing

Post by Tony Li »

Hi,

Thanks for buying Quest Machine!

Does the spawner work in the Demo scene?
Gandoff
Posts: 20
Joined: Mon Jan 01, 2018 7:13 pm

Re: Demo Spawner Missing

Post by Gandoff »

No. I tried that second thinking I had done something wrong porting the code into mine.

What starts the spawner?
I noticed that the quests' actions do not have a start spawner message.
The spawners do have Autostart checked though.

I do not see the Spawner Manager connected to anything. Should it be?
User avatar
Tony Li
Posts: 20756
Joined: Thu Jul 18, 2013 1:27 pm

Re: Demo Spawner Missing

Post by Tony Li »

If you import Quest Machine into a new, empty project, does spawning work in the Demo scene? If not, please let me know what versions of Unity and Quest Machine you're using, and if Unity's Console window is reporting any errors or warnings. The Quest Machine version is in the welcome window (Tools > Pixel Crushers > Quest Machine > Welcome Window) and in the file Plugins / Pixel Crushers / Quest Machine / _README.txt.

When Auto Start is ticked, the Spawner should spawn enough instances of the prefabs that the Min value is reached. For example, the Wolf Spawner's Min is 1. As long as there's 1 wolf in the scene, Min has been reached. Then it will spawn another wolf at a Spawn Rate of 1 every 20 seconds until it reaches Max (which is 5 for the Wolf Spawner).

If Stop When Min Reached is ticked, it will stop as soon as the Min number have been reached. Otherwise, it will keep spawning to try to maintain Max. So if you kill 2 wolves, bringing the current number to 3, it will spawn 2 more wolves over the course of 40 seconds.
Gandoff
Posts: 20
Joined: Mon Jan 01, 2018 7:13 pm

Re: Demo Spawner Missing

Post by Gandoff »

Ok, here is what I have done:

1) Started Unity 2017.3.0f3
2) created a new project QM_Demo as a 2D project
3) Imported Quest Machine 1.0.1 from the Asset store (imported completely with all defaults)
4) In the inspector, I selected the villager
5) I added "Harvest Carrots" from Plugins/PixelCrushers/Quest Machine/Quests/Handwritten to the QuestGiver's Quests/Handwritten
6) Without saving, I started the project playing
7) I MOved the player to the farmer and right clicked on the farmer once I had the notification that he had quests
8) I accepted the Harvest Carrots quests

At no time either before accepting the quest or after did I see any spawns (carrots, wolfs, orcs, or rabbits)
Gandoff
Posts: 20
Joined: Mon Jan 01, 2018 7:13 pm

Re: Demo Spawner Missing

Post by Gandoff »

3A) I should have mentioned that I opened the Quick Start scene from Plugins/PixelCrushers/Quest Machine/Demo/Quick Start

Please note: The path in my previous path should have been Plugins/PixelCrushers/Quest Machine/Demo/Quests/Handwritten
Gandoff
Posts: 20
Joined: Mon Jan 01, 2018 7:13 pm

Re: Demo Spawner Missing

Post by Gandoff »

I do get these warnings when I import QM.

Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Editor/Quest Editors/Quest Editor Window/QuestEditorWindow.cs(140,31): warning CS0618: `UnityEditor.EditorApplication.playmodeStateChanged' is obsolete: `Use EditorApplication.playModeStateChanged and/or EditorApplication.pauseStateChanged'

Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Editor/Quest Editors/Quest Editor Window/QuestEditorWindow.cs(152,31): warning CS0618: `UnityEditor.EditorApplication.playmodeStateChanged' is obsolete: `Use EditorApplication.playModeStateChanged and/or EditorApplication.pauseStateChanged'

After configuring as stated above, I received this error:

Some input settings listed on the Input Device Manager component are missing from Unity's Input Manager. To automatically add them, inspect the Input Device Manager component and click the 'Add Input Definitions' button at the bottom.
Input Axis JoystickAxis1 is not setup.
To change the input settings use: Edit -> Project Settings -> Input
UnityEngine.Debug:LogError(Object, Object)
PixelCrushers.InputDeviceManager:IsUsingJoystick() (at Assets/Plugins/Pixel Crushers/Common/Scripts/UI/InputDeviceManager.cs:206)
PixelCrushers.InputDeviceManager:Update() (at Assets/Plugins/Pixel Crushers/Common/Scripts/UI/InputDeviceManager.cs:166)

I pressed the 'Add Input Definitions' button as requested and reran the game. I then received no errors at startup.
But I still have no spawns of any kind.
User avatar
Tony Li
Posts: 20756
Joined: Thu Jul 18, 2013 1:27 pm

Re: Demo Spawner Missing

Post by Tony Li »

Hi,

To make the Quick Start scene simpler, I deactivated several GameObjects, including the spawners. Try activating Level > Spawners. The spawners are set to Auto Start, so you don't need to accept any quests. Just play, and watch things appear (hopefully!).
Gandoff wrote: Tue Jan 02, 2018 6:58 pmI do get these warnings when I import QM.

Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Editor/Quest Editors/Quest Editor Window/QuestEditorWindow.cs(140,31): warning CS0618: `UnityEditor.EditorApplication.playmodeStateChanged' is obsolete: `Use EditorApplication.playModeStateChanged and/or EditorApplication.pauseStateChanged'

Assets/Plugins/Pixel Crushers/Quest Machine/Scripts/Editor/Quest Editors/Quest Editor Window/QuestEditorWindow.cs(152,31): warning CS0618: `UnityEditor.EditorApplication.playmodeStateChanged' is obsolete: `Use EditorApplication.playModeStateChanged and/or EditorApplication.pauseStateChanged'
It's an ignorable warning due to an API change in Unity 2017.3. It's already fixed in the upcoming version 1.0.2, which is scheduled for release on Monday (although it will take a few business days to appear on the Asset Store).
Gandoff wrote: Tue Jan 02, 2018 6:58 pmAfter configuring as stated above, I received this error:

Some input settings listed on the Input Device Manager component are missing from Unity's Input Manager. To automatically add them, inspect the Input Device Manager component and click the 'Add Input Definitions' button at the bottom.
Input Axis JoystickAxis1 is not setup.
To change the input settings use: Edit -> Project Settings -> Input
UnityEngine.Debug:LogError(Object, Object)
PixelCrushers.InputDeviceManager:IsUsingJoystick() (at Assets/Plugins/Pixel Crushers/Common/Scripts/UI/InputDeviceManager.cs:206)
PixelCrushers.InputDeviceManager:Update() (at Assets/Plugins/Pixel Crushers/Common/Scripts/UI/InputDeviceManager.cs:166)

I pressed the 'Add Input Definitions' button as requested and reran the game. I then received no errors at startup.
Yup, that's as intended. That button sets up your project's input definitions to work with Quest Machine's Input Device Manager. Since you clicked 'Add Input Definitions', it should be all good now.
Gandoff
Posts: 20
Joined: Mon Jan 01, 2018 7:13 pm

Re: Demo Spawner Missing

Post by Gandoff »

Yes, that fixed it!
Ok, I guess I just missed that one, sorry.
Thank you very much for clearing that up.

I assume Captain Molly and Sir Goodwin are the same way as I do not see them in the scene.
Should their game objects exists with the procedural quests etc.?
Or is there a tutorial to show us how to set them up?

Thanks in advanced for your patience as I am new to both Quest Machine and Unity,
Gandoff
User avatar
Tony Li
Posts: 20756
Joined: Thu Jul 18, 2013 1:27 pm

Re: Demo Spawner Missing

Post by Tony Li »

Hi,

No worries; it's something I forgot to mention about the Quick Start scene.

I fully removed Captain Molly and Sir Goodwin from the Quick Start scene, so it's a little more complicated to add them back. With version 1.0.2, I'm releasing a video tutorial specifically on procedural quest generation. In the meantime, here's a summary of the steps:

1. Add the prefab Plugins / Pixel Crushers / Quest Machine / Demo / Prefabs / Creatures / Knight to the scene. This will add Sir Goodwin. You may need to adjust his position. X=12, Y=6 are good values.

Image


2. Inspect the Knight in your scene. On the Targetable component, assign the scene's Player GameObject to the On Interact() event:

Image

This tells the NPC who to start the dialogue with (i.e., the player).


3. On the Quest Generator Entity component, there's a foldout called Domains. Expand this. You should see two unassigned elements (Element 0 and Element 1). In the Hierarchy view, expand Level > Domains. Drag Forest Domain into Element 0 and Field Domain into Element 1:

Image

This tells Sir Goodwin what domains to monitor. He'll be aware of entities that are in the Forest and the Field.

Also select the blank element in the Dialogue For Rewards Section, then click the "+". This is a mistake in the prefab that's fixed in version 1.0.2.

Now when you play the scene Sir Goodwin should generate a quest. If you've activated the Orc Spawner, he'll generate a quest about orcs, which he dislikes most out of all entity types. If you've activated the Wolf Spawner but not the Orc Spawner, he'll generate a quest about wolves. He doesn't care enough about carrots or rabbits to generate quests about them.
Post Reply