Strange problem working on Scripted cutscene event queueing

Get help using Construct 2

Post » Sat Nov 15, 2014 6:47 am

I've been trying to put together a bit of code so that when the player talks to a character, I'll call a "CharacterSpeech" function for each line of dialogue that appears. As in :

CharacterSpeech("Here's the first line of dialogue");
CharacterSpeech("And Here's the Second");

To facilitate this, as well as having a system I can build off of for other cutscene-style animations (making characters walk around, change animations, etc.) I built a rudimentary event queueing system you can see in the image here, relying on having each event added to the queue waiting for a signal generated by the completion of the previous queued event.


However, while the queueing seems to work fine, it seems to be doing something odd to the parameter passed to the CharacterSpeech function, namely the text to display. The function parameter (expliticly, the value of "Function.Param(0)" in the code) becomes 0 no matter what is actually passed to it, text, number, whatever, and I have no idea why.

Now I've fiddled with this a bit, Setting the text isn't the problem, nor the queue position counters or anything. But Strangely, if I disable the first "Wait for Signal" in the function, then while not exactly working, the parameter is passed correctly. It only seems to be while waiting for the first signal that it's affected, and I have no idea why this should be.

Can anyone help with this?
Posts: 13
Reputation: 1,823

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 14 guests