Forced sleep and Replacement of some object.

Talk about creating Grimrock 1 levels and mods here. Warning: forum contains spoilers!
Post Reply
User avatar
Daght
Posts: 146
Joined: Sun Apr 15, 2012 12:28 pm
Location: Italy

Forced sleep and Replacement of some object.

Post by Daght »

I need help on this code, i'm not a scripter and so I ask you some help.

Code: Select all

function strangeAltar()
if containsItem(strangeAltar, "remains_of_toorum_1")
  then
    --the players fall uncosciuos (forced sleep for 5 secs)
    -- after they wake up the follow new setting must be applied
     --the altar is moved (during the sleep so they see only the changes after they wake up) from 12,0 on level 3, to 13,0 on the same level, with the remains of toorum on it)
      --the pitXX has opened, always during the sleep
  end
end
Thanks to this great community! :mrgreen:
If we do not end the war, the war will end us.
User avatar
Komag
Posts: 3659
Joined: Sat Jul 28, 2012 4:55 pm
Location: Boston, USA

Re: Forced sleep and Replacement of some object.

Post by Komag »

You'll have to mess around with onRest and onWakeUp hooks, with return false at times, to keep them asleep for the 5 secs.
Finished Dungeons - complete mods to play
User avatar
Daght
Posts: 146
Joined: Sun Apr 15, 2012 12:28 pm
Location: Italy

Re: Forced sleep and Replacement of some object.

Post by Daght »

Komag wrote:You'll have to mess around with onRest and onWakeUp hooks, with return false at times, to keep them asleep for the 5 secs.
Thanks, but to me this seem Korean :-/
I got no basic on lua scripting, but many thanks!
If we do not end the war, the war will end us.
Post Reply