Pagina's

Showing posts with label dialog. Show all posts
Showing posts with label dialog. Show all posts

Wednesday, 15 May 2019

Been a while

Alright, quickly before I hit the sack. It's been a while since my last post. Life interfered like it sometimes does. Went away for a weekend with my wife to celebrate we got married a year ago, so that was nice. The neighbours and some famous tv-show both took an evening and then time goes fast, but I'm back, I guess.

What I've been working on and have not finished yet is a system of quests being triggered by a collider. Once the player moves into a trigger area, it should evaluate if that trigger completes a moving quest and then check if it offers a new quest.

Of course this does not work yet, because it seems I have trouble triggering a dialog screen to notify the player the first quest's been completed, AND somehow the new quest starts off "completed". Not sure what that is about, but I'll find that out later this week.

Now off to bed. Tomorrow gamedev time, because I refuse to watch Eurovision and having a lady in the house, that's what is happening here..

Saturday, 4 May 2019

Multipurpose mechanics

The quest system really starts to look like something. A quest can be accepted or rejected and if you don't answer and return later, the NPC wil phrase the question differently. Quests have objectives that can be gathering of an object, defeating an enemy or moving somewhere. Gathering now works. When you get asked for a red ball and you get one, the NPC will understand your success and ask for the thing:



I'm pretty happy with that, because I think I built a dialog system in the progress. Not only are quests starting to be implemented, I also nog have some GUI and mechanics to run a dialog window with one or two buttons to work with. It's always nice to be able to reuse the stuff you build for seemingly unrelated purposes. With hardly any changes, the player can now read a letter on the wall.



Of course I know the letter is not easily readable, so I'll make the panel less transparent and lighter of color, but it pleases me that it works so nicely. Pretty proud of myself.

Before I get ahead of myself. That's it for now.

Thursday, 2 May 2019

A quest in its own right

So I'm implementing quests in my game and since I had been quiet for a while, I'll start with a cheap joke: that's a quest in its own right. It looks like it's taking shape, but it's all looks now.


The first thing I needed to do is have the game understand there's such a thing as a quest, which is now actually nothing more than a class with a couple of strings to contain text. Most of the text is for  dialogs, so I created a dialog handler that can show whatever you want to show in a dedicated dialog window when the rest of the GUI is hidden.

Quests are connected to WorldObjects via a script so that when you interact with that object, it'll view the dialog box. That's kind of all I did tonight. What I'm going to do next is make this a real exchange. There's a couple of lines the NPC can speak, depending on the status of the quest, but that status will never change. For that, I need to have the player actually get the quest. Getting it will change the status. 

Next, I want to add mechanics to the quest so that it has objectives. A delivery quest, like this one, needs to have information on what the NPC wants to have delivered. In this case, the red ball. Furthermore, finding the red ball should change the status of the objective so that when I return to the NPC, it'll be able to decide what to say. A lot of stuff.

And... I need to get the NPC to respect me enough to stop patrolling when we're talking and maybe other NPC's to wait for the dialog to complete before doing their things.