Space Invasion - Multiplying Integers

Space Invasion - Multiplying Integers
Loading the math board and drawing, please wait…
2019-07-26 20:31
This example demonstrates integer multiplication through a space invasion game. It involves core math concepts like integer multiplication and random number generation. Construction highlights include using GeoGebra commands such as Sequence, Shuffle, Segment, Point, Line, Join, Centroid, OrthogonalLine, Intersect, LineBisector, Circle, If, Polygon to create game elements and interactions. Suitable for middle school mathematics teaching to practice integer multiplication in a fun way.

GeoGebra Commands & Parameters

  1. Sequence(Random[-10, 10], j, 1, 6, 1) → A3drugiFakt
  2. Shuffle(Sequence[j, j, -10, 10, 1]) → A1sviPrviFakt
  3. Sequence(Element[A1sviPrviFakt, j], j, 1, 6, 1) → A2odabrPrviFakt
  4. Segment(A', B') → f
  5. Point(f) → A_1
  6. Segment((5.2, 3.6), (5.2, -3.6)) → h
  7. Point(h) → C
  8. Line(C, xAxis) → g
  9. Point(g) → D
  10. Point(g) → E
  11. Point(g) → F
  12. Point(g) → G
  13. Point(g) → H
  14. Point(g) → I
  15. Point(g) → J
  16. Point(g) → K
  17. Point(g) → L
  18. Point(g) → M
  19. Point(g) → N
  20. Point(g) → O
  21. Join({A2odabrPrviFakt, A3drugiFakt}) → listaBrojeva
  22. Centroid(Polygon[A_1, B_1, B'_1, A'_1]) → P
  23. OrthogonalLine(P, xAxis) → j
  24. Line(B''_1, xAxis) → i
  25. Intersect(i, j) → Q
  26. LineBisector(C, C') → k
  27. Line(Q, yAxis) → l
  28. Intersect(k, l) → R
  29. Circle(R, 0.25) → c
  30. Intersect(c, j) → S, T
  31. Intersect(c, k) → U, V
  32. Segment(S, T) → m
  33. Segment(U, V) → n
  34. Segment(S, Q) → p
  35. If(x(D) < x(R) < x(E), true, false) → uPodručju1
  36. If(x(H) < x(R) < x(I), true, false) → uPodručju3
  37. If(x(J) < x(R) < x(K), true, false) → uPodručju4
  38. If(x(L) < x(R) < x(M), true, false) → uPodručju5
  39. If(x(N) < x(R) < x(O), true, false) → uPodručju6
  40. If(x(F) < x(R) < x(G), true, false) → uPodručju2
  41. If(uPodručju1, tekstRjeZad1, If[uPodručju2, tekstRjeZad2, If[uPodručju3, tekstRjeZad3, If[uPodručju4, tekstRjeZad4, If[uPodručju5, tekstRjeZad5, If[uPodručju6, tekstRjeZad6, "izvan"]]]]]) → naciljanBrojTxt
  42. Shuffle({1, 2, 3, 4, 5, 6}) → indeksiZadaciShuffle
  43. If(Text[Object["rjeZad" + (Element[indeksiZadaciShuffle, redniBrZad])]] ≟ naciljanBrojTxt, true, false) → tocnoPogodjeno
  44. Segment(Q, R) → q
  45. Point(q) → Projektil
  46. If(uPodručju1, 1, If[uPodručju2, 2, If[uPodručju3, 3, If[uPodručju4, 4, If[uPodručju5, 5, If[uPodručju6, 6, 0]]]]]) → gdjeJeProjektil
  47. If(y(C) ≟ -3.6, true, false) → krajIgre
  48. If(x(D) < x(S) < x(E) ∧ vidljivoPodručje1 ∨ x(F) < x(S) < x(G) ∧ vidljivoPodručje2 ∨ x(H) < x(S) < x(I) ∧ vidljivoPodručje3 ∨ x(J) < x(S) < x(K) ∧ vidljivoPodručje4 ∨ x(L) < x(S) < x(M) ∧ vidljivoPodručje5 ∨ x(N) < x(S) < x(O) ∧ vidljivoPodručje6, true, false) → JeLiNaciljanBrod
  49. Polygon(A, B, (x(B), 5.3), (x(A), 5.3)) → okvir, r, s, t, a

AI Drawing Prompt Reference

Create a space invasion game with 6 random integers representing enemy ships. The ships are located above the x-axis, and the player needs to click to hit them. Each ship's coordinates are formed by two random integers, and the player needs to click the correct position to hit the ship. The game area is divided into six sections, each corresponding to a ship. After clicking, a shooting line will be generated, passing through the ship. If the shooting line hits the ship, the game will show correct, otherwise incorrect.
The prompt above was compiled from the original drawing commands and is for reference only.