# Play GLB Animation (pre built in GLB file)

| refId      | objId of the object                                                                    | required                                         | <p>string</p><p><br></p> |
| ---------- | -------------------------------------------------------------------------------------- | ------------------------------------------------ | ------------------------ |
| trigger    | trigger type of the object                                                             | required                                         | ‘scroll’ \| ‘event’      |
| actionName | Assign the click name that needs to be played                                          | required                                         | string                   |
| leftX      | use only for trigger: ‘scroll’, default: 0 (starting point of your trigger)            | optional                                         | number                   |
| length     | <p>default: 200 (duration of your animation)</p><p>(use only for trigger: ‘scroll’</p> | Optional (60 fps per sec 200 is the default fps) | number                   |

```javascript
// IDE.playGLBAnimation({
	 refId: objId,
        trigger: 'scroll',
        actionName: 'green_open',
        leftX: 150,
        length: 10,
    })

IDE.playGLBAnimation({
	 refId: objId,
        trigger: 'event',
        actionName: 'green_open',
    })

```
