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


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Set Entity Active Problem
bigfoot Offline
Member

Posts: 58
Threads: 12
Joined: Dec 2010
Reputation: 0
#7
RE: Set Entity Active Problem

(07-12-2011, 06:01 PM)Kyle Wrote:
(07-12-2011, 05:43 PM)bigfoot Wrote: Oh it doesn't matter, then the chairs alone will circle around you :p just as creepy, maybe even creepier. anywho uuhm how can I make the interact callback actually work? cause I don't have any errors but the chairs don't activate.

An interact callback looks like this, for example:

void OnStart()
{
     SetEntityPlayerInteractCallback("Object", "Func01", true);
}
void Func01(string &in asEntity)
{
     //Whatever you want to happen here.
}

You can use an interact callback with any entity or script area, but not a static object. The hook is that you could put a script area a little on the outside of the static object so it would be as if you interacted with the static object instead of the script area.

In your script, you forgot the parameters where your function is, as it should match (somewhat) with the callback you make.

void cabinet_nice_1_callback(string &in asEntity)

It isn't the callback that makes the function. It is the function already existing which gives the callback a reason to call the function.

In the function, you can refer to something as "asEntity" which makes the game know that you are talking about "cabinet_nice_1".

Ah, I forgot the string &in asEntity
YUSH IT WORKS WOOHOO, THANK YOU SOOO MUCH.
(This post was last modified: 07-12-2011, 06:06 PM by bigfoot.)
07-12-2011, 06:05 PM
Find


Messages In This Thread
Set Entity Active Problem - by bigfoot - 07-12-2011, 04:54 PM
RE: Set Entity Active Problem - by Tanshaydar - 07-12-2011, 05:00 PM
RE: Set Entity Active Problem - by bigfoot - 07-12-2011, 05:26 PM
RE: Set Entity Active Problem - by Kyle - 07-12-2011, 05:40 PM
RE: Set Entity Active Problem - by Streetboat - 07-12-2011, 07:31 PM
RE: Set Entity Active Problem - by Kyle - 07-12-2011, 07:52 PM
RE: Set Entity Active Problem - by bigfoot - 07-12-2011, 05:43 PM
RE: Set Entity Active Problem - by Kyle - 07-12-2011, 06:01 PM
RE: Set Entity Active Problem - by bigfoot - 07-12-2011, 06:05 PM



Users browsing this thread: 1 Guest(s)