Advertisement
Guest User

sp

a guest
Jul 9th, 2017
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.03 KB | None | 0 0
  1. prixt =0
  2. prix = ""
  3. pr = peripheral.wrap("bottom")
  4. ligne = 7
  5. print("Acheteur")
  6. acheteur = read()
  7. pr.newPage()
  8. pr.setPageTitle(acheteur)
  9. print("commande fini ? ")
  10. reponse = read()
  11.    
  12.      while reponse~="oui" do
  13.  
  14. ligne = ligne+1
  15. print("qu'a t'il commander?")
  16. commande = read()
  17. print("Combien?")
  18. nombre = read()
  19. print("a quel prix?")
  20. prix = read()
  21. prixt=prixt+prix
  22. print(prixt)
  23. pr.setCursorPos(4,1)
  24. pr.write("~commande SpiriT&Co~")
  25. pr.setCursorPos(1,2)
  26. --pr.write("------------------------")
  27. pr.setCursorPos(1,3)
  28. pr.write("Acquereur :")
  29. pr.setCursorPos(14,3)
  30. pr.write(acheteur)
  31. pr.setCursorPos(1,5)
  32. pr.write("--------------------------")
  33. pr.setCursorPos(1,6)
  34. pr.write("Nom")
  35. pr.setCursorPos(11,6)
  36. pr.write("| Nombre")
  37. pr.setCursorPos(20,6)
  38. pr.write("| Prix")
  39. pr.setCursorPos(1,7)
  40. pr.write("--------------------------")
  41. pr.setCursorPos(1,ligne)
  42. pr.write(commande)
  43. pr.setCursorPos(12,ligne)
  44. pr.write(nombre)
  45. pr.setCursorPos(21,ligne)
  46. pr.write(prix)
  47. print("commande fini ? ")
  48. reponse= read()
  49.  
  50.  
  51.  
  52. end
  53. pr.endPage()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement