def getCorrectRotation(self): r = self.getR() if r == 90.0: r = 270.0 elif r == 270.0: r = 90.0 if self.id == PartyGlobals.ActivityIds.PartyCannon: return PartyUtils.convertDegreesToPartyGrid(r + 180.0) return PartyUtils.convertDegreesToPartyGrid(r)
def getCorrectRotation(self): """ Since the y value is inverted in our grid, we need to flip the rotation of elements that are to either side, but not top/bottom. """ r = self.getR() if r == 90.0: r = 270.0 elif r == 270.0: r = 90.0 if self.id == PartyGlobals.ActivityIds.PartyCannon: return PartyUtils.convertDegreesToPartyGrid((r + 180.0)) return PartyUtils.convertDegreesToPartyGrid(r)