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
Script Help Script area does not activate
Author Message
Peldan Offline
Junior Member

Posts: 16
Threads: 3
Joined: Mar 2012
Reputation: 0
#21
RE: Script area does not activate

(03-10-2012, 02:34 PM)flamez3 Wrote: delete second.map_cache
Done it several times. Trying it again..

Still nothing! Scripts do work on my first map, though.


EDIT: Okay, seems like the map script itself doesn't even work, at all. SetMessage and AddDebugMessage in OnStart doesn't work either.

EDIT2: Alright, renamed the custom story name and the map and script names aswell. My old script somehow REPLACED the new one, out of nowhere. My custom stories are really glitchy..

Oh well, now I have the old script, and the Justine monster is appearing. Here's the script now:
PHP Code: (Select All)
void OnStart()
{
    
AddEntityCollideCallback("Player""ScriptArea_Malo""SpawnMalo"true1);
    
AddEntityCollideCallback("malo""MaloDeSpawn""DeSpawnMalo"true1);
}

void SpawnMalo(string &in asParentstring &in asChildint alState)
{
    
PlaySoundAtEntity("""notice_long.snt""malo"0false);
    
PlayMusic("search_suitor.ogg"true0.8f00true);
    
SetMessage("SetMessage""SM_Malo"0);
    
SetEntityActive("malo"true);
    
SetSwingDoorClosed("sewer_arched_1"truetrue);
    
AddEnemyPatrolNode("malo""PathNodeArea_1"0.1f"");
    
AddEnemyPatrolNode("malo""PathNodeArea_2"0.1f"");
    
AddEnemyPatrolNode("malo""PathNodeArea_3"0.1f"");
    
AddEnemyPatrolNode("malo""PathNodeArea_4"0.1f"");
    
AddEnemyPatrolNode("malo""PathNodeArea_5"0.1f"");
    
AddEnemyPatrolNode("malo""PathNodeArea_6"0.1f"");
    
AddEnemyPatrolNode("malo""PathNodeArea_7"0.1f"");
    
AddEnemyPatrolNode("malo""PathNodeArea_8"0.1f"");
}

void DeSpawnMalo(string &in asParentstring &in asChildint alState)
{
    
SetEntityActive("malo"true);
    
StopMusic(1.0f0);
    
SetMessage("SetMessage""SM_MaloGone"0);
}

void OnEnter()
{

}

void OnLeave()
{


(This post was last modified: 03-10-2012, 02:48 PM by Peldan.)
03-10-2012, 02:34 PM
Find Reply
flamez3 Offline
Posting Freak

Posts: 1,281
Threads: 48
Joined: Apr 2011
Reputation: 57
#22
RE: Script area does not activate

Do you need any more help?

03-10-2012, 02:56 PM
Find Reply
Peldan Offline
Junior Member

Posts: 16
Threads: 3
Joined: Mar 2012
Reputation: 0
#23
RE: Script area does not activate

Well, somehow the old map gets loaded by the level door on map one, even though I changed the map that should be loaded, and all that. I guess I will reinstall or try on another computer, bye for now and thanks for the help! Big Grin
03-10-2012, 03:01 PM
Find Reply




Users browsing this thread: 1 Guest(s)