Changeset 5074
- Timestamp:
- 2014-06-24 14:59:46 (9 years ago)
- Location:
- 2014/26/Pyry-PetteriP
- Files:
-
- 8 added
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
2014/26/Pyry-PetteriP/Motopeli/Motopeli/Motopeli/Motopeli.cs
r5063 r5074 9 9 public class Motopeli : PhysicsGame 10 10 { 11 Image autoKuva = LoadImage("auto"); 12 Automobile moottoripyora; 13 14 Vector[] reittiPisteet = new Vector[] 15 { new Vector( -255.0, -124.0 ), 16 new Vector( -252.0, -131.0 ), 17 new Vector( -201.0, -214.0 ), 18 19 20 21 22 }; 23 24 11 25 public override void Begin() 12 26 { 27 SmoothTextures = false; 13 28 Luokentta(); 14 Camera.Zoom(1.0); 29 Camera.ZoomToLevel(); 30 Moottoripyora(); 31 AsetaOhjaimet(); 32 33 34 } 35 36 37 void Luokentta() 38 { 39 RoadMap tie = new RoadMap(reittiPisteet); 40 tie.DefaultWidth = 200.0; 41 tie.Insert(); 42 43 44 45 } 46 47 48 void Moottoripyora() 49 { 50 moottoripyora = new Automobile(55.0, 55.0); 51 Add(moottoripyora); 52 moottoripyora.Image = autoKuva; 53 } 54 55 56 void AsetaOhjaimet() 57 { 58 Keyboard.Listen(Key.Left, ButtonState.Down, KaannaPelaajaa, null, Angle.FromDegrees(-1)); 59 Keyboard.Listen(Key.Right, ButtonState.Down, KaannaPelaajaa, null, Angle.FromDegrees(1)); 60 Keyboard.Listen(Key.Up, ButtonState.Down, KaasutaPelaajaa, null); 61 Keyboard.Listen(Key.Down, ButtonState.Down, TaaksepainPelaajaa, null); 15 62 PhoneBackButton.Listen(ConfirmExit, "Lopeta peli"); 16 63 Keyboard.Listen(Key.Escape, ButtonState.Pressed, ConfirmExit, "Lopeta peli"); 17 64 } 18 void Luokentta() 65 66 67 void LiikutaPelaajaa(Vector vektori) 19 68 { 20 Surface alaReuna = Surface.CreateBottom(Level, 30, 200, 20, 140); 21 Add(alaReuna); 22 69 moottoripyora.Push(vektori); 23 70 } 24 void moottoripyora 25 { PhysicsObject moottoripyora = new PhysicsObject (80.0, 75.0) 71 void KaannaPelaajaa(Angle kulma) 72 { 73 moottoripyora.Angle += kulma; 26 74 27 Add (moottoripyora); 28 29 75 30 76 } 31 77 78 void KaasutaPelaajaa() 79 { 80 moottoripyora.Accelerate(); 81 } 82 void TaaksepainPelaajaa() 83 { 84 moottoripyora.Brake(); 85 } 86 } 87 32 88 33 } 34 35 89 -
2014/26/Pyry-PetteriP/Motopeli/Motopeli/Motopeli/obj/x86/Debug/ContentPipeline-{49BD7CC0-449A-44E6-A07A-3F90AE280C94}.xml
r5063 r5074 2 2 <XnaContent xmlns:Pipeline="Microsoft.Xna.Framework.Content.Pipeline"> 3 3 <Asset Type="Pipeline:BuildItemCollection"> 4 <Item> 5 <Source>auto.png</Source> 6 <Name>auto</Name> 7 <Importer>TextureImporter</Importer> 8 <Processor>TextureProcessor</Processor> 9 <Options>None</Options> 10 <Output>C:\MyTemp\Pyry-PetteriP\Motopeli\Motopeli\Motopeli\bin\x86\Debug\Content\auto.xnb</Output> 11 <Time>2014-06-24T14:30:54.1764027+03:00</Time> 12 </Item> 4 13 <BuildSuccessful>true</BuildSuccessful> 5 14 <Settings> … … 16 25 <Assemblies> 17 26 <Assembly> 27 <Key>C:\Program Files (x86)\Jypeli\lib\ContentExtensions\TextFileContentExtension.dll</Key> 28 <Value>2013-09-06T09:39:14+03:00</Value> 29 </Assembly> 30 <Assembly> 31 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.XImporter.dll</Key> 32 <Value>2011-09-01T16:22:30+03:00</Value> 33 </Assembly> 34 <Assembly> 35 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.VideoImporters.dll</Key> 36 <Value>2011-09-01T16:22:30+03:00</Value> 37 </Assembly> 38 <Assembly> 39 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.TextureImporter.dll</Key> 40 <Value>2011-09-01T16:22:30+03:00</Value> 41 </Assembly> 42 <Assembly> 43 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.FBXImporter.dll</Key> 44 <Value>2011-09-01T16:22:30+03:00</Value> 45 </Assembly> 46 <Assembly> 47 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.EffectImporter.dll</Key> 48 <Value>2011-09-01T16:22:30+03:00</Value> 49 </Assembly> 50 <Assembly> 51 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.AudioImporters.dll</Key> 52 <Value>2011-09-01T16:22:30+03:00</Value> 53 </Assembly> 54 <Assembly> 55 <Key>C:\Program Files (x86)\Jypeli\lib\ContentExtensions\AnimationExtension.dll</Key> 56 <Value>2013-09-06T09:39:16+03:00</Value> 57 </Assembly> 58 <Assembly> 18 59 <Key>C:\Windows\Microsoft.Net\assembly\GAC_32\Microsoft.Xna.Framework.Content.Pipeline\v4.0_4.0.0.0__842cf8be1de50553\Microsoft.Xna.Framework.Content.Pipeline.dll</Key> 19 60 <Value>2014-04-22T21:32:12.354917+03:00</Value> -
2014/26/Pyry-PetteriP/Motopeli/Motopeli/Motopeli/obj/x86/Debug/Motopeli.csproj.FileListAbsolute.txt
r5063 r5074 7 7 C:\MyTemp\Pyry-PetteriP\Motopeli\Motopeli\Motopeli\obj\x86\Debug\Motopeli.exe 8 8 C:\MyTemp\Pyry-PetteriP\Motopeli\Motopeli\Motopeli\obj\x86\Debug\Motopeli.pdb 9 C:\MyTemp\Pyry-PetteriP\Motopeli\Motopeli\Motopeli\bin\x86\Debug\Content\auto.xnb -
2014/26/Pyry-PetteriP/Motopeli/Motopeli/MotopeliContent/MotopeliContent.contentproj
r5063 r5074 45 45 <Reference Include="AnimationExtension" /> 46 46 </ItemGroup> 47 <ItemGroup> 48 <Compile Include="auto.png"> 49 <Name>auto</Name> 50 <Importer>TextureImporter</Importer> 51 <Processor>TextureProcessor</Processor> 52 </Compile> 53 </ItemGroup> 47 54 <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\$(XnaFrameworkVersion)\Microsoft.Xna.GameStudio.ContentPipeline.targets" /> 48 55 <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Note: See TracChangeset
for help on using the changeset viewer.