Changeset 1171 for 2010/27


Ignore:
Timestamp:
2010-07-08 11:08:03 (10 years ago)
Author:
vekakart
Message:

Lisäsin Pelaajan kuvan ja myös maali esineet.

Location:
2010/27/Vekakart/Catch The Rainbow
Files:
4 added
3 edited

Legend:

Unmodified
Added
Removed
  • 2010/27/Vekakart/Catch The Rainbow/Catch The Rainbow/Catch The Rainbow.csproj

    r1156 r1171  
    8484    <Compile Include="Properties\AssemblyInfo.cs" /> 
    8585    <Compile Include="Ohjelma.cs" /> 
    86     <Compile Include="Peli.cs" /> 
     86    <Compile Include="Peli.cs"> 
     87      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 
     88    </Compile> 
    8789  </ItemGroup> 
    8890  <ItemGroup> 
     
    9092    <Content Include="GameThumbnail.png" /> 
    9193    <Content Include="Kentta1.txt"> 
     94      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 
     95    </Content> 
     96    <Content Include="Max Mechanic.png"> 
     97      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 
     98    </Content> 
     99    <Content Include="Max Mechanic2.png"> 
     100      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 
     101    </Content> 
     102    <Content Include="Rainbow.png"> 
    92103      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> 
    93104    </Content> 
  • 2010/27/Vekakart/Catch The Rainbow/Catch The Rainbow/Peli.cs

    r1156 r1171  
    1212    Vector NopeusEteen = new Vector(200, 0); 
    1313 
    14     PlatformCharacter Chandler; 
     14    PlatformCharacter Max; 
    1515 
    1616    protected override void Begin() 
    1717    { 
    18         LuoChandler(); 
     18        LuoMax(); 
    1919        AsetaOhjaimet(); 
    2020        LuoKentta(); 
     
    2323    void LuoKentta() 
    2424    { 
    25         Camera.FollowedObject = Chandler; 
     25        Camera.FollowedObject = Max; 
    2626 
    2727        TileMap ruudut = TileMap.FromFile("Kentta1.txt"); 
     
    4242    { 
    4343        PhysicsObject Rainbow = PhysicsObject.CreateStaticObject(25, 25); 
    44        Rainbow.Image = Image.FromFile (" 
     44        Rainbow.Image = Image.FromFile("Rainbow.png"); 
    4545        return Rainbow; 
    4646    } 
    4747 
    48     void LuoChandler() 
     48    void LuoMax() 
    4949    { 
    50         Chandler = new PlatformCharacter(20,45); 
    51         Chandler.Restitution = 0.0; 
    52         Chandler.CanRotate = false; 
    53         Chandler.X = -450; 
    54         Chandler.Y = -365; 
    55         Chandler.KineticFriction = 0.0; 
    56         Add (Chandler); 
     50        Max = new PlatformCharacter(35,45); 
     51        Max.Restitution = 0.0; 
     52        Max.CanRotate = false; 
     53        Max.X = -450; 
     54        Max.Y = -365; 
     55        Max.Image = Image.FromFile("Max Mechanic.png"); 
     56        Max.KineticFriction = 0.0; 
     57        Add (Max); 
    5758        return; 
    5859    } 
     
    7273    void PelaajaLiikuEteenpain() 
    7374    { 
    74         Chandler.Walk(200); 
     75        Max.Walk(300); 
     76        Max.Image = Image.FromFile("Max Mechanic.png"); 
    7577    } 
    7678 
    7779    void PelaajaLiikuTaakse() 
    7880    { 
    79         Chandler.Walk (-200); 
     81        Max.Walk (-300); 
     82        Max.Image = Image.FromFile("max mechanic2.png"); 
    8083    } 
    8184 
     
    8790    void PelaajaHypaa() 
    8891    { 
    89         Chandler.Jump(1000); 
     92        Max.Jump(1000); 
    9093    } 
    9194} 
Note: See TracChangeset for help on using the changeset viewer.