Permalink
Browse files

Levers are now toggled by thrown objects again

  • Loading branch information...
1 parent 7db8135 commit c95034464452c9116c6b0bb09250f4a1cb8eb1c7 @marcavis marcavis committed May 3, 2012
@@ -10,7 +10,7 @@ vars: {
pressed: 0,
},
on_create: "set(animation, if(vars.pressed, 'pushed', 'normal'))",
-on_collide_object_body: "if(collide_with.team = 'player' and (collide_with_area = 'attack'), get_hit_by(collide_with))",
+on_collide_object_body: "if(collide_with.team = 'player' and (collide_with_area in ['attack', 'thrown']), get_hit_by(collide_with))",
on_enter_pushed_anim: "[if(get_object(level, linked_object) and (not level.in_editor), fire_event(get_object(level, linked_object), 'button_pressed')), if(linked_object_list, map(linked_object_list, 'obj', fire_event(get_object(level, obj), 'button_pressed')))]",
on_leave_pushed_anim: "[if(get_object(level, linked_object) and (not level.in_editor), fire_event(get_object(level, linked_object), 'button_released')), if(linked_object_list, map(linked_object_list, 'obj', fire_event(get_object(level, obj), 'button_released')))]",
editor_info: {
@@ -44,4 +44,4 @@ animation: [
duration: 1000000,
},
],
-}
+}
@@ -10,7 +10,7 @@ vars: {
pressed: 0,
},
on_create: "set(animation, if(vars.pressed, 'pushed', 'normal'))",
-on_collide_object_body: "if(collide_with.team = 'player' and (collide_with_area = 'attack'), get_hit_by(collide_with))",
+on_collide_object_body: "if(collide_with.team = 'player' and (collide_with_area in ['attack', 'thrown']), get_hit_by(collide_with))",
on_enter_pushed_anim: "[if(get_object(level, linked_object) and (not level.in_editor), fire_event(get_object(level, linked_object), 'button_pressed')), if(linked_object_list, map(linked_object_list, 'obj', fire_event(get_object(level, obj), 'button_pressed')))]",
on_leave_pushed_anim: "[if(get_object(level, linked_object) and (not level.in_editor), fire_event(get_object(level, linked_object), 'button_released')), if(linked_object_list, map(linked_object_list, 'obj', fire_event(get_object(level, obj), 'button_released')))]",
editor_info: {
@@ -44,4 +44,4 @@ animation: [
duration: 1000000,
},
],
-}
+}

0 comments on commit c950344

Please sign in to comment.