// The following datablock definition is an example of what you will need to create for each trigger you place.
// The name of this trigger datablock appears in the parenthesis below ("TestTriggerDatablock", in this case). 

datablock TriggerData(TestTriggerDatablock)
{
   // The period is value is used to control how often the console
   // onTriggerTick callback is called while there are any objects
   // in the trigger.  The default value is 100 MS.
   tickPeriodMS = 100;
};


// Next you will need to create this trigger datablock's onEnterTrigger function. You can just copy this function below 
// and change its name to reflect your new datablock name.

function TestTriggerDatablock::onEnterTrigger(%this,%trigger,%obj)
{
   // This script is called whenever an object enters the %trigger
   // The object entering the trigger (usually the player, but can also be AI players) is passed as %obj.  
   
   if ( isTriggerReady( %trigger, %obj )) // this ensures the VO is only heard the first time the trigger is entered
   {
      $VMPlayer.PlaySong("~/data/sound/Level1/Burke/brian_burke_line1.ogg");
   }
}


// If you want a trigger to have another behavior (like stopping a VO) when a player leaves it, you will need to create
// an "onLeaveTrigger" function like the one below. 

function TestTriggerDatablock::onLeaveTrigger(%this,%trigger,%obj)
{
   // This script is called whenever an object leaves the %trigger
   // area, the object is passed as %obj.  
   
   // you can use this to stop a particular VO if you want it to end when the player leaves the trigger
   $VMPlayer.Stop();
   
   // if you don't want this "stop-on-exit" behavior, you can either use the "//" marks to comment out the stop command
   // $VMPlayer.Stop();
   
   // ...or simply do not create the onLeaveTrigger function for this particular trigger -- it is not required
}


// So, in summary, you create and name a new datablock, then you create an onEnterTrigger script for that datablock.
// The onLeaveTrigger is optional.

// Now, to connect these scripts with the trigger you created in your level, find that trigger in the .mis file 
// (or you can find it using the mission editor if you prefer to work visually, but using a text-editor like Torsion on the
// .mis file will probably be faster if you named the triggers when you placed them). The trigger definition in the .mis file
// looks like this:

/*
   new Trigger(test_trigger) {
      canSaveDynamicFields = "1";
      position = "58.5009 -442.659 -0.1";
      rotation = "1 0 0 0";
      scale = "10 10 5";
      dataBlock = "defaultTrigger";
      polyhedron = "0.0000000 0.0000000 0.0000000 1.0000000 0.0000000 0.0000000 0.0000000 -1.0000000 0.0000000 0.0000000 0.0000000 1.0000000";
   };
*/

// Just change the "dataBlock =" part to reflect the name of the new trigger datablock you created above, ie:

//    datablock = "TestTriggerDatablock";

// and now your onEnterTrigger script will run when you move the player into that trigger. Presto!


datablock TriggerData(journalistIntroVOLevelTwo_Datablock)
{
   
   tickPeriodMS = 100;
};

function journalistIntroVOLevelTwo_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/CutSceneVO/madhuri_journ_lvl2_intro.ogg");
      %obj.schedule(38000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
   }

}

datablock TriggerData(FactoryGateInside_Datablock)
{
   
   tickPeriodMS = 100;
};

function FactoryGateInside_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
}
}

datablock TriggerData(EmployeeEntrance_Datablock)
{
   
   tickPeriodMS = 100;
};

function EmployeeEntrance_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Guard1/jarah_guard1_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/guard1_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(7000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
   %obj.schedule(7000, setTransform,KickOutGarage.getTransform() );  
   IPhone_AddPoints(IPhone, $IPHONE_KICKOUT_POINTS);

}
}

datablock TriggerData(MainBuildingDoor_Datablock)
{
   
   tickPeriodMS = 100;
};

function MainBuildingDoor_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Receptionist1/suyin_receptionist1_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/receptionist1_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(9000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
      Receptionist.schedule(9000,followPath, Receptionist_walk);
      
      IPhone_ShowPictureChance(%obj.iphone, 9000, $IPHONE_PICTURE_FOUR, %obj, %trigger);   
      %obj.LockPlayerToDirection(%trigger.rotation);   
      %obj.schedule(9000, unlockPlayerToDirection);      
      
}
}

datablock TriggerData(VonKnoxConferenceRoom_Datablock)
{
   
   tickPeriodMS = 100;
};

function VonKnoxConferenceRoom_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/DrVonKnox/itay_vonknox_line2.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/vonknox_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(21000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
            IPhone_FlashMicIcon(IPhone);
      schedule(21000, 0, IPhone_StopMicFlash, IPhone); 
      schedule(21000, 0, IPhone_AddPoints, IPhone, $IPHONE_MIC_POINTS);   
      VonKnox.schedule(21000,followPath, VonKnox_walk);
      ReceptionistShape.schedule(21000,pushForward);
      
}
}

datablock TriggerData(LeavingMainBuilding_Datablock)
{
   
   tickPeriodMS = 100;
};

function LeavingMainBuilding_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Receptionist1/suyin_receptionist1_line2.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/receptionist1_lvl2_line2.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(6000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
}
}

datablock TriggerData(OnWay2GeodesicDome_Datablock)
{
   
   tickPeriodMS = 100;
};

function OnWay2GeodesicDome_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line2.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line2.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
}
}

datablock TriggerData(VonKnoxLabDoor_Datablock)
{
   
   tickPeriodMS = 100;
};

function VonKnoxLabDoor_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line3.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line3.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(5000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
   IPhone_AddPoints(IPhone, $IPHONE_KICKOUT_POINTS);

   %obj.schedule(5000, setTransform,KickOutIgloo.getTransform() );  
}
}

datablock TriggerData(UpstairsOfficeDoor_Datablock)
{
   
   tickPeriodMS = 100;
};

function UpstairsOfficeDoor_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/DrFuchs/samara_drfuchs_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/drfuchs_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(28000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
            IPhone_FlashMicIcon(IPhone);
      schedule(28000, 0, IPhone_StopMicFlash, IPhone); 
      schedule(28000, 0, IPhone_AddPoints, IPhone, $IPHONE_MIC_POINTS);         
      
}
}

datablock TriggerData(JournalistOverhearsVM_Datablock)
{
   
   tickPeriodMS = 100;
};

function JournalistOverhearsVM_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line4.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line4.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false );   

}
}

datablock TriggerData(PressPhoneRecording_Datablock)
{
   
   tickPeriodMS = 100;
};

function PressPhoneRecording_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/BlackwellRecording/pam_blackwellrecord_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/blackwellrecording_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 

      %obj.schedule(10000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation);
	
	IPhone_FlashMicIcon(IPhone);
      schedule(10000, 0, IPhone_StopMicFlash, IPhone); 
      schedule(10000, 0, IPhone_AddPoints, IPhone, $IPHONE_MIC_POINTS);  
 

}
}

datablock TriggerData(JournalistCleaningArea_Datablock)
{
   
   tickPeriodMS = 100;
};

function JournalistCleaningArea_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line5.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line5.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 


}
}

datablock TriggerData(CleaningStation_Datablock)
{
   
   tickPeriodMS = 100;
};

function CleaningStation_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line6.ogg");

//SCDPopupTextAlt.setBitmap( "StitchCutDye/data/popupTextGraphics/questionMark_bw.png" );
SCDPopupTextAlt.schedule( 7500, setVisible, true );
SCDPopupTextAlt.schedule( 7500, setBitmap, "StitchCutDye/data/popupTextGraphics/assistLetter_color.jpg" ); 
SCDPopupTextAlt.schedule( 12000, setVisible, false ); 

      IPhone_FlashClueIcon(IPhone);
      schedule(7500, 0, IPhone_StopClueFlash, IPhone); 
      schedule(7500, 0, IPhone_AddPoints, IPhone, $IPHONE_CLUE_POINTS);       

      %obj.schedule(12000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
}
}

datablock TriggerData(WorkerOneArea_Datablock)
{
   
   tickPeriodMS = 100;
};

function WorkerOneArea_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/WorkerOne/simone_worker1_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/worker1_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(90000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
      // Initialize a picture opporunity
      IPhone_ShowPictureChance(%obj.iphone, 75000, $IPHONE_PICTURE_ONE, %obj, %trigger);   
      %obj.LockPlayerToDirection(%trigger.rotation);   
      %obj.schedule(75000, unlockPlayerToDirection);
}
}

datablock TriggerData(WorkerTwoArea_Datablock)
{
   
   tickPeriodMS = 100;
};

function WorkerTwoArea_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/WorkerTwo/gosia_worker2_line1.ogg");

//SCDPopupTextAlt2.setBitmap( "StitchCutDye/data/popupTextGraphics/questionMark_bw.png" );
SCDPopupTextAlt2.schedule( 12000, setVisible, true );
SCDPopupTextAlt2.schedule( 12000, setBitmap, "StitchCutDye/data/popupTextGraphics/CODchart.png" ); 
SCDPopupTextAlt2.schedule( 25000, setVisible, false ); 

      IPhone_FlashClueIcon(IPhone);
      schedule(12000, 0, IPhone_StopClueFlash, IPhone); 
      schedule(12000, 0, IPhone_AddPoints, IPhone, $IPHONE_CLUE_POINTS);     

      %obj.schedule(90000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
}
}

datablock TriggerData(WorkerThreeArea_Datablock)
{
   
   tickPeriodMS = 100;
};

function WorkerThreeArea_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/WorkerThree/daupo_worker3_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/worker3_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(80000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
}
}

datablock TriggerData(ViewFemaleGhostStairs_Datablock)
{
   
   tickPeriodMS = 100;
};

function ViewFemaleGhostStairs_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/ghostFemale/rosalyn_femaleghost_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/femaleghost_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(40000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
      // Initialize a picture opporunity
      IPhone_ShowPictureChance(%obj.iphone, 35000, $IPHONE_PICTURE_TWO, %obj, %trigger);   
      %obj.LockPlayerToDirection(%trigger.rotation);  
      %obj.schedule(35000, unlockPlayerToDirection);    
}
}

datablock TriggerData(JournalistResponseFemaleGhost_Datablock)
{
   
   tickPeriodMS = 100;
};

function JournalistResponseFemaleGhost_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line8.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line8.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 



      

}
}

datablock TriggerData(JournalistHearsGhostMix_Datablock)
{
   
   tickPeriodMS = 100;
};

function JournalistHearsGhostMix_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/ghostMix/rosalyn_ghostmix_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/ghostMix_beware.png" );
SCDPopupText.setVisible( true );

SCDPopupText.schedule( 5000, setBitmap, "StitchCutDye/data/popupTextGraphics/ghostMix_spawning.png" ); 
SCDPopupText.schedule( 10000, setBitmap, "StitchCutDye/data/popupTextGraphics/ghostMix_pay.png" );

SCDPopupText.schedule( 15000, setVisible, false );  

      %obj.schedule(18000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
}
}

datablock TriggerData(WorkerFourArea_Datablock)
{
   
   tickPeriodMS = 100;
};

function WorkerFourArea_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/WorkerFour/daupo_worker4_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/worker4_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 

      %obj.schedule(20000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
}
}

datablock TriggerData(LucsGhostAppearsPool_Datablock)
{
   
   tickPeriodMS = 100;
};

function LucsGhostAppearsPool_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/LucsGhost/david_lucsghost_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/lucsGhost_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
            IPhone_FlashMicIcon(IPhone);
      schedule(55000, 0, IPhone_StopMicFlash, IPhone); 
      schedule(55000, 0, IPhone_AddPoints, IPhone, $IPHONE_MIC_POINTS);  
      %obj.schedule(55000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
}
}

datablock TriggerData(JournalistResponseLucsGhost_Datablock)
{
   
   tickPeriodMS = 100;
};

function JournalistResponseLucsGhost_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line9.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line9.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 


      %obj.schedule(40000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 

   %obj.schedule(40000, setTransform,"" @ vonknoxVerflucht.position @ vonknoxVerflucht.rotation );  

}
}

datablock TriggerData(WorkerFiveArea_Datablock)
{
   
   tickPeriodMS = 100;
};

function WorkerFiveArea_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/WorkerFive/samara_worker5_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/worker5_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 

      %obj.schedule(32000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
}
}

datablock TriggerData(JournalistInsideSkinBin_Datablock)
{
   
   tickPeriodMS = 100;
};

function JournalistInsideSkinBin_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line10.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line10.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 


}
}

datablock TriggerData(InsideShippingArea_Datablock)
{
   
   tickPeriodMS = 100;
};

function InsideShippingArea_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Driver1/fabio_driver1_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/driver1_lvl2_line1.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 

      %obj.schedule(21000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation);
	
	IPhone_FlashMicIcon(IPhone);
      schedule(21000, 0, IPhone_StopMicFlash, IPhone); 
      schedule(21000, 0, IPhone_AddPoints, IPhone, $IPHONE_MIC_POINTS); 
}
}

datablock TriggerData(SupervisorsRoom_Datablock)
{
   
   tickPeriodMS = 100;
};

function SupervisorsRoom_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/DrVonKnox/itay_vonknox_line1.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/vonknox_lvl2_line2.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
      %obj.schedule(6000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
      Mordecai.schedule(5000,followPath, Mordecai_walk);      
      
}
}

datablock TriggerData(SneakingOutSideEntrance_Datablock)
{
   
   tickPeriodMS = 100;
};

function SneakingOutSideEntrance_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line14.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line12.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
}
}

datablock TriggerData(RoundingCornerTowardsLab_Datablock)
{
   
   tickPeriodMS = 100;
};

function RoundingCornerTowardsLab_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line12.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line13.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
}
}

datablock TriggerData(FinalSceneLab_Datablock)
{
   
   tickPeriodMS = 100;
};

function FinalSceneLab_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/DrVonKnox/itay_vonknox_line3.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/vonknox_lvl2_line3.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 

      %obj.schedule(30000, unlockPlayerToDirection);
      %obj.LockPlayerToDirection(%trigger.rotation); 
      
      IPhone_ShowPictureChance(%obj.iphone, 30000, $IPHONE_PICTURE_THREE, %obj, %trigger);   
      %obj.LockPlayerToDirection(%trigger.rotation);    
      %obj.schedule(30000, unlockPlayerToDirection);
}
}

datablock TriggerData(JournalistFindsSkinCooler_Datablock)
{
   
   tickPeriodMS = 100;
};

function JournalistFindsSkinCooler_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line13.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line14.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
}
}

datablock TriggerData(PonderingBySkinBin_Datablock)
{
   
   tickPeriodMS = 100;
};

function PonderingBySkinBin_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line7.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line7.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
}
}

datablock TriggerData(JournalistOverhearsDrivers_Datablock)
{
   
   tickPeriodMS = 100;
};

function JournalistOverhearsDrivers_Datablock::onEnterTrigger(%this,%trigger,%obj)
{

if ( isTriggerReady( %trigger, %obj )) 
   {
      $VMPlayer.PlaySong("~/data/sound/Level2/Journalist/madhuri_journ_lvl2_line11.ogg");

SCDPopupText.setBitmap( "StitchCutDye/data/popupTextGraphics/journalist_lvl2_line11.png" );
SCDPopupText.setVisible( true );
SCDPopupText.schedule( 5000, setVisible, false ); 
}
}
