clockwerk-opensim-config – Blame information for rev
?pathlinks?
Rev | Author | Line No. | Line |
---|---|---|---|
1 | eva | 1 | default |
2 | { |
||
3 | state_entry() |
||
4 | { |
||
5 | llSay( 0, "Hello, Avatar! Touch to launch me straight up."); |
||
6 | llSetStatus( 1, TRUE ); // turn on physics. |
||
7 | } |
||
8 | |||
9 | touch_start(integer total_number) |
||
10 | { |
||
11 | vector start_color = llGetColor( ALL_SIDES ); // save current color. |
||
12 | llSetColor( < 1.0, 0.0, 0.0 > , ALL_SIDES ); // set color to red. |
||
13 | |||
14 | float objMass = llGetMass(); |
||
15 | float Z_force = 20.0 * objMass; |
||
16 | |||
17 | llApplyImpulse( < 0.0, 0.0, Z_force >, FALSE ); |
||
18 | |||
19 | llSay( 0, "Impulse of " + (string)Z_force + " applied." ); |
||
20 | llSetColor( start_color , ALL_SIDES ); // set color to green. |
||
21 | } |
||
22 | } |
||
23 |