Beispiel #1
0
def LeftDoMoveOnX(x, y, z):
	funcMouv.moveCenter(constant.coords, constant.legs, 
		-(constant.SIZE_IMAGE/2)+((constant.SIZE_IMAGE -1)-x), 
		-(constant.SIZE_IMAGE/2)+(y), z)
Beispiel #2
0
						freq_speed_robot = freq_speed_robot - constant.VARIATION_ROBOT_SPEED
					else :
						print "You can't move slower."

		# Condition to Stand up
		if standUp :
			funcMouv.standUp()
			time.sleep(constant.TIME_SLEEP_STAND_UP)
			funcMouv.standUp()
			standUp = not standUp

		# Condition to writing
		if writing :
			if (not onPosition):
				for i in range(4):
					funcMouv.moveCenter(constant.coords, constant.legs, 0, 0, i*10)
					time.sleep(constant.TIME_SLEEP_WRITING)
				onPosition = True

			if writingON :
				funcMouv.moveCenter(constant.coords, constant.legs, (x/constant.SCALE_PICTURE_OTHER), (y/constant.SCALE_PICTURE_OTHER), constant.HEIGHT_TO_WRITE_ON)
			if not writingON :
				funcMouv.moveCenter(constant.coords, constant.legs, (x/constant.SCALE_PICTURE_OTHER), (y/constant.SCALE_PICTURE_OTHER), constant.HEIGHT_TO_WRITE_OFF)

		# Condition to move one leg
		if move_leg :
			funcMouv.moveLeg(constant.legs, 0, constant.coords[0][0]-(y/constant.SCALE_PICTURE_OTHER), constant.coords[0][1]-(x/constant.SCALE_PICTURE_OTHER), zleg)

		# Condition to dancing
		if dancing :
			funcMouv.goToDance(constant.LENGTH_DANCE, constant.FREQ_DANCE)
Beispiel #3
0
def RightDoMoveOnX(x, y, z):
	funcMouv.moveCenter(constant.coords, constant.legs, 
		-(constant.SIZE_IMAGE/2)+x, -(constant.SIZE_IMAGE/2)+y, z)