initial framework added
[fp1415-soccerfun.git] / src / StdTeam / Team_Student_DeepPass_Assignment.icl
diff --git a/src/StdTeam/Team_Student_DeepPass_Assignment.icl b/src/StdTeam/Team_Student_DeepPass_Assignment.icl
new file mode 100644 (file)
index 0000000..9d735b1
--- /dev/null
@@ -0,0 +1,25 @@
+implementation module Team_Student_DeepPass_Assignment\r
+\r
+/**    Implement a solution to the deep passing assignment.\r
+\r
+       Your team consists of two players, with player's numbers 2 and 3 respectively.\r
+       Below you should only change the definition of footballer to your solution.\r
+       Do not change the positions and player identifications. \r
+       Do not change the implementation of base_TeamName_Student_DeepPass.\r
+*/\r
+\r
+import Footballer\r
+\r
+Team_Student_DeepPass :: !Home FootballField -> Team\r
+Team_Student_DeepPass home field       = if (home == West) team (mirror field team)\r
+where\r
+       team                                                    = [  {footballer {clubName=club,playerNr=nr} & pos = toPosition (scale (0.5*x) field.flength,scale (0.5*y) field.fwidth)}\r
+                                                                         \\ (x,y) <- positions\r
+                                                                          & nr    <- [2,3]\r
+                                                                         ]\r
+       club                                                    = base_TeamName_Student_DeepPass +++ if (home==West) "_W" "_E"\r
+       positions                                               = [(0.05,-0.05),(0.35,0.05)]\r
+       footballer playerID                             = defaultFootballer playerID            // implement your footballer here\r
+\r
+base_TeamName_Student_DeepPass :: String\r
+base_TeamName_Student_DeepPass = "Student Deep Pass"\r