- Timestamp:
- 2014-07-25 11:11:44 (9 years ago)
- Location:
- 2014/30/SimonG/OmaPeli2014
- Files:
-
- 4 added
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/OmaPeli2014.cs
r5619 r5668 13 13 Timer aikaLaskuri; 14 14 Image PelaajaKuva = LoadImage("Pelaaja123"); 15 Image TaustaKuva1 = LoadImage("TaustaKuva"); 16 Image HyokkaajanKuva = LoadImage("Zombie123"); 15 17 public override void Begin() 16 18 { … … 27 29 LuoHyokkaaja(); 28 30 LuoAikaLaskuri(); 29 30 // TODO - Background (!!2d camo background) (minecraft grass block top!!)31 // TODO - Alien Paint.Net32 31 33 32 Level.CreateBorders (); … … 35 34 36 35 Timer ajastin = new Timer(); 37 ajastin.Interval = 6. 9;36 ajastin.Interval = 6.0; 38 37 ajastin.Timeout += LuoHyokkaaja; 39 38 ajastin.Start(); 39 //Ennätys= 130,4sec (O) 40 Keyboard.Listen(Key.P, ButtonState.Pressed, Pause, "Pysäyttää pelin"); 40 41 41 42 Keyboard.Listen(Key.A, ButtonState.Down, LiikutaPelaajaa, null, new Vector(-1000, 0)); … … 43 44 Keyboard.Listen(Key.W, ButtonState.Down, LiikutaPelaajaa, null, new Vector(0, 1000)); 44 45 Keyboard.Listen(Key.S, ButtonState.Down, LiikutaPelaajaa, null, new Vector(0, -1000)); 45 46 Level.Background.Color = Color.DarkForestGreen;47 46 48 47 PhoneBackButton.Listen(ConfirmExit, "Lopeta peli"); … … 83 82 aikaNaytto.BindTo(aikaLaskuri.SecondCounter); 84 83 Add(aikaNaytto); 85 86 84 } 87 85 void Luokentta() … … 97 95 PelaajanAse.ProjectileCollision = AmmusOsui; 98 96 Pelaaja.Add(PelaajanAse); 99 PelaajanAse.AttackSound = null; 97 //PelaajanAse.AttackSound = null; 98 99 Level.Background.Image = TaustaKuva1; 100 100 101 101 Mouse.Listen (MouseButton.Left, ButtonState.Down, AmmuAseella, "Ammu", PelaajanAse); … … 110 110 SeuraajanAivot.Speed = 200; 111 111 SeuraajanAivot.DistanceFar = 8000; 112 SeuraajanAivot.DistanceClose = 55;112 SeuraajanAivot.DistanceClose = 62; 113 113 SeuraajanAivot.StopWhenTargetClose = false; 114 114 SeuraajanAivot.TargetClose += KunOllaanLahella; 115 115 SeuraajanAivot.Active = true; 116 116 117 117 PhysicsObject Hyokkaaja = new PhysicsObject(50, 50); 118 Hyokkaaja.Shape = Shape.Circle;119 Hyokkaaja.Color = Color.MediumPurple;120 118 Hyokkaaja.Tag = "Hyokkaaja"; 119 Hyokkaaja.Image = HyokkaajanKuva; 121 120 Add(Hyokkaaja); 122 121 Hyokkaaja.Brain = SeuraajanAivot; 123 SeuraajanAivot.Speed = 6 9;122 SeuraajanAivot.Speed = 68.9; 124 123 Hyokkaaja.LinearDamping = 0.9; 124 125 125 126 126 if (RandomGen.NextBool()) 127 127 { 128 Hyokkaaja.X = RandomGen.SelectOne(Level.Left , Level.Right);129 Hyokkaaja.Y = RandomGen.NextDouble(Level.Top , Level.Bottom);128 Hyokkaaja.X = RandomGen.SelectOne(Level.Left +50, Level.Right -50); 129 Hyokkaaja.Y = RandomGen.NextDouble(Level.Top -50, Level.Bottom +50); 130 130 } 131 131 else -
2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/OmaPeli2014.csproj.Debug.cachefile
r5619 r5668 1 1 Content\Pelaaja123.xnb 2 Content\TaustaKuva.xnb 3 Content\Zombie123.xnb -
2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/obj/x86/Debug/ContentPipeline-{BE2A82B7-4ED4-4853-BE88-99F6EE96FB2C}.xml
r5619 r5668 10 10 <Output>C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\Pelaaja123.xnb</Output> 11 11 <Time>2014-07-24T10:54:26.4214196+03:00</Time> 12 </Item> 13 <Item> 14 <Source>TaustaKuva.png</Source> 15 <Name>TaustaKuva</Name> 16 <Importer>TextureImporter</Importer> 17 <Processor>TextureProcessor</Processor> 18 <Options>None</Options> 19 <Output>C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\TaustaKuva.xnb</Output> 20 <Time>2014-07-25T09:24:10.496562+03:00</Time> 21 </Item> 22 <Item> 23 <Source>Zombie123.png</Source> 24 <Name>Zombie123</Name> 25 <Importer>TextureImporter</Importer> 26 <Processor>TextureProcessor</Processor> 27 <Options>None</Options> 28 <Output>C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\Zombie123.xnb</Output> 29 <Time>2014-07-25T09:34:39.3644425+03:00</Time> 12 30 </Item> 13 31 <BuildSuccessful>true</BuildSuccessful> -
2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/obj/x86/Debug/OmaPeli2014.csproj.FileListAbsolute.txt
r5619 r5668 8 8 C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\obj\x86\Debug\OmaPeli2014.pdb 9 9 C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\Pelaaja123.xnb 10 C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\TaustaKuva.xnb 11 C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\Zombie123.xnb -
2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/obj/x86/Debug/cachefile-{BE2A82B7-4ED4-4853-BE88-99F6EE96FB2C}-targetpath.txt
r5619 r5668 1 1 Content\Pelaaja123.xnb 2 Content\TaustaKuva.xnb 3 Content\Zombie123.xnb -
2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014Content/OmaPeli2014Content.contentproj
r5619 r5668 52 52 </Compile> 53 53 </ItemGroup> 54 <ItemGroup> 55 <Compile Include="TaustaKuva.png"> 56 <Name>TaustaKuva</Name> 57 <Importer>TextureImporter</Importer> 58 <Processor>TextureProcessor</Processor> 59 </Compile> 60 </ItemGroup> 61 <ItemGroup> 62 <Compile Include="Zombie123.png"> 63 <Name>Zombie123</Name> 64 <Importer>TextureImporter</Importer> 65 <Processor>TextureProcessor</Processor> 66 </Compile> 67 </ItemGroup> 54 68 <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\$(XnaFrameworkVersion)\Microsoft.Xna.GameStudio.ContentPipeline.targets" /> 55 69 <!-- 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.