Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4765


Ignore:
Timestamp:
Apr 6, 2007, 7:14:55 PM (18 years ago)
Author:
snellen
Message:

adapted all the scripts to the new trunk

Location:
data/trunk/scripts
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • data/trunk/scripts/cutscene/cutscene.lua

    r4760 r4765  
    11-- Main trigger
    2 trigger = ScriptTrigger()                     -- Create the trigger
     2trigger = TickTrigger()                     -- Create the trigger
    33trigger:setScript("cutscene.lua")             -- Tell the trigger which script to call
    44trigger:setFunction("tick")                   -- Tell the trigger which scriptfunction to call
    5 trigger:setActiveOnCreation(true)     
     5
    66
    77
    88-- Cameraswitchzero
    9 triggerZero = ScriptTrigger()
     9triggerZero = SpaceTrigger()
    1010triggerZero:setScript("cutscene.lua")
    1111triggerZero:setFunction("switchCamToBomber")
     
    1717
    1818-- Cameraswitchone
    19 triggerOne = ScriptTrigger()
     19triggerOne = SpaceTrigger()
    2020triggerOne:setScript("cutscene.lua")
    2121triggerOne:setFunction("switchCamTargetToEarth")
     
    2727
    2828-- Cameraswitchtwo
    29 triggerTwo = ScriptTrigger()
     29triggerTwo = SpaceTrigger()
    3030triggerTwo:setScript("cutscene.lua")
    3131triggerTwo:setFunction("switchCamToSpaceship")
     
    3636
    3737-- Cameraswitchthree
    38 triggerThree = ScriptTrigger()
     38triggerThree = SpaceTrigger()
    3939triggerThree:setScript("cutscene.lua")
    4040triggerThree:setFunction("switchCamToStation")
     
    4646
    4747-- startScenery
    48 triggerFour = ScriptTrigger()
     48triggerFour = SpaceTrigger()
    4949triggerFour:setScript("cutscene.lua")
    5050triggerFour:setFunction("startSceneryOne")
     
    5353triggerFour:setRadius(5)
    5454--triggerFour:setDebugDraw(true) 
     55
     56-- Scroller
     57triggerScr = TimeTrigger()                 
     58triggerScr:setScript("cutscene.lua")             
     59triggerScr:setFunction("startScrolling")
     60triggerScr:setDelay(10)
    5561
    5662
     
    104110end
    105111
    106 
    107112-- Start
    108113function startSceneryOne(timestep)
     
    158163fighterThree:pause(true)
    159164bomberThree:pause(true)
    160 bomberFour:pause(false)
    161 
    162 return true
    163 
    164 end
    165 
     165bomberFour:pause(true)
     166
     167return true
     168
     169end
     170
     171-- Start the scrolling screen
     172function startScrolling(timestep)
     173scrollingScreen:start()
     174return true
     175end
    166176
    167177-- THE tick function
     
    169179function tick(timestep)
    170180time = time + timestep
     181triggerScr:start()
    171182
    172183if not sceneryOneStopped then
     
    204215end
    205216
    206 if time > 10 then
    207    scrollingScreen:start()
    208 end
    209 
    210 
    211217if time > 6 and stationReached then
    212218gameWorld:setNextStoryName( "Space Station 1" )
  • data/trunk/scripts/spacestation/spaceship_hangar.lua

    r4671 r4765  
    11 -- Create the trigger
    2 trigger = ScriptTrigger()
     2trigger = TickTrigger()
    33trigger:setName("maintrigger")
    44trigger:setScript("spaceship_hangar.lua")
    55trigger:setFunction("tick")
    6 trigger:setActiveOnCreation(true)
     6
    77 
    8 triggerZero = ScriptTrigger()
     8triggerZero = SpaceTrigger()
    99triggerZero:setScript("spaceship_hangar.lua")
    1010triggerZero:setFunction("startQuestThree")
     
    1616
    1717
    18 triggerOne = ScriptTrigger()
     18triggerOne = SpaceTrigger()
    1919triggerOne:setScript("spaceship_hangar.lua")
    2020triggerOne:setFunction("startQuestTwo")
  • data/trunk/scripts/spacestation/spaceship_tower.lua

    r4671 r4765  
    11 -- Create the trigger
    2 trigger = ScriptTrigger()
     2trigger = TickTrigger()
    33trigger:setName("maintrigger")
    44trigger:setScript("spaceship_tower.lua")
    55trigger:setFunction("tick")
    6 trigger:setActiveOnCreation(true)
    7 
    8 triggerOne = ScriptTrigger()
     6
     7triggerOne = SpaceTrigger()
    98triggerOne:setScript("spaceship_tower.lua")
    109triggerOne:setFunction("startSecondQuest")
     
    1413--triggerOne:setDebugDraw(true)
    1514
    16 triggerTwo = ScriptTrigger()
     15triggerTwo = SpaceTrigger()
    1716triggerTwo:setScript("spaceship_tower.lua")
    1817triggerTwo:setFunction("startThirdQuest")
  • data/trunk/scripts/spacestation/switchtohangar.lua

    r4614 r4765  
    11 -- Create the trigger
    2 trigger = ScriptTrigger()
     2trigger = SpaceTrigger()
    33trigger:setScript("switchtohangar.lua")
    44trigger:setFunction("tick")
  • data/trunk/scripts/spacestation/switchtotower.lua

    r4614 r4765  
    11  -- Create the trigger
    2 trigger = ScriptTrigger()
     2trigger = SpaceTrigger()
    33trigger:setScript("switchtotower.lua")
    44trigger:setFunction("tick")
  • data/trunk/scripts/vertical_scroller/vs1.lua

    r4760 r4765  
    4242-- thisscript:addObjectAsName("GameWorld", "Mission 1", "gameWorld")
    4343
    44 triggerInit = ScriptTrigger()
     44triggerInit = TickTrigger()
    4545triggerInit:setScript("vs1.lua")
    4646triggerInit:setFunction("init")
    47 triggerInit:setActiveOnCreation(true)
    4847
    4948-- Create the cutscene trigger
    50 triggerCutscene = ScriptTrigger()
     49triggerCutscene = SpaceTrigger()
    5150triggerCutscene:setScript("vs1.lua")
    5251triggerCutscene:setFunction("startSequence")
     
    5554triggerCutscene:setAbsCoor(2300 , 0 , 0)
    5655triggerCutscene:setDebugDraw(false)
    57 triggerCutscene:setActiveOnCreation(false)
    5856
    5957-- Create another cutscene trigger
    60 triggerCutscene02 = ScriptTrigger()
     58triggerCutscene02 = TickTrigger()
    6159triggerCutscene02:setScript("vs1.lua")
    6260triggerCutscene02:setFunction("switchToOtherPirate")
    63 triggerCutscene02:setActiveOnCreation(true)
    6461
    6562-- Create another cutscene trigger
    66 triggerCutscene03 = ScriptTrigger()
     63triggerCutscene03 = TickTrigger()
    6764triggerCutscene03:setScript("vs1.lua")
    6865triggerCutscene03:setFunction("surviver")
    69 triggerCutscene03:setActiveOnCreation(true)
    7066
    7167-- Create another cutscene trigger
    72 triggerCutscene04 = ScriptTrigger()
     68triggerCutscene04 = TickTrigger()
    7369triggerCutscene04:setScript("vs1.lua")
    7470triggerCutscene04:setFunction("onNoxons")
    75 triggerCutscene04:setActiveOnCreation(true)
    7671
    7772-- Create another cutscene trigger
    78 triggerCutscene05 = ScriptTrigger()
     73triggerCutscene05 = TickTrigger()
    7974triggerCutscene05:setScript("vs1.lua")
    8075triggerCutscene05:setFunction("changeFromNoxon")
    81 triggerCutscene05:setActiveOnCreation(true)
     76
    8277
    8378-- Create another trigger
    84 triggerStop = ScriptTrigger()
     79triggerStop = SpaceTrigger()
    8580triggerStop:setScript("vs1.lua")
    8681triggerStop:setFunction("stopPlayer")
     
    8984triggerStop:setAbsCoor(8000 , 0 , -2000)
    9085triggerStop:setDebugDraw(false)
    91 triggerStop:setActiveOnCreation(false)
    9286
    9387-- Create the cool Ragnar trigger
    94 triggerRagnar = ScriptTrigger()
     88triggerRagnar = SpaceTrigger()
    9589triggerRagnar:setScript("vs1.lua")
    9690triggerRagnar:setFunction("startRagnar")
     
    9993triggerRagnar:setAbsCoor(3600 , 0 , -15)
    10094triggerRagnar:setDebugDraw(false)
    101 triggerRagnar:setActiveOnCreation(false)
    10295
    10396-- Create a great AI activater
    104 --triggerAI01 = ScriptTrigger()
     97--triggerAI01 = SpaceTrigger()
    10598--triggerAI01:setScript("vs1.lua")
    10699--triggerAI01:setFunction("activateGroup1")
     
    112105
    113106-- Create another great AI activater
    114 --triggerAI02 = ScriptTrigger()
     107--triggerAI02 = SpaceTrigger()
    115108--triggerAI02:setScript("vs1.lua")
    116109--triggerAI02:setFunction("activateGroup2")
     
    119112--triggerAI02:setAbsCoor(4900, 0, -45)
    120113--triggerAI02:setDebugDraw(false)
    121 --triggerAI02:setActiveOnCreation(false)
    122114
    123115-- Create another great AI activater
    124 --triggerAI03 = ScriptTrigger()
     116--triggerAI03 = SpaceTrigger()
    125117--triggerAI03:setScript("vs1.lua")
    126118--triggerAI03:setFunction("activateGroup3")
     
    129121--triggerAI03:setAbsCoor(5850, 0, -170)
    130122--triggerAI03:setDebugDraw(false)
    131 --triggerAI03:setActiveOnCreation(false)
    132123
    133124-- Create another great AI activater
    134 --triggerAI04 = ScriptTrigger()
     125--triggerAI04 = SpaceTrigger()
    135126--triggerAI04:setScript("vs1.lua")
    136127--triggerAI04:setFunction("startRagnar2")
     
    139130--triggerAI04:setAbsCoor(6500, 0, -350)
    140131--triggerAI04:setDebugDraw(false)
    141 --triggerAI04:setActiveOnCreation(false)
     132
    142133
    143134
Note: See TracChangeset for help on using the changeset viewer.