Changeset 6981
- Timestamp:
- 2015-07-23 14:51:56 (8 years ago)
- Location:
- 2015/30/ArttuH/TasoHyppely
- Files:
-
- 3 added
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
2015/30/ArttuH/TasoHyppely/TasoHyppely/TasoHyppely/TasoHyppely.cs
r6978 r6981 12 12 const double hyppyNopeus = 750; 13 13 const int RUUDUN_KOKO = 40; 14 double ammusnopeus2 = 1500;14 double ammusnopeus2 = 3000; 15 15 double pahisNopeus = 100; 16 16 double Painovoima = -1000; 17 17 double pelaajaMassa = 4.0; 18 double pelaajan1_ase_nopeus = 1 000000;18 double pelaajan1_ase_nopeus = 15; 19 19 double ase_X = 20.0; 20 20 double ase_Y = -10.0; … … 26 26 double pelaajan2_Luoti_laskuri_X = 190; 27 27 double pelaajan2_Luoti_laskuri_Y = 180; 28 double pelaajan1_luodin_massa = 150; 29 double pelaajan2_luodin_massa = 15; 28 30 29 31 bool pelaaja1ampuu = false; … … 63 65 { 64 66 ClearAll(); 67 MediaPlayer.Play("LevelUp"); 65 68 Gravity = new Vector(0, Painovoima); 66 69 TileMap kentta = TileMap.FromLevelAsset("Kentta"+ kenttaNro); … … 127 130 pelaaja1.Weapon.Y = ase_Y; 128 131 pelaaja1.Weapon.Ammo.Value = 100; 132 pelaaja1.Weapon.AmmoIgnoresGravity = false; 129 133 elamalaskuri = new IntMeter(20, 0, 20); 130 134 elamalaskuri.LowerLimit += delegate {PiikkiTormaa(pelaaja1, new PhysicsObject(1,1));}; … … 140 144 ControllerOne.Listen(Button.RightTrigger, ButtonState.Pressed, delegate { pelaaja1ampuu = true; }, null); 141 145 ControllerOne.Listen(Button.RightTrigger, ButtonState.Released, delegate {pelaaja1ampuu = false;} , null); 146 ControllerOne.Listen(Button.DPadLeft, ButtonState.Pressed, Cheathauska, ""); 142 147 Add(pelaaja1); 143 148 } … … 166 171 ControllerTwo.Listen(Button.Start, ButtonState.Pressed, ConfirmExit, "Lopeta peli"); 167 172 Keyboard.Listen(Key.F1, ButtonState.Pressed, Cheat, ""); 173 Keyboard.Listen(Key.F2, ButtonState.Down, LuotiCheat, ""); 174 ControllerOne.Listen(Button.DPadDown, ButtonState.Down, LuotiCheat, ""); 175 ControllerTwo.Listen(Button.DPadDown, ButtonState.Down, LuotiCheat, ""); 168 176 } 169 177 … … 178 186 pelaaja2.Weapon = new AssaultRifle(50, 10); 179 187 pelaaja2.Weapon.FireRate = 1; 188 pelaaja2.Weapon.AmmoIgnoresGravity = false; 180 189 pelaaja2.Weapon.Image = null; 181 190 pelaaja2.Weapon.Image = asekuva2; … … 260 269 luotilaskuri.Value--; 261 270 ammus.Size *= 0.8; 262 ammus.Mass = 50000000;271 ammus.Mass = pelaajan1_luodin_massa; 263 272 ammus.Image = luoti; 264 273 ControllerOne.Vibrate(0.16, 0.16, 0.16, 0.16, 0.1); … … 304 313 pelaaja2.Weapon.Angle += Angle.FromDegrees(RandomGen.NextInt(-1, 1)); 305 314 ammus.Size *= 0.8; 306 ammus.Mass = 500000;315 ammus.Mass = pelaajan2_luodin_massa; 307 316 ammus.Image = luoti; 308 317 luotilaskuri2.Value--; … … 436 445 elamalaskuri2.Value -= 1; 437 446 } 447 void LuotiCheat() 448 { 449 pelaaja1.Weapon.Ammo.Value = 100; 450 luotilaskuri.Value = 100; 451 452 pelaaja2.Weapon.Ammo.Value = 100; 453 luotilaskuri2.Value = 100; 454 } 455 void Cheathauska() 456 { 457 ammusnopeus2 = 999999999999999; 458 pelaajan1_ase_nopeus = 999999999999999; 459 pelaaja1.Weapon.InfiniteAmmo = true; 460 pelaaja2.Weapon.InfiniteAmmo = true; 461 } 438 462 } -
2015/30/ArttuH/TasoHyppely/TasoHyppely/TasoHyppely/TasoHyppely.csproj.Debug.cachefile
r6978 r6981 26 26 Content\kentta6.xnb 27 27 Content\Kentta3.xnb 28 Content\LevelUp.xnb 28 29 Content\Gaslamp_Funworks.wma 30 Content\LevelUp.wma -
2015/30/ArttuH/TasoHyppely/TasoHyppely/TasoHyppely/obj/x86/Debug/TasoHyppely.csproj.FileListAbsolute.txt
r6978 r6981 67 67 C:\MyTemp\ArttuH\TasoHyppely\TasoHyppely\TasoHyppely\bin\x86\Debug\Content\kentta6.xnb 68 68 C:\MyTemp\ArttuH\TasoHyppely\TasoHyppely\TasoHyppely\bin\x86\Debug\Content\Kentta3.xnb 69 C:\MyTemp\ArttuH\TasoHyppely\TasoHyppely\TasoHyppely\bin\x86\Debug\Content\LevelUp.xnb 70 C:\MyTemp\ArttuH\TasoHyppely\TasoHyppely\TasoHyppely\bin\x86\Debug\Content\LevelUp.wma -
2015/30/ArttuH/TasoHyppely/TasoHyppely/TasoHyppely/obj/x86/Debug/cachefile-{6FC3E379-BCB4-46AD-88D8-15B242DAFE49}-targetpath.txt
r6978 r6981 27 27 Content\kentta6.xnb 28 28 Content\Kentta3.xnb 29 Content\LevelUp.xnb 30 Content\LevelUp.wma -
2015/30/ArttuH/TasoHyppely/TasoHyppely/TasoHyppelyContent/Kentta2.txt
r6978 r6981 1 2 3 4 5 6 7 .................................P...P..P..B...................................................................................................... 8 .............................*.##########################..A..A..A................................................................................ 9 ..1.2...................*.#####..........................#########...............P..P.B.B...B..B..B..H............................................ 10 #########..........*..####..........................................#.#.#...###########################...H...B..B.B.............................. 11 ..............*...###.............................................xxxxxxxxxxx..........................##################..B.P.B.P.B.B..........M. 12 ...........######........................................................................................................########################. 13 XXXXXXXXXXX....................................................................................................................................... 1 2 3 4 5 6 7 .................................P...P..P..B...................................................................................................... 8 .............................*.##########################..A..A..A................................................................................ 9 ..1.2...................*.#####..........................#########...............P..P.B.B...B..B..B..H............................................ 10 #########..........*..####..........................................#.#.#...###########################...H...B..B.B.............................. 11 ..............*...###.............................................xxxxxxxxxxx..........................##################..B.P.B.P.B.B..........M. 12 ...........######........................................................................................................########################. 13 XXXXXXXXXXX....................................................................................................................................... 14 15 16 17 18 19 20 -
2015/30/ArttuH/TasoHyppely/TasoHyppely/TasoHyppelyContent/TasoHyppelyContent.contentproj
r6978 r6981 218 218 </Compile> 219 219 </ItemGroup> 220 <ItemGroup> 221 <Compile Include="LevelUp.mp3"> 222 <Name>LevelUp</Name> 223 <Importer>Mp3Importer</Importer> 224 <Processor>SongProcessor</Processor> 225 </Compile> 226 </ItemGroup> 220 227 <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\$(XnaFrameworkVersion)\Microsoft.Xna.GameStudio.ContentPipeline.targets" /> 221 228 <!-- To modify your build process, add your task inside one of the targets below and uncomment it. -
2015/30/ArttuH/TasoHyppely/TasoHyppely/TasoHyppelyContent/obj/x86/Debug/ContentPipeline.xml
r6978 r6981 193 193 <Options>None</Options> 194 194 <Output>C:\MyTemp\ArttuH\TasoHyppely\TasoHyppely\TasoHyppely\bin\x86\Debug\Content\Kentta2.xnb</Output> 195 <Time>2015-07-23T13: 17:52.1743538+03:00</Time>195 <Time>2015-07-23T13:45:26.1107538+03:00</Time> 196 196 </Item> 197 197 <Item> … … 249 249 <Output>C:\MyTemp\ArttuH\TasoHyppely\TasoHyppely\TasoHyppely\bin\x86\Debug\Content\Kentta3.xnb</Output> 250 250 <Time>2015-07-23T13:37:35.1409538+03:00</Time> 251 </Item> 252 <Item> 253 <Source>LevelUp.mp3</Source> 254 <Name>LevelUp</Name> 255 <Importer>Mp3Importer</Importer> 256 <Processor>SongProcessor</Processor> 257 <Options>None</Options> 258 <Output>C:\MyTemp\ArttuH\TasoHyppely\TasoHyppely\TasoHyppely\bin\x86\Debug\Content\LevelUp.xnb</Output> 259 <Extra>C:\MyTemp\ArttuH\TasoHyppely\TasoHyppely\TasoHyppely\bin\x86\Debug\Content\LevelUp.wma</Extra> 260 <Time>2015-07-23T14:37:32.8998538+03:00</Time> 251 261 </Item> 252 262 <BuildSuccessful>true</BuildSuccessful>
Note: See TracChangeset
for help on using the changeset viewer.