1 | The script can access any exposedField, eventIn or eventOut of any node to which it has a pointer: |
2 | |
3 | DEF MyCube3 Transform { } |
4 | DEF Example_3 Script { |
5 | field SFNode node USE MyCube3 |
6 | eventIn SFVec3f pos |
7 | directOutput TRUE |
8 | url "javascript: |
9 | function pos(value) { |
10 | node.set_translation = value; |
11 | }" |
12 | } |