- Timestamp:
- 2015-06-24 15:34:04 (8 years ago)
- Location:
- 2014/30/MitjaK/Attack to Agora/Attack to Agora/Attack to Agora/Attack to Agora
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
2014/30/MitjaK/Attack to Agora/Attack to Agora/Attack to Agora/Attack to Agora/Attack_to_Agora.cs
r6272 r6276 15 15 /// Vakiot kannattaa merkitä constiksi (ei voi muuttaa). Tällöin ne kirjoitetaan isolla. 16 16 /// </summary> 17 const double NOPEUS = 500; // 25017 const double NOPEUS = 1000; // 250 18 18 const double HYPPYVOIMA = 1500; 19 19 … … 24 24 PlatformCharacter taistelija; 25 25 26 int kenttaNro = 2;26 int kenttaNro = 1; 27 27 28 28 /// <summary> … … 59 59 { 60 60 SmoothTextures = false; 61 //IsFullScreen = true;61 IsFullScreen = true; 62 62 Gravity = new Vector(0, -2500); 63 63 … … 213 213 cCaseDialog.Destroy(); 214 214 215 GameObject cCaseFront = new GameObject(200.0, 200.0); 216 cCaseFront.Color = new Color(0, 64, 0, 32); 215 GameObject cCaseFront = new GameObject(LoadImage("caseavausruutu")); 217 216 218 217 ChromaCase cCase = new ChromaCase(pItems, cCaseFront, null, 20); 219 cCase.Add( Vector.Zero, 2);218 cCase.Add(new Vector(0.0, Level.Bottom + cCaseFront.Height / 2), 2); 220 219 cCase.ItemReceived += GotItemFromCase; 220 //cCase.ItemRelativePosition = new Vector(47 221 221 cCase.Start(); 222 222 -
2014/30/MitjaK/Attack to Agora/Attack to Agora/Attack to Agora/Attack to Agora/ChromaCase.cs
r6272 r6276 18 18 19 19 public Vector Position = Vector.Zero; 20 public Vector ItemRelativePosition; 20 21 21 22 public const double START_SPEED = 0.02; … … 73 74 // n == shownItems.Count 74 75 // z == stopSpeed 75 // solve x y*x^n=z =>x = (z / y) ^ (1 / n)76 // y*x^n=z x:n suhteen => x = (z / y) ^ (1 / n) 76 77 double speedIncrease = Math.Pow((STOP_SPEED / START_SPEED), (1.0 / ShownItems.Count)); 77 78 … … 166 167 if (rNumber >= limits[i] && rNumber < limits[i + 1]) 167 168 { 169 PossibleItems[i].Position = ItemRelativePosition; 168 170 ShownItems.Add(PossibleItems[i]); 169 171 }
Note: See TracChangeset
for help on using the changeset viewer.