Example #1
0
	def draw(self):
		motherboard.setPenRadius(.002)
		motherboard.setPenColor(self.color)
		motherboard.filledRectangle(self.xpos, self.ypos, self.width, self.height)
		motherboard.setPenColor(motherboard.DARK_GRAY)
		motherboard.setFontFamily("Arial")
		motherboard.setFontSize(20)
		motherboard.text(self.xpos, self.ypos, self.name)
		motherboard.rectangle(self.xpos, self.ypos, self.width, self.height)
Example #2
0
	def update(self):

		for i in self.ordersleft:
			i.draw()

		for i in self.ordersright:
			i.draw()

		motherboard.text(self.xpos, self.ypos + self.height - (self.height - self.innerheight)/2, str(self.cupPanel.num_yellow))
		motherboard.text(self.xpos+ 2*self.width/3, self.ypos + self.height - (self.height - self.innerheight)/2, str(self.cupPanel.num_green))
		motherboard.text(self.xpos- 2*self.width/3, self.ypos + self.height - (self.height - self.innerheight)/2, str(self.cupPanel.num_red))
Example #3
0
motherboard.filledCircle(largecupX+60, largecupY, 20)
motherboard.setPenColor(motherboard.DARK_GRAY)

#outlines of circles
motherboard.setPenRadius(0.004)
motherboard.circle(largecupX, largecupY, 21)
motherboard.circle(largecupX+60, largecupY, 21)
motherboard.circle(largecupX-60, largecupY, 21)

#Statuses
motherboard.setFontFamily("Arial")
motherboard.setFontSize(20)
yellowStatus = "1"
redStatus = "3"
greenStatus = "2"
motherboard.text(largecupX, largecupY, yellowStatus)
motherboard.text(largecupX+60, largecupY, greenStatus)
motherboard.text(largecupX-60, largecupY, redStatus)

#-------------------------------------------------------------------
# Cup panel for the circle
#
#-------------------------------------------------------------------

#circle cup panel
circlecupX = circleX
circlecupY = circleY + 130
motherboard.setPenRadius(0.005)
motherboard.setPenColor(motherboard.DARK_GRAY)
motherboard.rectangle(circlecupX, circlecupY, 100, 21)
Example #4
0
		motherboard.circle(self.xpos, self.ypos + self.height - (self.height - self.innerheight)/2 , 21)
		motherboard.circle(self.xpos + 2*self.width/3, self.ypos + self.height - (self.height - self.innerheight)/2 , 21)
		motherboard.circle(self.xpos - 2*self.width/3, self.ypos + self.height - (self.height - self.innerheight)/2 , 21)

		#add table
)
		
		#draw orders
		for i in self.ordersleft:
			i.draw()

		for i in self.ordersright:
			i.draw()

		#draw cup panel numbers
		motherboard.text(self.xpos, self.ypos + self.height - (self.height - self.innerheight)/2, str(self.cupPanel.num_yellow))
		motherboard.text(self.xpos+ 2*self.width/3, self.ypos + self.height - (self.height - self.innerheight)/2, str(self.cupPanel.num_green))
		motherboard.text(self.xpos- 2*self.width/3, self.ypos + self.height - (self.height - self.innerheight)/2, str(self.cupPanel.num_red))

		motherboard.setFontFamily("Arial")
		motherboard.setFontSize(20)
		motherboard.text(self.xpos, self.ypos, 'Table: ' + str(self.number))
	
	def update(self):

		for i in self.ordersleft:
			i.draw()

		for i in self.ordersright:
			i.draw()