Changeset 8863
- Timestamp:
- 2017-07-04 11:54:53 (6 years ago)
- Location:
- 2017/27/OskariK
- Files:
-
- 8 added
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
2017/27/OskariK/OK/OK/OK/OK.cs
r8840 r8863 7 7 using Jypeli.Widgets; 8 8 9 public class OK : Game9 public class OK : PhysicsGame 10 10 { 11 PhysicsObject command; 12 PhysicsObject feed; 11 GameObject command; 12 GameObject feed; 13 GameObject portrait; 14 GameObject foe; 15 16 PhysicsObject Pointer; 17 18 Vector nopeusYlos = new Vector(0, 100); 19 Vector nopeusAlas = new Vector(0, -100); 20 Vector nopeusVasen = new Vector(-200, 0); 21 Vector nopeusOikea = new Vector(200, 0); 22 13 23 public override void Begin() 14 24 { 15 25 LuoAlue(); 26 luopelaaja(); 16 27 Kontrollit(); 17 28 … … 23 34 Level.Background.Color = Color.White; 24 35 25 command = new PhysicsObject(400.0, 300.0);36 command = new GameObject(450.0, 300.0); 26 37 command.Shape = Shape.Rectangle; 27 38 command.Color = Color.Black; 28 command.X = 100.00; 29 command.Y = -250.00; 39 command.X = 370.00; 40 command.Y = -330.00; 41 command.Image = LoadImage("Kökkö"); 30 42 Add(command); 31 43 32 feed = new PhysicsObject(700.00, 300.00);44 feed = new GameObject(1000.00, 300.00); 33 45 feed.Shape = Shape.Rectangle; 34 46 feed.Color = Color.Black; 35 feed.X = - 500.00;36 feed.Y = - 250.00;47 feed.X = -400.00; 48 feed.Y = -330.00; 37 49 Add(feed); 38 50 39 portrait = new PhysicsObject(100.00, 300.00); 51 portrait = new GameObject(250.00, 300.00); 52 portrait.Shape = Shape.Rectangle; 53 portrait.Color = Color.Black; 54 portrait.X = 750.00; 55 portrait.Y = -330.00; 56 Add(portrait); 57 58 foe = new GameObject(1800.00, 700.00); 59 foe.Shape = Shape.Rectangle; 60 foe.Color = Color.Blue; 61 foe.X = -10.00; 62 foe.Y = 200.00; 63 Add(foe); 40 64 } 41 65 66 PhysicsObject luopelaaja() 67 { 68 Pointer = new PhysicsObject (10.0, 10.0); 69 Pointer.Color = Color.White; 70 Pointer.X = 190.00; 71 Pointer.Y = -220.00; 72 Add(Pointer,3); 73 return Pointer; 74 } 75 76 void AsetaNopeus(PhysicsObject Pointer, Vector nopeus) 77 { 78 Vector sijainti = Pointer.Position + nopeus; 79 if (sijainti.Y > command.Top) return; 80 else if (sijainti.Y < command.Bottom) return; 81 82 Pointer.MoveTo(Pointer.Position + nopeus, 1000.00); 83 84 } 42 85 void Kontrollit () 43 { Keyboard.Listen(Key.Escape, ButtonState.Pressed, ConfirmExit, "Lopeta peli"); } 86 { 87 Keyboard.Listen(Key.Down, ButtonState.Pressed, AsetaNopeus, "liikkuu", Pointer, nopeusAlas); 88 //Keyboard.Listen(Key.Down, ButtonState.Released, AsetaNopeus, null, Pointer, Vector.Zero); 89 90 Keyboard.Listen(Key.Up, ButtonState.Pressed, AsetaNopeus, "liikkuu", Pointer, nopeusYlos); 91 //Keyboard.Listen(Key.Up, ButtonState.Released, AsetaNopeus, null, Pointer, Vector.Zero); 92 93 //Keyboard.Listen(Key.Left, ButtonState.Pressed, AsetaNopeus, "liikkuu", Pointer, nopeusVasen); 94 ///Keyboard.Listen(Key.Left, ButtonState.Released, AsetaNopeus, null, Pointer, Vector.Zero); 95 96 //Keyboard.Listen(Key.Right, ButtonState.Pressed, AsetaNopeus, "liikkuu", Pointer, nopeusOikea); 97 //Keyboard.Listen(Key.Right, ButtonState.Released, AsetaNopeus, null, Pointer, Vector.Zero); 98 99 Keyboard.Listen(Key.Escape, ButtonState.Pressed, ConfirmExit, "Lopeta peli"); } 44 100 } -
2017/27/OskariK/OK/OK/OK/obj/x86/Debug/ContentPipeline-{FF5F8A32-FAE3-40A4-9505-35D2B1C5DB01}.xml
r8840 r8863 2 2 <XnaContent xmlns:Pipeline="Microsoft.Xna.Framework.Content.Pipeline"> 3 3 <Asset Type="Pipeline:BuildItemCollection"> 4 <Item> 5 <Source>kikki.png</Source> 6 <Name>kikki</Name> 7 <Importer>TextureImporter</Importer> 8 <Processor>TextureProcessor</Processor> 9 <Options>None</Options> 10 <Output>C:\MyTemp\OskariK\OK\OK\OK\bin\x86\Debug\Content\kikki.xnb</Output> 11 <Time>2017-07-04T11:30:13.5834865+03:00</Time> 12 </Item> 13 <Item> 14 <Source>kökkö.png</Source> 15 <Name>kökkö</Name> 16 <Importer>TextureImporter</Importer> 17 <Processor>TextureProcessor</Processor> 18 <Options>None</Options> 19 <Output>C:\MyTemp\OskariK\OK\OK\OK\bin\x86\Debug\Content\kökkö.xnb</Output> 20 <Time>2017-07-04T11:40:52.0044288+03:00</Time> 21 </Item> 4 22 <BuildSuccessful>true</BuildSuccessful> 5 23 <Settings> … … 16 34 <Assemblies> 17 35 <Assembly> 36 <Key>C:\Program Files (x86)\Jypeli\lib\ContentExtensions\TextFileContentExtension.dll</Key> 37 <Value>2015-02-09T20:18:44+02:00</Value> 38 </Assembly> 39 <Assembly> 40 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.XImporter.dll</Key> 41 <Value>2011-09-01T16:22:30+03:00</Value> 42 </Assembly> 43 <Assembly> 44 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.VideoImporters.dll</Key> 45 <Value>2011-09-01T16:22:30+03:00</Value> 46 </Assembly> 47 <Assembly> 48 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.TextureImporter.dll</Key> 49 <Value>2011-09-01T16:22:30+03:00</Value> 50 </Assembly> 51 <Assembly> 52 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.FBXImporter.dll</Key> 53 <Value>2011-09-01T16:22:30+03:00</Value> 54 </Assembly> 55 <Assembly> 56 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.EffectImporter.dll</Key> 57 <Value>2011-09-01T16:22:30+03:00</Value> 58 </Assembly> 59 <Assembly> 60 <Key>C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Content.Pipeline.AudioImporters.dll</Key> 61 <Value>2011-09-01T16:22:30+03:00</Value> 62 </Assembly> 63 <Assembly> 64 <Key>C:\Program Files (x86)\Jypeli\lib\ContentExtensions\AnimationExtension.dll</Key> 65 <Value>2015-02-17T22:27:18+02:00</Value> 66 </Assembly> 67 <Assembly> 18 68 <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 69 <Value>2017-06-07T15:46:40.1506283+03:00</Value> -
2017/27/OskariK/OK/OK/OK/obj/x86/Debug/OK.csproj.FileListAbsolute.txt
r8840 r8863 7 7 C:\MyTemp\OskariK\OK\OK\OK\obj\x86\Debug\OK.exe 8 8 C:\MyTemp\OskariK\OK\OK\OK\obj\x86\Debug\OK.pdb 9 C:\MyTemp\OskariK\OK\OK\OK\bin\x86\Debug\Content\kikki.xnb 10 C:\MyTemp\OskariK\OK\OK\OK\bin\x86\Debug\Content\kökkö.xnb -
2017/27/OskariK/OK/OK/OKContent/OKContent.contentproj
r8840 r8863 45 45 <Reference Include="AnimationExtension" /> 46 46 </ItemGroup> 47 <ItemGroup> 48 <Compile Include="kikki.png"> 49 <Name>kikki</Name> 50 <Importer>TextureImporter</Importer> 51 <Processor>TextureProcessor</Processor> 52 </Compile> 53 </ItemGroup> 54 <ItemGroup> 55 <Compile Include="kökkö.png"> 56 <Name>kökkö</Name> 57 <Importer>TextureImporter</Importer> 58 <Processor>TextureProcessor</Processor> 59 </Compile> 60 </ItemGroup> 47 61 <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\$(XnaFrameworkVersion)\Microsoft.Xna.GameStudio.ContentPipeline.targets" /> 48 62 <!-- To modify your build process, add your task inside one of the targets below and uncomment it. -
2017/27/OskariK/Pong/Pong/Pong/Pong.cs
r8832 r8863 74 74 void Aloitapeli() 75 75 { 76 Vector impulssi = new Vector( 1000.0, 0.0);76 Vector impulssi = new Vector(2000.0, 0.0); 77 77 pallo.Hit(impulssi); 78 78 }
Note: See TracChangeset
for help on using the changeset viewer.