Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 4 Vote(s) - 3 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how to make floor break when u go to a certain area
Romulator Offline
Not Tech Support ;-)

Posts: 3,628
Threads: 63
Joined: Jan 2013
Reputation: 195
#55
RE: how to make floor break when u go to a certain area

1) Follow the bookshelf part of this tutorial:
https://wiki.frictionalgames.com/hpl2/tu...=bookshelf

2) Get your pulley book (Entities > Gameplay > book_moveable)

3) Add a Script_Area behind the book at a suitable distance (the book can only go so far) like this:
[Image: b11c1a3ccf.jpg]

4) And try using this code:
PHP Code: (Select All)
void OnStart()
{
AddEntityCollideCallback("<name_of_book>""<name_of_script_area>""open_shelf"1true);
}

void open_shelf(string &in asParentstring &in asChildint alState)
{
SetMoveObjectState("shelf"1.0f);


Discord: Romulator#0001
[Image: 3f6f01a904.png]
(This post was last modified: 07-03-2014, 02:37 AM by Romulator.)
07-03-2014, 02:36 AM
Find


Messages In This Thread
RE: how to make floor break when u go to a certain area - by Romulator - 07-03-2014, 02:36 AM



Users browsing this thread: 1 Guest(s)