[Solved] My dancer stop dancing when character talk to npc

Started by actaria, Thu 13/04/2023 22:06:30

Previous topic - Next topic

actaria

Hello,

I hope everyone is doing well.

I need your help because i am stuck on that one.

I have a bar with a pianist and a dancer:



I use this code to make the dancer move everywhere on stage

 
Code: ags
function room_AfterFadeIn()
{
SetTimer(15,250);
}


 
Code: ags
function room_RepExec()
{
if (IsTimerExpired(15)) {
cdanseuse.Walk(Random(999), Random(999), eNoBlock, eWalkableAreas);
SetTimer(15,80 + Random(80));
}

It works well the problem i'd like to solve is that the character needs to talk to a NPC and when the dancer reach the end of timer she stops once the NPC is talking or opening a dialog.

How can i make the dancer to keep dancing even when the player is talking to someone ?

Thanks a lot for your precious help.


actaria

Thanks a lot for the answer i will have a look right now  ;-D

EDIT:
Perfectly working thank you didn"t know about the "always" thing

Crimson Wizard

Quote from: actaria on Thu 13/04/2023 22:34:37Perfectly working thank you didn"t know about the "always" thing

There's some information about these, and explains the difference:
https://adventuregamestudio.github.io/ags-manual/RepExec.html

actaria


SMF spam blocked by CleanTalk