- Timestamp:
- 2012-06-14 13:30:25 (11 years ago)
- Location:
- 2012/24/LeeviL
- Files:
-
- 3 added
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
2012/24/LeeviL/Rangoneina/Rangoneina/Rangoneina/Rangoneina.cs
r3016 r3018 16 16 Image Vih3I = LoadImage("Vih3"); 17 17 PhysicsObject Rekuroka; 18 PhysicsObject Serunom; 18 19 PhysicsObject Merinoma; 19 20 IntMeter Pistelaskuri; 21 int kenttaNro = 1; 20 22 public override void Begin() 21 23 { … … 24 26 Add(valikko); 25 27 26 LuoKentta(); 27 AsetaOhjaimet(); 28 28 29 29 30 30 31 } 31 32 32 void LuoKentta( )33 { 34 TileMap ruudut = TileMap.FromLevelAsset( "Kentta1");33 void LuoKentta(string KenttaTiedosto) 34 { 35 TileMap ruudut = TileMap.FromLevelAsset(KenttaTiedosto); 35 36 ruudut.SetTileMethod('=', LuoPalikka); 36 37 ruudut.SetTileMethod('T', LuoTahti); … … 39 40 ruudut.SetTileMethod('3', Vih3); 40 41 ruudut.SetTileMethod('R', LuoRekuroka); 41 ruudut.SetTileMethod('S', Serunom);42 ruudut.SetTileMethod('S', LuoSerunom); 42 43 ruudut.SetTileMethod('M', LuoMerinoma); 43 44 ruudut.SetTileMethod('W', LuoPiste); … … 55 56 { 56 57 ClearAll(); 58 59 AsetaOhjaimet(); 60 61 if (kenttaNro == 1) LuoKentta("Kentta1"); 62 else if (kenttaNro == 2) LuoKentta("Kentta2"); 63 else if (kenttaNro == 3) LuoKentta("Kentta3"); 64 else if (kenttaNro > 3) Exit(); 65 66 57 67 } 58 68 … … 66 76 AddCollisionHandler(Rekuroka, "LuoPiste", Tormays2); 67 77 AddCollisionHandler(Rekuroka, "Kuolema", Tormays3); 78 AddCollisionHandler(Rekuroka, "UusiKentta", Tormays4); 68 79 Add(Rekuroka); 69 80 } 70 81 71 void Serunom(Vector paikka, double leveys, double korkeus)72 { 73 PhysicsObjectSerunom = new PhysicsObject(leveys, korkeus);82 void LuoSerunom(Vector paikka, double leveys, double korkeus) 83 { 84 Serunom = new PhysicsObject(leveys, korkeus); 74 85 Serunom.Image = SerunomI; 75 86 Serunom.Restitution = 0.0; 76 87 Serunom.Position = paikka; 88 Serunom.Tag = "UusiKentta"; 77 89 Add(Serunom); 78 90 } … … 119 131 PhysicsObject palikka = PhysicsObject.CreateStaticObject(leveys, korkeus); 120 132 palikka.Shape = Shape.Rectangle; 121 palikka.Color = Color. Black;133 palikka.Color = Color.Green; 122 134 palikka.Restitution = 0.0; 123 135 palikka.Position = paikka; 136 palikka.CollisionIgnoreGroup = 1; 124 137 Add(palikka); 125 138 } … … 180 193 } 181 194 195 void Tormays4(IPhysicsObject Rekuroka, IPhysicsObject kohde) 196 { 197 if (kohde == Serunom) 198 { 199 kenttaNro++; 200 SeuraavaKentta(kenttaNro); 201 } 202 } 203 182 204 void PainettiinValikkoNappia(int valinta) 183 205 { … … 185 207 { 186 208 case 0: 187 //AloitaPeli();209 SeuraavaKentta(kenttaNro); 188 210 break; 189 211 case 1: … … 227 249 { 228 250 ClearAll(); 229 LuoKentta(); 230 AsetaOhjaimet(); 251 SeuraavaKentta(kenttaNro); 231 252 } 232 253 } -
2012/24/LeeviL/Rangoneina/Rangoneina/Rangoneina/Rangoneina.csproj.Debug.cachefile
r3016 r3018 7 7 Content\Kentta1.xnb 8 8 Content\Kentta2.xnb 9 Content\Kentta3.xnb 9 10 Content\Kentta1.txt -
2012/24/LeeviL/Rangoneina/Rangoneina/Rangoneina/obj/x86/Debug/ContentPipeline-{43DDB7A9-921D-4BF9-A5DD-4CA1D9C85B38}.xml
r3016 r3018 63 63 <Options>None</Options> 64 64 <Output>C:\MyTemp\LeeviL2\Rangoneina\Rangoneina\Rangoneina\bin\x86\Debug\Content\Kentta1.xnb</Output> 65 <Time>2012-06-14T1 0:40:11.2096025+03:00</Time>65 <Time>2012-06-14T13:09:40.9164614+03:00</Time> 66 66 </Item> 67 67 <Item> … … 72 72 <Options>None</Options> 73 73 <Output>C:\MyTemp\LeeviL2\Rangoneina\Rangoneina\Rangoneina\bin\x86\Debug\Content\Kentta2.xnb</Output> 74 <Time>2012-06-14T10:46:41.9170607+03:00</Time> 74 <Time>2012-06-14T13:16:10.9954614+03:00</Time> 75 </Item> 76 <Item> 77 <Source>Kentta3.txt</Source> 78 <Name>Kentta3</Name> 79 <Importer>TextFileImporter</Importer> 80 <Processor>TextFileContentProcessor</Processor> 81 <Options>None</Options> 82 <Output>C:\MyTemp\LeeviL2\Rangoneina\Rangoneina\Rangoneina\bin\x86\Debug\Content\Kentta3.xnb</Output> 83 <Time>2012-06-14T13:16:10.8334614+03:00</Time> 75 84 </Item> 76 85 <BuildSuccessful>true</BuildSuccessful> -
2012/24/LeeviL/Rangoneina/Rangoneina/Rangoneina/obj/x86/Debug/Rangoneina.csproj.FileListAbsolute.txt
r3016 r3018 32 32 C:\MyTemp\LeeviL2\Rangoneina\Rangoneina\Rangoneina\obj\x86\Debug\Rangoneina.pdb 33 33 C:\MyTemp\LeeviL2\Rangoneina\Rangoneina\Rangoneina\bin\x86\Debug\Content\Kentta2.xnb 34 C:\MyTemp\LeeviL2\Rangoneina\Rangoneina\Rangoneina\bin\x86\Debug\Content\Kentta3.xnb -
2012/24/LeeviL/Rangoneina/Rangoneina/Rangoneina/obj/x86/Debug/cachefile-{43DDB7A9-921D-4BF9-A5DD-4CA1D9C85B38}-targetpath.txt
r3016 r3018 7 7 Content\Kentta1.xnb 8 8 Content\Kentta2.xnb 9 Content\Kentta3.xnb 9 10 Content\Kentta1.txt -
2012/24/LeeviL/Rangoneina/Rangoneina/RangoneinaContent/Kentta2.txt
r3016 r3018 1 1 ====================================================================================================================== 2 ================ = ==========================================================================================2 ================ = = 3 3 == =========================================================================================== 4 == ======= ================ ==5 == ========== = = ==================6 == == == = = = ================ ====== ==================== ============ ==7 == == ==== == = ==== ================ ====== ==================== ============ ==8 == ======== == = = =============== ================ ============ ==9 == == = = =============== == ============== ==============4 == R ======= = = == 5 == ========== 3 = W= = = 3 == 6 == == == = = = = ====== ==================== ============ == 7 == ==T == = ==== = = ====== ==================== ============ == 8 == ======== == = = = ==T T ============== ============ == 9 == == = = = == ============== ============ M M == 10 10 == == ========================= == ================== ================== == 11 ================ = ======================== == ================== ================== ==12 ================ = ======================== == ================== ====================13 ================ = ======================== == ================== ================== ==14 ================ = ======================== == ====== ====================15 ================ = ======================== == ======================== ==16 ================ ========================= ========================================== 17 == 18 == ======= ======================= ==11 ================ = = == ================== ================== == 12 ================ = = == ================== ================== M == 13 ================ = = == ================== ================== == 14 ================ = = == W ======M ================== M == 15 ================ = = == ======M ================== == 16 ================ ========================= ========================================== M == 17 == W======= ================== ===== == 18 == ======= 3 ================== 2 ===== == 19 19 == === ===== ======================================================= ===== == 20 == === ===== ======================================== =============== =======21 ================ ===== ====== ================ ===== ==22 ================ ===== ====== = =============== ===== ==23 ================ ===== ====== ============================= = =============== ===== ==24 ========== ==== ===== ====== ============================= ================ =======25 ========== ==== ===== ====== = ============================ ================ ===== ==26 ========== ===== ====== = ============================ ================ ===== ==27 ========== ===== ====== ============================= ===================== ==28 ===================== ====== = ============================ ================ ===== ==29 == ================= ====== ============================= ================ =======30 == ================= ======== = ============================ ================ ===== ==31 == ======== ============================= ================ ===== ==32 == ======== = ============================ ================ ===== ==33 ====== ============= ======== = ============================ ================ ===== ==34 ====== ============= ======== ============================= = =============== ===== ==35 ====== ============= ===================== ================ =======36 ===================== ===================== ================ =======37 ============================= ========= ==================== ================ ===== ==38 ============================= ====================== ================ ===== ==39 ============================= === ===================== ================ ===== ==40 ============================= ======================== ======================= ====================================41 ======= ============================= ======================= ====================================42 ======= = ============================ ======================= ====================================43 ======= =============== = ============================ ======================= ====================================44 ======= ====== ======= ============================= ======================= ====================================45 ======= ====== ======= = ============================ ======================= ====================================46 ======= === === ============================= ======================= ====================================47 ======= === === ============================= ======================= ====================================48 ======= ====== ======= = ============================ ======================= ====================================49 ======= ====== ======= ============================= = ====================== ====================================50 ======= ====== ======= = ====================== ====================================51 ======= ====== ======= ======================= ====================================52 ======= ====== =============================================================== = ===================================53 ======= ====================================54 ======= = ===================================20 == === ===== ======================================== = ===== M == 21 ================ ===== ======1 = = ===== == 22 ================ ===== ====== = = ===== == 23 ================ ===== ====== ============================= = = ===== == 24 ==========M==== ===== ====== = = = = ===== M == 25 ========== ==== ===== ====== = = = = ===== == 26 ========== ===== ====== = = = = ===== == 27 ========== M ===== ====== = = = = 3===== == 28 ===================== ====== = = = = ===== == 29 == W================= ====== = = = = ===== M M == 30 == ================= ======== = = = = ===== == 31 == 2 ======== = = = = ===== == 32 == ======== = = = = ===== == 33 ====== ============= ======== = = = = ===== == 34 ====== ============= ======== ============================= = = ===== == 35 ======T ============= = = = = ===== M == 36 ===================== 2 T= = = = ===== S == 37 ============================= ========= ======== = = ===== == 38 ============================= M= = 3 = = ===== == 39 ============================= === = = = ===== == 40 ============================= M= = ======================= ==================================== 41 ======= T ====== = = = = = 42 ======= = = = = = = 43 ======= =============== = = = = = = 44 ======= ====== T======= = = = = = = 45 ======= ====== ======= = = = = = = 46 ======= ===M === = = = = = = 47 ======= === T=== = = = = = = 48 ======= ====== ======= = = = = = = 49 ======= ====== ======= ============================= = = = = 50 ======= ====== ======= = = = = 51 ======= ====== ======= 3 = = = = 52 ======= ====== =============================================================== = = 53 ======= 1 2 3 = = 54 ======= = = 55 55 ====================================================================================================================== 56 ====================================================================================================================== 56 -
2012/24/LeeviL/Rangoneina/Rangoneina/RangoneinaContent/RangoneinaContent.contentproj
r3016 r3018 101 101 </Compile> 102 102 </ItemGroup> 103 <ItemGroup> 104 <Compile Include="Kentta3.txt"> 105 <Name>Kentta3</Name> 106 <Importer>TextFileImporter</Importer> 107 <Processor>TextFileContentProcessor</Processor> 108 </Compile> 109 </ItemGroup> 103 110 <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\$(XnaFrameworkVersion)\Microsoft.Xna.GameStudio.ContentPipeline.targets" /> 104 111 <!-- 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.