Changeset 5668


Ignore:
Timestamp:
2014-07-25 11:11:44 (9 years ago)
Author:
sidatogr
Message:

Peli valmis

Location:
2014/30/SimonG/OmaPeli2014
Files:
4 added
11 edited

Legend:

Unmodified
Added
Removed
  • 2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/OmaPeli2014.cs

    r5619 r5668  
    1313    Timer aikaLaskuri; 
    1414    Image PelaajaKuva = LoadImage("Pelaaja123"); 
     15    Image TaustaKuva1 = LoadImage("TaustaKuva"); 
     16    Image HyokkaajanKuva = LoadImage("Zombie123"); 
    1517    public override void Begin() 
    1618    { 
     
    2729        LuoHyokkaaja(); 
    2830        LuoAikaLaskuri(); 
    29          
    30         // TODO - Background (!!2d camo background) (minecraft grass block top!!) 
    31         // TODO -  Alien Paint.Net 
    3231 
    3332        Level.CreateBorders (); 
     
    3534         
    3635        Timer ajastin = new Timer(); 
    37         ajastin.Interval = 6.9; 
     36        ajastin.Interval = 6.0; 
    3837        ajastin.Timeout += LuoHyokkaaja; 
    3938        ajastin.Start(); 
     39        //Ennätys= 130,4sec (O) 
     40        Keyboard.Listen(Key.P, ButtonState.Pressed, Pause, "Pysäyttää pelin"); 
    4041 
    4142        Keyboard.Listen(Key.A, ButtonState.Down, LiikutaPelaajaa, null, new Vector(-1000, 0)); 
     
    4344        Keyboard.Listen(Key.W, ButtonState.Down, LiikutaPelaajaa, null, new Vector(0, 1000)); 
    4445        Keyboard.Listen(Key.S, ButtonState.Down, LiikutaPelaajaa, null, new Vector(0, -1000)); 
    45          
    46         Level.Background.Color = Color.DarkForestGreen; 
    4746         
    4847        PhoneBackButton.Listen(ConfirmExit, "Lopeta peli"); 
     
    8382        aikaNaytto.BindTo(aikaLaskuri.SecondCounter); 
    8483        Add(aikaNaytto); 
    85  
    8684    } 
    8785    void Luokentta() 
     
    9795        PelaajanAse.ProjectileCollision = AmmusOsui; 
    9896        Pelaaja.Add(PelaajanAse); 
    99         PelaajanAse.AttackSound = null; 
     97        //PelaajanAse.AttackSound = null; 
     98 
     99        Level.Background.Image = TaustaKuva1; 
    100100         
    101101        Mouse.Listen (MouseButton.Left, ButtonState.Down, AmmuAseella, "Ammu", PelaajanAse); 
     
    110110            SeuraajanAivot.Speed = 200; 
    111111            SeuraajanAivot.DistanceFar = 8000; 
    112             SeuraajanAivot.DistanceClose = 55; 
     112            SeuraajanAivot.DistanceClose = 62; 
    113113            SeuraajanAivot.StopWhenTargetClose = false; 
    114114            SeuraajanAivot.TargetClose += KunOllaanLahella; 
    115115            SeuraajanAivot.Active = true; 
    116              
     116 
    117117            PhysicsObject Hyokkaaja = new PhysicsObject(50, 50); 
    118             Hyokkaaja.Shape = Shape.Circle; 
    119             Hyokkaaja.Color = Color.MediumPurple; 
    120118            Hyokkaaja.Tag = "Hyokkaaja"; 
     119            Hyokkaaja.Image = HyokkaajanKuva; 
    121120            Add(Hyokkaaja); 
    122121            Hyokkaaja.Brain = SeuraajanAivot; 
    123             SeuraajanAivot.Speed = 69; 
     122            SeuraajanAivot.Speed = 68.9; 
    124123            Hyokkaaja.LinearDamping = 0.9; 
     124 
    125125             
    126126            if (RandomGen.NextBool()) 
    127127            { 
    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); 
    130130            } 
    131131            else 
  • 2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/OmaPeli2014.csproj.Debug.cachefile

    r5619 r5668  
    11Content\Pelaaja123.xnb 
     2Content\TaustaKuva.xnb 
     3Content\Zombie123.xnb 
  • 2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/obj/x86/Debug/ContentPipeline-{BE2A82B7-4ED4-4853-BE88-99F6EE96FB2C}.xml

    r5619 r5668  
    1010      <Output>C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\Pelaaja123.xnb</Output> 
    1111      <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> 
    1230    </Item> 
    1331    <BuildSuccessful>true</BuildSuccessful> 
  • 2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014/obj/x86/Debug/OmaPeli2014.csproj.FileListAbsolute.txt

    r5619 r5668  
    88C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\obj\x86\Debug\OmaPeli2014.pdb 
    99C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\Pelaaja123.xnb 
     10C:\MyTemp\SimonG\OmaPeli2014\OmaPeli2014\OmaPeli2014\bin\x86\Debug\Content\TaustaKuva.xnb 
     11C:\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  
    11Content\Pelaaja123.xnb 
     2Content\TaustaKuva.xnb 
     3Content\Zombie123.xnb 
  • 2014/30/SimonG/OmaPeli2014/OmaPeli2014/OmaPeli2014Content/OmaPeli2014Content.contentproj

    r5619 r5668  
    5252    </Compile> 
    5353  </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> 
    5468  <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\$(XnaFrameworkVersion)\Microsoft.Xna.GameStudio.ContentPipeline.targets" /> 
    5569  <!--  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.