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
SOLVED: Script based on the Orb Pillars not working...
39Games Offline
Junior Member

Posts: 48
Threads: 14
Joined: Jan 2013
Reputation: 0
#4
RE: Script based on the Orb Pillars not working...

Ok so I tried your code and it didnt seem to work...
ERR: "pillarsKnocked" is not declared.
(04-29-2016, 07:37 AM)Mudbill Wrote:
PHP Code: (Select All)
int pillarsKnocked 0;

void OnStart() 
{
    
//Creates 4 callbacks for Pillar_1 & Area_1 up till #4.
    
for(int i 1<= 4i++) AddEntityCollideCallback("Pillar_"+i"AreaPillar_"+i"PillarExit"true, -1);
}

void PillarExit(string &in asParentstring &in asChildint alState) {
    if(
alState != -1) return; //This isn't exactly necessary since it's only called upon exit.

    
pillarsKnocked++; //This adds 1 to the variable, counting total pillars knocked.

    
if(pillarsKnocked 4) return; //Unless knocked pillars have reached 4, no further code is ran.

    //Run your code here that you want to be called upon knocking all 4 pillars over.


Ok so I tried it again on a fresh map, and it didnt crash this time but the entity call back didnt seem to work...

(This post was last modified: 04-30-2016, 09:38 AM by 39Games.)
04-30-2016, 05:42 AM
Find


Messages In This Thread
RE: Script based on the Orb Pillars not working... - by 39Games - 04-30-2016, 05:42 AM



Users browsing this thread: 1 Guest(s)