Difference between revisions of "Saving Object Animations' States"

(New page: SWDoorButton: animations: - name: SWdoorbuttonclick autostart: 0 loop: 0 logic: modifiers: - tag: AutoClick cursor: poised...)
 
m (New page moved to Saving Object Animations' States: changed name of page (God knows what the hell I'm doing here))
(No difference)

Revision as of 05:16, 23 July 2008

SWDoorButton:

   animations:
       - name: SWdoorbuttonclick
         autostart: 0
         loop: 0
   logic:
       modifiers:
         - tag: AutoClick
           cursor: poised
           flags:
             - localelement
           activators:
             - type: objectinvolume
               remote: Doorswing
               triggers:
                 - any
           conditions:
             - type: activator
               activators:
                 - type: picking
             - type: objectinbox
               satisfied: true
           actions:
             - type: pythonfile
               ref: $BoolToggle
       actions:
         - type: pythonfile
           tag: BoolToggle
           pythonfile:
               file: xAgeSDLBoolToggle
               parameters:
                 - type: activator
                   ref: logicmod:$AutoClick
                 - type: string
                   value: <SDL Name>
                 - type: skip
                 - type: skip
                 - type: string
                   value: <SDL Name>
         - type: pythonfile
           tag: BoolRespond
           pythonfile:
               file: xAgeSDLBoolRespond
               parameters:
                 - type: string
                   value: <SDL Name>
                 - type: responder
                   ref: :DoorOpen
                 - type: responder
                   ref: :DoorClose
                 - type: bool
                   value: false
                 - type: bool
                   value: true


DoorButtonOneshot:

  logic:
      actions:
         - type: oneshot
           name: DoorButtonOneshot
           oneshot:
               animation: DoorButtonTouch


Door1:

   animations:
       - name: DoorOpen1
         autostart: 0
         loop: 0
   logic:
       actions:
         - type: responder
           name: DoorOpen
           responder:
              states:
               - cmds:
                  - type: oneshotmsg
                    params:
                       receivers:
                        - oneshotmod:DoorButtonOneshot
                       callbacks:
                        - marker: "DoorButtonTouch"
                          receiver: respondermod:DoorOpen
                          user: 0
                    waiton: -1
                  - type: animcmdmsg
                    params:
                       receivers:
                        - 006D:Door1
                       animname: DoorOpen1
                       cmds:
                        - setforewards
                        - continue
                    waiton: 0
                  - type: animcmdmsg
                    params:
                       receivers:
                        - 006D:SWDoorButton
                       animname: SWdoorbuttonclick
                       cmds:
                        - setforewards
                        - continue
                    waiton: 0
                  - type: soundmsg
                    params:
                       receivers:
                        - 0011:emit_swingdoorOpen
                        - 0011:emit_swdoorbutton
                       cmds:
                         - play
                         - setvolume
                       volume: 1
                    waiton: -1
                 nextstate: 1
                 waittocmd: 0
              curstate: 0
              flags:
                - detecttrigger
         - type: responder
           name: DoorClose
           responder:
              states:
               - cmds:
                  - type: oneshotmsg
                    params:
                       receivers:
                        - oneshotmod:DoorButtonOneshot
                       callbacks:
                        - marker: "DoorButtonTouch"
                          receiver: respondermod:DoorOpen
                          user: 0
                    waiton: -1
                  - type: animcmdmsg
                    params:
                       receivers:
                        - 006D:Door1
                       animname: DoorOpen1
                       cmds:
                        - setbackwards
                        - continue
                    waiton: 0
                  - type: animcmdmsg
                    params:
                       receivers:
                        - 006D:SWDoorButton
                       animname: SWdoorbuttonclick
                       cmds:
                        - setforewards
                        - continue
                    waiton: 0
                  - type: soundmsg
                    params:
                       receivers:
                        - 0011:emit_swingdoor
                        - 0011:emit_swdoorbutton
                       cmds:
                         - play
                         - setvolume
                       volume: 1
                    waiton: -1
                 nextstate: 0
                 waittocmd: 0
              curstate: 0
              flags:
                - detecttrigger

emit_swingdoor:

   type: soundemit
   sound:
       flags:
         - is3dsound
       file: sonaviocreakclos
       volume: 1
       type: soundfx
       maxfdist: 50
       minfdist: 50

emit_swingdoorOpen:

   type: soundemit
   sound:
       flags:
         - is3dsound
       file: sonaviocreakopen
       volume: 1
       type: soundfx
       maxfdist: 50
       minfdist: 50

emit_swdoorbutton:

   type: soundemit
   sound:
       flags:
         - is3dsound
       file: Sonaviotile
       volume: 1
       type: soundfx
       maxfdist: 50
       minfdist: 50