Is there a way to activate a region (by walking on it) while the character is in a blocking function?
Example : EGO does something which causes a MoveCharacterBlocking(); function to start. He walks across a region which should cause a NPC to appear. If he walks across it normally, (ie the player clicks the walk icon to move the character) it works fine. If the blocking function is used, it doesn't activate.
Blocking Functions and Regions in AGS
Moderators: adeyke, VampD3, eriqchang, Angelus3K
Technically yes. In repeatedly_execute_always, check which region the character is over. HOWEVER you cannot abort the blocking function like that, so instead of a blocking walk, you'd be better off doing something like
Code: Select all
MoveCharacter (someone, someposition);
while (character[someone].walking) {
Wait (1);
if (GetRegionAt (character[someone].x, character[someone].y) == 4) {
// explosion occurs
break;
}
}