Changeset 6778


Ignore:
Timestamp:
2015-07-03 11:25:36 (8 years ago)
Author:
jasukuva
Message:
 
Location:
2015/27/JaakkoS/Tikku
Files:
17 added
21 edited

Legend:

Unmodified
Added
Removed
  • 2015/27/JaakkoS/Tikku/Tikku/Tikku/Tikku.cs

    r6765 r6778  
    2828 
    2929    Image pelaajanKuva = LoadImage("Pelaaja"); 
    30     Image tahtiKuva = LoadImage("tahti"); 
     30    Image tahtiKuva = LoadImage("aarre"); 
    3131    Image vihuKuva = LoadImage("AUTO"); 
    3232    Image kynaKuva = LoadImage("kyna"); 
    3333    Image MaaKuva = LoadImage("Maa"); 
    3434    Image palikkaKuva = LoadImage("palikka"); 
     35    Image Loppukuva = LoadImage("Loppu"); 
    3536 
    3637    SoundEffect maaliAani = LoadSoundEffect("maali"); 
     38    SoundEffect kynaAani = LoadSoundEffect("Health"); 
     39    SoundEffect auts = LoadSoundEffect("Auts"); 
     40    SoundEffect kuoleAani = LoadSoundEffect("Kuole"); 
     41 
    3742    bool onmenettanytenergiaa = false; 
    3843 
     
    191196        Keyboard.Listen(Key.F1, ButtonState.Pressed, ShowControlHelp, "Näytä ohjeet"); 
    192197        Keyboard.Listen(Key.Escape, ButtonState.Pressed, ConfirmExit, "Lopeta peli"); 
    193  
    194198         
    195199 
     200 
    196201        if (pelaajia == 2) 
    197202        { 
    198203            Keyboard.Listen(Key.Right, ButtonState.Down, Liikuta, "Liikkuu oikalle", pelaaja1, nopeus); 
    199             Keyboard.Listen(Key.A, ButtonState.Down, Liikuta, "Liikkuu vasemmalle", pelaaja1, nopeus); 
     204            Keyboard.Listen(Key.A, ButtonState.Down, Liikuta, "Liikkuu vasemmalle", pelaaja1, -nopeus); 
    200205            Keyboard.Listen(Key.Space, ButtonState.Pressed, Hyppaa, "Pelaaja hyppää", pelaaja1, hyppyNopeus); 
    201206 
     
    211216        { 
    212217            Keyboard.Listen(Key.D, ButtonState.Down, Liikuta, "Liikkuu oikalle", pelaaja1, nopeus); 
    213             Keyboard.Listen(Key.A, ButtonState.Down, Liikuta, "Liikkuu vasemmalle", pelaaja1, nopeus); 
     218            Keyboard.Listen(Key.A, ButtonState.Down, Liikuta, "Liikkuu vasemmalle", pelaaja1, -nopeus); 
    214219            Keyboard.Listen(Key.Space, ButtonState.Pressed, Hyppaa, "Pelaaja hyppää", pelaaja1, hyppyNopeus); 
    215220 
     
    251256            elamalaskuri.Value++; 
    252257            LisaaYksiUusiSydan(); 
     258            kynaAani.Play(); 
    253259        } 
    254260    } 
     
    266272    void Kuole(PhysicsObject hahmo, PhysicsObject vihu) 
    267273    { 
     274 
    268275        if (onmenettanytenergiaa == false) 
    269276        { 
    270277            if (elamalaskuri.Value >= 0 || pelaajansydammet[elamalaskuri.Value] != null) 
    271278            { 
     279                 
    272280                elamalaskuri.Value--; 
    273281                onmenettanytenergiaa = true; 
    274282                Timer.SingleShot(0.1, delegate { onmenettanytenergiaa = false; }); 
    275283                pelaajansydammet[elamalaskuri.Value].Destroy(); 
     284                auts.Play(); 
    276285            } 
    277286            if (elamalaskuri.Value < 1) 
     
    281290                Timer.SingleShot(3.0, SeuraavaKentta); 
    282291                pelaajansydammet.Clear(); 
     292                kuoleAani.Play(); 
    283293            } 
    284294        } 
     295 
    285296 
    286297    } 
     
    323334 
    324335        if (kenttaNro == 1) LuoKentta("kentta1"); 
     336        if (kenttaNro == 1) MessageDisplay.Add("Lähdet etsimään tarun hohtoista aarretta... No mene jo!"); 
    325337        else if (kenttaNro == 2) LuoKentta("kentta2"); 
     338        if (kenttaNro == 2) MessageDisplay.Add("Huhuh. Oliko rankkaa :D? AI EIKÖ VAI..."); 
    326339        else if (kenttaNro == 3) LuoKentta("kentta3"); 
    327         else if (kenttaNro == 4) MessageDisplay.Add("Voitit pelin"); 
    328         if (kenttaNro == 4) Timer.SingleShot(3.0, Exit); 
     340        else if (kenttaNro == 4) LuoKentta("kentta4"); 
     341        if (kenttaNro == 4) MessageDisplay.Add("NO OLIKO NYT RANKKAA?!"); 
     342        else if (kenttaNro == 5) MessageDisplay.Add("Noh löysit aarteen. Onko nyt hyvä mieli? -_-*"); 
     343        if (kenttaNro == 5) Timer.SingleShot(3.0, Exit); 
    329344 
    330345 
  • 2015/27/JaakkoS/Tikku/Tikku/Tikku/Tikku.csproj.Debug.cachefile

    r6765 r6778  
    55Content\AUTO.xnb 
    66Content\kyna.xnb 
     7Content\palikka.xnb 
     8Content\Maa.xnb 
    79Content\kentta1.xnb 
    810Content\kentta2.xnb 
    911Content\kentta3.xnb 
    10 Content\palikka.xnb 
    11 Content\Maa.xnb 
     12Content\Health.xnb 
     13Content\Auts.xnb 
     14Content\Kuole.xnb 
     15Content\Loppu.xnb 
     16Content\kentta4.xnb 
    1217Content\kentta2.txt 
  • 2015/27/JaakkoS/Tikku/Tikku/Tikku/obj/x86/Debug/ContentPipeline-{70F78017-3504-40A5-864B-07486E7AEB1B}.xml

    r6682 r6778  
    99      <Options>None</Options> 
    1010      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\maali.xnb</Output> 
    11       <Time>2015-06-30T10:53:55.6624362+03:00</Time> 
     11      <Time>2015-07-03T09:20:58.7322002+03:00</Time> 
    1212    </Item> 
    1313    <Item> 
     
    1818      <Options>None</Options> 
    1919      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\norsu.xnb</Output> 
    20       <Time>2015-06-30T10:53:55.6634362+03:00</Time> 
     20      <Time>2015-07-03T09:20:58.8102007+03:00</Time> 
    2121    </Item> 
    2222    <Item> 
     
    2727      <Options>None</Options> 
    2828      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\tahti.xnb</Output> 
    29       <Time>2015-06-30T10:53:55.6654362+03:00</Time> 
     29      <Time>2015-07-03T09:20:58.8726011+03:00</Time> 
     30    </Item> 
     31    <Item> 
     32      <Source>Pelaaja.png</Source> 
     33      <Name>Pelaaja</Name> 
     34      <Importer>TextureImporter</Importer> 
     35      <Processor>TextureProcessor</Processor> 
     36      <Options>None</Options> 
     37      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Pelaaja.xnb</Output> 
     38      <Time>2015-07-03T09:55:24.4766557+03:00</Time> 
     39    </Item> 
     40    <Item> 
     41      <Source>AUTO.png</Source> 
     42      <Name>AUTO</Name> 
     43      <Importer>TextureImporter</Importer> 
     44      <Processor>TextureProcessor</Processor> 
     45      <Options>None</Options> 
     46      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\AUTO.xnb</Output> 
     47      <Time>2015-07-03T09:31:17.8096781+03:00</Time> 
     48    </Item> 
     49    <Item> 
     50      <Source>kyna.png</Source> 
     51      <Name>kyna</Name> 
     52      <Importer>TextureImporter</Importer> 
     53      <Processor>TextureProcessor</Processor> 
     54      <Options>None</Options> 
     55      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\kyna.xnb</Output> 
     56      <Time>2015-07-03T09:20:58.7478003+03:00</Time> 
     57    </Item> 
     58    <Item> 
     59      <Source>palikka.png</Source> 
     60      <Name>palikka</Name> 
     61      <Importer>TextureImporter</Importer> 
     62      <Processor>TextureProcessor</Processor> 
     63      <Options>None</Options> 
     64      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\palikka.xnb</Output> 
     65      <Time>2015-07-03T09:20:58.7322002+03:00</Time> 
     66    </Item> 
     67    <Item> 
     68      <Source>Maa.png</Source> 
     69      <Name>Maa</Name> 
     70      <Importer>TextureImporter</Importer> 
     71      <Processor>TextureProcessor</Processor> 
     72      <Options>None</Options> 
     73      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Maa.xnb</Output> 
     74      <Time>2015-07-03T09:20:58.7478003+03:00</Time> 
    3075    </Item> 
    3176    <Item> 
     
    3681      <Options>None</Options> 
    3782      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\kentta1.xnb</Output> 
    38       <Time>2015-07-01T14:47:28.7754785+03:00</Time> 
    39     </Item> 
    40     <Item> 
    41       <Source>Pelaaja.png</Source> 
    42       <Name>Pelaaja</Name> 
    43       <Importer>TextureImporter</Importer> 
    44       <Processor>TextureProcessor</Processor> 
    45       <Options>None</Options> 
    46       <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Pelaaja.xnb</Output> 
    47       <Time>2015-06-30T11:23:49.3804362+03:00</Time> 
     83      <Time>2015-07-03T09:20:58.7478003+03:00</Time> 
    4884    </Item> 
    4985    <Item> 
     
    5490      <Options>None</Options> 
    5591      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\kentta2.xnb</Output> 
    56       <Time>2015-07-01T13:50:39.9144785+03:00</Time> 
     92      <Time>2015-07-03T09:20:58.7634004+03:00</Time> 
    5793    </Item> 
    5894    <Item> 
    59       <Source>AUTO.png</Source> 
    60       <Name>AUTO</Name> 
     95      <Source>kentta3.txt</Source> 
     96      <Name>kentta3</Name> 
     97      <Importer>TextFileImporter</Importer> 
     98      <Processor>TextFileContentProcessor</Processor> 
     99      <Options>None</Options> 
     100      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\kentta3.xnb</Output> 
     101      <Time>2015-07-03T09:35:24.7838691+03:00</Time> 
     102    </Item> 
     103    <Item> 
     104      <Source>Health.wav</Source> 
     105      <Name>Health</Name> 
     106      <Importer>WavImporter</Importer> 
     107      <Processor>SoundEffectProcessor</Processor> 
     108      <Options>None</Options> 
     109      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Health.xnb</Output> 
     110      <Time>2015-07-03T09:38:39.6879494+03:00</Time> 
     111    </Item> 
     112    <Item> 
     113      <Source>Auts.wav</Source> 
     114      <Name>Auts</Name> 
     115      <Importer>WavImporter</Importer> 
     116      <Processor>SoundEffectProcessor</Processor> 
     117      <Options>None</Options> 
     118      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Auts.xnb</Output> 
     119      <Time>2015-07-03T09:42:14.3021578+03:00</Time> 
     120    </Item> 
     121    <Item> 
     122      <Source>Kuole.wav</Source> 
     123      <Name>Kuole</Name> 
     124      <Importer>WavImporter</Importer> 
     125      <Processor>SoundEffectProcessor</Processor> 
     126      <Options>None</Options> 
     127      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Kuole.xnb</Output> 
     128      <Time>2015-07-03T09:47:16.4837186+03:00</Time> 
     129    </Item> 
     130    <Item> 
     131      <Source>Loppu.png</Source> 
     132      <Name>Loppu</Name> 
    61133      <Importer>TextureImporter</Importer> 
    62134      <Processor>TextureProcessor</Processor> 
    63135      <Options>None</Options> 
    64       <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\AUTO.xnb</Output> 
    65       <Time>2015-07-01T10:43:14.7324785+03:00</Time> 
     136      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Loppu.xnb</Output> 
     137      <Time>2015-07-03T10:06:19.1784953+03:00</Time> 
    66138    </Item> 
    67139    <Item> 
    68       <Source>kyna.png</Source> 
    69       <Name>kyna</Name> 
    70       <Importer>TextureImporter</Importer> 
    71       <Processor>TextureProcessor</Processor> 
     140      <Source>kentta4.txt</Source> 
     141      <Name>kentta4</Name> 
     142      <Importer>TextFileImporter</Importer> 
     143      <Processor>TextFileContentProcessor</Processor> 
    72144      <Options>None</Options> 
    73       <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\kyna.xnb</Output> 
    74       <Time>2015-07-01T12:27:08.9624785+03:00</Time> 
     145      <Output>C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\kentta4.xnb</Output> 
     146      <Time>2015-07-03T10:57:12.9161983+03:00</Time> 
    75147    </Item> 
    76148    <BuildSuccessful>true</BuildSuccessful> 
     
    121193      <Assembly> 
    122194        <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> 
    123         <Value>2014-04-23T01:01:53.8831999+03:00</Value> 
     195        <Value>2014-05-02T09:58:16.3807377+03:00</Value> 
    124196      </Assembly> 
    125197    </Assemblies> 
  • 2015/27/JaakkoS/Tikku/Tikku/Tikku/obj/x86/Debug/Tikku.csproj.FileListAbsolute.txt

    r6765 r6778  
    1919C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\palikka.xnb 
    2020C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Maa.xnb 
     21C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Health.xnb 
     22C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Auts.xnb 
     23C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Kuole.xnb 
     24C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\Loppu.xnb 
     25C:\MyTemp\JaakkoS\Tikku\Tikku\Tikku\bin\x86\Debug\Content\kentta4.xnb 
  • 2015/27/JaakkoS/Tikku/Tikku/Tikku/obj/x86/Debug/cachefile-{70F78017-3504-40A5-864B-07486E7AEB1B}-targetpath.txt

    r6765 r6778  
    55Content\AUTO.xnb 
    66Content\kyna.xnb 
     7Content\palikka.xnb 
     8Content\Maa.xnb 
    79Content\kentta1.xnb 
    810Content\kentta2.xnb 
    911Content\kentta3.xnb 
    10 Content\palikka.xnb 
    11 Content\Maa.xnb 
     12Content\Health.xnb 
     13Content\Auts.xnb 
     14Content\Kuole.xnb 
     15Content\Loppu.xnb 
     16Content\kentta4.xnb 
    1217Content\kentta2.txt 
  • 2015/27/JaakkoS/Tikku/Tikku/TikkuContent/TikkuContent.contentproj

    r6765 r6778  
    6868  </ItemGroup> 
    6969  <ItemGroup> 
    70     <Compile Include="Pelaaja.png"> 
    71       <Name>Pelaaja</Name> 
    72       <Importer>TextureImporter</Importer> 
    73       <Processor>TextureProcessor</Processor> 
    74     </Compile> 
    75   </ItemGroup> 
    76   <ItemGroup> 
    7770    <Compile Include="kentta2.txt"> 
    7871      <Name>kentta2</Name> 
     
    8073      <Processor>TextFileContentProcessor</Processor> 
    8174      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 
    82     </Compile> 
    83   </ItemGroup> 
    84   <ItemGroup> 
    85     <Compile Include="AUTO.png"> 
    86       <Name>AUTO</Name> 
    87       <Importer>TextureImporter</Importer> 
    88       <Processor>TextureProcessor</Processor> 
    8975    </Compile> 
    9076  </ItemGroup> 
     
    117103    </Compile> 
    118104  </ItemGroup> 
     105  <ItemGroup> 
     106    <Compile Include="AUTO.png"> 
     107      <Name>AUTO</Name> 
     108      <Importer>TextureImporter</Importer> 
     109      <Processor>TextureProcessor</Processor> 
     110    </Compile> 
     111  </ItemGroup> 
     112  <ItemGroup> 
     113    <Compile Include="Health.wav"> 
     114      <Name>Health</Name> 
     115      <Importer>WavImporter</Importer> 
     116      <Processor>SoundEffectProcessor</Processor> 
     117    </Compile> 
     118  </ItemGroup> 
     119  <ItemGroup> 
     120    <Compile Include="Auts.wav"> 
     121      <Name>Auts</Name> 
     122      <Importer>WavImporter</Importer> 
     123      <Processor>SoundEffectProcessor</Processor> 
     124    </Compile> 
     125  </ItemGroup> 
     126  <ItemGroup> 
     127    <Compile Include="Kuole.wav"> 
     128      <Name>Kuole</Name> 
     129      <Importer>WavImporter</Importer> 
     130      <Processor>SoundEffectProcessor</Processor> 
     131    </Compile> 
     132  </ItemGroup> 
     133  <ItemGroup> 
     134    <Compile Include="Pelaaja.png"> 
     135      <Name>Pelaaja</Name> 
     136      <Importer>TextureImporter</Importer> 
     137      <Processor>TextureProcessor</Processor> 
     138    </Compile> 
     139  </ItemGroup> 
     140  <ItemGroup> 
     141    <Compile Include="Loppu.png"> 
     142      <Name>Loppu</Name> 
     143      <Importer>TextureImporter</Importer> 
     144      <Processor>TextureProcessor</Processor> 
     145    </Compile> 
     146  </ItemGroup> 
     147  <ItemGroup> 
     148    <Compile Include="kentta4.txt"> 
     149      <Name>kentta4</Name> 
     150      <Importer>TextFileImporter</Importer> 
     151      <Processor>TextFileContentProcessor</Processor> 
     152    </Compile> 
     153  </ItemGroup> 
     154  <ItemGroup> 
     155    <Compile Include="aarre.png"> 
     156      <Name>aarre</Name> 
     157      <Importer>TextureImporter</Importer> 
     158      <Processor>TextureProcessor</Processor> 
     159    </Compile> 
     160  </ItemGroup> 
    119161  <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\$(XnaFrameworkVersion)\Microsoft.Xna.GameStudio.ContentPipeline.targets" /> 
    120162  <!--  To modify your build process, add your task inside one of the targets below and uncomment it.  
  • 2015/27/JaakkoS/Tikku/Tikku/TikkuContent/kentta3.txt

    r6765 r6778  
    22................................................................................ 
    33................................................................................ 
    4 ................................................................................ 
    5 *............................................................................... 
    6 !!!!.................V...K...V.................................................. 
    7 ....................###..!..###................................................. 
    8 .........V...................................................................... 
     4*...........................................................................!... 
     5............................................................................!... 
     6.....................V...K...V..............................................!... 
     7....................###..!..###.............................................!... 
     8.........V..................................................................!... 
    99........#####.......................K.................V................!!!!!#### 
    1010......##########...................##.............K..###..K.................#..# 
Note: See TracChangeset for help on using the changeset viewer.