src/Rope.cc
branchnew_graphics
changeset 412 721c60072091
parent 408 e6cfc44266af
child 417 c503e0c6a740
--- a/src/Rope.cc	Wed Jan 21 03:33:35 2009 +0200
+++ b/src/Rope.cc	Wed Jan 21 23:07:22 2009 +0200
@@ -1,7 +1,7 @@
 #include "Player.hh"
 #include "Rope.hh"      
 #include "Engine.hh"
-#include "Graphics.hh"
+
 #include <math.h>
 #include <stdexcept>
 
@@ -150,7 +150,7 @@
     this->length = length;
 }
 
-void Rope::draw (Graphics *g, PixelCoordinate camera) {
+void Rope::draw (graphics::Display &display, PixelCoordinate camera) {
     PixelCoordinate player_pos = player.getCoordinate() - camera;
     PixelCoordinate target_pos;
     
@@ -175,7 +175,7 @@
     target_pos -= camera;
     
     // draw a line from the player to the target chosen above
-    g->get_gc()->draw_line(
+    display.get_gc()->draw_line(
         player_pos.x, player_pos.y,
         target_pos.x, target_pos.y,
         ROPE_COLOR_DARK