Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/TurtleArt
diff options
context:
space:
mode:
Diffstat (limited to 'TurtleArt')
-rw-r--r--TurtleArt/tacollaboration.py12
-rw-r--r--TurtleArt/taturtle.py2
2 files changed, 7 insertions, 7 deletions
diff --git a/TurtleArt/tacollaboration.py b/TurtleArt/tacollaboration.py
index 84ad4db..26a21d7 100644
--- a/TurtleArt/tacollaboration.py
+++ b/TurtleArt/tacollaboration.py
@@ -279,22 +279,22 @@ class Collaboration():
''' Set xy location so joiner can sync turtle positions. Should be
used to sync positions after turtle drag. '''
self._tw.turtles.set_turtle(self._get_nick())
- if self._tw.turtles.get_active_turtle().pendown:
+ if self._tw.turtles.get_active_turtle().get_pen_state():
self.send_event('p|%s' % (data_to_string([self._get_nick(),
False])))
put_pen_back_down = True
else:
put_pen_back_down = False
self.send_event('x|%s' % (data_to_string(
- [self._get_nick(),
- [int(self._tw.turtles.get_active_turtle().get_xy()[0]),
- int(self._tw.turtles.get_active_turtle().get_xy()[1])]])))
+ [self._get_nick(),
+ [int(self._tw.turtles.get_active_turtle().get_xy()[0]),
+ int(self._tw.turtles.get_active_turtle().get_xy()[1])]])))
if put_pen_back_down:
self.send_event('p|%s' % (data_to_string([self._get_nick(),
True])))
self.send_event('r|%s' % (data_to_string(
- [self._get_nick(),
- int(self._tw.turtles.get_active_turtle().get_heading())])))
+ [self._get_nick(),
+ int(self._tw.turtles.get_active_turtle().get_heading())])))
def _reskin_turtle(self, payload):
if len(payload) > 0:
diff --git a/TurtleArt/taturtle.py b/TurtleArt/taturtle.py
index d829020..030d58d 100644
--- a/TurtleArt/taturtle.py
+++ b/TurtleArt/taturtle.py
@@ -666,7 +666,7 @@ class Turtle:
height = pixbuf.get_height()
width = pixbuf.get_width()
- pos = self.screen_to_turtle_coordinates((x, y))
+ pos = self._turtles.screen_to_turtle_coordinates((x, y))
event = 'P|%s' % (data_to_string([self._turtles.turtle_window.nick,
[round_int(a), round_int(b),