User Tools

Site Tools


dragengine:modules:dragonscript:abstractions

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
dragengine:modules:dragonscript:abstractions [2020/05/05 20:14] dragonlorddragengine:modules:dragonscript:abstractions [2020/05/05 20:17] dragonlord
Line 71: Line 71:
                  
         // create collider which is used for physical interaction. in most situations you want to         // create collider which is used for physical interaction. in most situations you want to
-        // animated the component with the rig. this requires to component behavior to go first+        // animate the component with the rig. this requires to component behavior to go first
         collider = ECBehaviorCollider.new(this, component)         collider = ECBehaviorCollider.new(this, component)
                  
         // create head lights. attached to collider with id "headlightLeft" respectively "headlightRight"         // create head lights. attached to collider with id "headlightLeft" respectively "headlightRight"
         headLightLeft = ECBehaviorLight.new(this, collider, "headlightLeft")         headLightLeft = ECBehaviorLight.new(this, collider, "headlightLeft")
-        headLightLeft.getLight().getColor().setColor(Color.YELLOW)+        headLightLeft.getLight().getColor().setColor(Color.yellow)
         headLightLeft.getAttach().getPosition().setVector(Vector.new(-1, 0.5, 2))         headLightLeft.getAttach().getPosition().setVector(Vector.new(-1, 0.5, 2))
                  
         headLightRight = ECBehaviorLight.new(this, collider, "headlightRight")         headLightRight = ECBehaviorLight.new(this, collider, "headlightRight")
-        headLightRight.getLight().getColor().setColor(Color.YELLOW)+        headLightRight.getLight().getColor().setColor(Color.yellow)
         headLightRight.getAttach().getPosition().setVector(Vector.new(1, 0.5, 2))         headLightRight.getAttach().getPosition().setVector(Vector.new(1, 0.5, 2))
                  
Line 93: Line 93:
                  
         // create behavior moving collider on rail. the mapper defines what rail to use.         // create behavior moving collider on rail. the mapper defines what rail to use.
-        // if you assign also the trigger system from the BaseGameApp then the mapper+        // if you assign also the trigger table from the BaseGameApp then the mapper
         // can use triggers to start/stop moving the train. if you want to control this         // can use triggers to start/stop moving the train. if you want to control this
         // on your own (or by other behaviors only) leave out this argument         // on your own (or by other behaviors only) leave out this argument
-        moveOnRail = ECBehaviorMoveOnRail.new(this, collider, BaseGameApp.getApp().getTriggerSystem())+        moveOnRail = ECBehaviorMoveOnRail.new(this, collider, BaseGameApp.getApp().getTriggerTable())
    end    end
 end end
dragengine/modules/dragonscript/abstractions.txt · Last modified: 2024/03/14 16:43 by dragonlord