Please login or register.

Login with username, password and session length
Advanced search  

News:

This forum provides RSS feed. To query recent posts use this url. More...


Author Topic: Pause during actions  (Read 3703 times)

0 Members and 1 Guest are viewing this topic.

The Flayer

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 3
    • View Profile
Pause during actions
« on: October 21, 2017, 11:54:57 PM »

Hello, I am learning to use WE and I have a question.
It is possible to pause the actions of a script for a definite amount of time?
I tryed to use the "sleep" function but it did not work, the script is not execute at all.

This is an example of what I need:


on "LookAt"
{
  actor.GoToObject(this);
  actor.Direction = DI_DOWN;
  actor.Talk("It's wonderfull.");
  sleep(10);  ?????
  actor.Talk("I'll take it.");
  }


Thanks for help
Logged

NAItReIN

  • Occasional poster
  • **
  • Karma: 1
  • Offline Offline
  • Posts: 69
    • View Profile
Re: Pause during actions
« Reply #1 on: October 22, 2017, 07:53:47 AM »

Hi,
your script should work but be sure you have to call Sleep() - first letter is upper case - function instead of sleep() because this function od not defined in Wintermute Engine.
Logged

The Flayer

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 3
    • View Profile
Re: Pause during actions
« Reply #2 on: October 22, 2017, 10:27:18 AM »

Thank you a lot!
It works now.
I have to practise more with the script! :)
Logged
 

Page created in 0.018 seconds with 20 queries.