# HG changeset patch # User koda # Date 1278720157 -7200 # Node ID 8e1bd8b5780eb5d2f8ce8abd7cc1629b8dbb06e5 # Parent 159bc2fd7f689474974a650da3a040435e6bcb8e fix land check fo' real more logs in case of failing gameConfig diff -r 159bc2fd7f68 -r 8e1bd8b5780e hedgewars/uLand.pas --- a/hedgewars/uLand.pas Thu Jul 08 23:34:25 2010 +0200 +++ b/hedgewars/uLand.pas Sat Jul 10 02:02:37 2010 +0200 @@ -66,10 +66,11 @@ procedure LogLandDigest; var s: shortstring; - adler: LongInt; + adler, i, tmp: LongInt; begin adler:= 1; -Adler32Update(adler, @Land[0,0], sizeof(Land)); +for i:= 0 to LAND_HEIGHT-1 do + Adler32Update(adler, @Land[i,0], LAND_WIDTH); s:= 'M'+inttostr(adler); CheckLandDigest(s); diff -r 159bc2fd7f68 -r 8e1bd8b5780e project_files/HedgewarsMobile/Classes/GameConfigViewController.m --- a/project_files/HedgewarsMobile/Classes/GameConfigViewController.m Thu Jul 08 23:34:25 2010 +0200 +++ b/project_files/HedgewarsMobile/Classes/GameConfigViewController.m Sat Jul 10 02:02:37 2010 +0200 @@ -143,8 +143,8 @@ return; } - /* - NSDictionary *gameDictionary = [[NSDictionary alloc] initWithObjectsAndKeys:mapConfigViewController.seedCommand,@"seed_command", + // create the configuration file that is going to be sent to engine + NSDictionary *gameDictionary = [NSDictionary dictionaryWithObjectsAndKeys:mapConfigViewController.seedCommand,@"seed_command", mapConfigViewController.templateFilterCommand,@"templatefilter_command", mapConfigViewController.mapGenCommand,@"mapgen_command", mapConfigViewController.mazeSizeCommand,@"mazesize_command", @@ -153,34 +153,15 @@ schemeWeaponConfigViewController.selectedScheme,@"scheme", schemeWeaponConfigViewController.selectedWeapon,@"weapon", nil]; - */ - // create the configuration file that is going to be sent to engine - NSDictionary *gameDictionary = [NSDictionary dictionaryWithObjects:[NSArray arrayWithObjects: - mapConfigViewController.seedCommand, - mapConfigViewController.templateFilterCommand, - mapConfigViewController.mapGenCommand, - mapConfigViewController.mazeSizeCommand, - mapConfigViewController.themeCommand, - teamConfigViewController.listOfSelectedTeams, - schemeWeaponConfigViewController.selectedScheme, - schemeWeaponConfigViewController.selectedWeapon,nil] - forKeys:[NSArray arrayWithObjects: - @"seed_command", - @"templatefilter_command", - @"mapgen_command", - @"mazesize_command", - @"theme_command", - @"teams_list", - @"scheme", - @"weapon",nil]]; // finally launch game and remove this controller DLog(@"sending config %@", gameDictionary); if ([[gameDictionary allKeys] count] == 8) { [[SDLUIKitDelegate sharedAppDelegate] startSDLgame:gameDictionary]; } else { - DLog(@"gameconfig data not complete\n%@\nWHY???", gameDictionary); + DLog(@"gameconfig data not complete!!\nmapConfigViewController = %@\nteamConfigViewController = %@\nschemeWeaponConfigViewController = %@\n", + mapConfigViewController, teamConfigViewController, schemeWeaponConfigViewController); } }