Definition at line 2365 of file WorldFile.cs.
2366 {
2367 for (
int i = 0;
i < Main.maxTilesX;
i++)
2368 {
2369 float num = (float)i / (float)Main.maxTilesX;
2370 Main.statusText = Lang.gen[51].Value + " " + (int)((double)num * 100.0 + 1.0) + "%";
2371 for (
int j = 0;
j < Main.maxTilesY;
j++)
2372 {
2376 byte b3 = (
b2 = (
b = 0));
2377 Tile tile = Main.tile[
i,
j];
2379 bool flag = false;
2381 {
2382 flag = true;
2384 }
2386 if (flag && (
b3 & 1) == 1)
2387 {
2390 }
2392 {
2394 }
2397 {
2398 tile.active(active:
true);
2399 if ((
b4 & 0
x20) == 32)
2400 {
2404 }
2405 else
2406 {
2408 }
2409 tile.type = (ushort)
num2;
2411 {
2414 if (tile.type == 144)
2415 {
2416 tile.frameY = 0;
2417 }
2418 }
2419 else
2420 {
2421 tile.frameX = -1;
2422 tile.frameY = -1;
2423 }
2425 {
2427 }
2428 }
2430 {
2433 {
2434 tile.wall = 0;
2435 }
2436 if ((
b2 & 0
x10) == 16)
2437 {
2439 }
2440 }
2441 b5 = (byte)((
b4 & 0
x18) >> 3);
2443 {
2445 if ((
b2 & 0
x80) == 128)
2446 {
2447 tile.shimmer(shimmer:
true);
2448 }
2450 {
2452 {
2453 tile.lava(lava:
true);
2454 }
2455 else
2456 {
2457 tile.honey(honey:
true);
2458 }
2459 }
2460 }
2462 {
2464 {
2465 tile.wire(wire:
true);
2466 }
2468 {
2469 tile.wire2(wire2:
true);
2470 }
2472 {
2473 tile.wire3(wire3:
true);
2474 }
2475 b5 = (byte)((
b3 & 0
x70) >> 4);
2477 {
2479 {
2480 tile.halfBrick(halfBrick:
true);
2481 }
2482 else
2483 {
2484 tile.slope((
byte)(
b5 - 1));
2485 }
2486 }
2487 }
2489 {
2491 {
2492 tile.actuator(actuator:
true);
2493 }
2495 {
2496 tile.inActive(inActive:
true);
2497 }
2498 if ((
b2 & 0
x20) == 32)
2499 {
2500 tile.wire4(wire4:
true);
2501 }
2502 if ((
b2 & 0
x40) == 64)
2503 {
2505 tile.wall = (ushort)((
b5 << 8) | tile.wall);
2507 {
2508 tile.wall = 0;
2509 }
2510 }
2511 }
2513 {
2515 {
2516 tile.invisibleBlock(invisibleBlock:
true);
2517 }
2519 {
2520 tile.invisibleWall(invisibleWall:
true);
2521 }
2523 {
2524 tile.fullbrightBlock(fullbrightBlock:
true);
2525 }
2526 if ((
b & 0
x10) == 16)
2527 {
2528 tile.fullbrightWall(fullbrightWall:
true);
2529 }
2530 }
2531 int num3 = (byte)((
b4 & 0
xC0) >> 6)
switch
2532 {
2533 0 => 0,
2536 };
2538 {
2539 if ((
double)
j <= Main.worldSurface)
2540 {
2541 if ((
double)(
j +
num3) <= Main.worldSurface)
2542 {
2544 }
2545 else
2546 {
2547 int num4 = (int)(Main.worldSurface - (
double)
j + 1.0);
2550 }
2551 }
2552 else
2553 {
2555 }
2556 }
2558 {
2560 Main.tile[
i,
j].CopyFrom(tile);
2562 }
2563 }
2564 }
2567 {
2569 }
2570 }
virtual short ReadInt16()
static bool[] NonSolidSaveSlopes
static readonly ushort Count
static int _versionNumber
References Terraria.IO.WorldFile._versionNumber, Terraria.Tile.active(), Terraria.Tile.actuator(), Terraria.WorldGen.AddUpAlignmentCounts(), Terraria.Tile.color(), Terraria.ID.WallID.Count, Terraria.WorldGen.FixHearts(), Terraria.Tile.fullbrightBlock(), Terraria.Tile.fullbrightWall(), Terraria.Lang.gen, Terraria.Tile.halfBrick(), Terraria.Tile.honey(), Terraria.Tile.inActive(), Terraria.Tile.invisibleBlock(), Terraria.Tile.invisibleWall(), Terraria.Tile.lava(), Terraria.Main.maxTilesX, Terraria.Main.maxTilesY, Terraria.ID.TileID.Sets.NonSolidSaveSlopes, System.IO.BinaryReader.ReadByte(), System.IO.BinaryReader.ReadInt16(), Terraria.Tile.shimmer(), Terraria.Tile.slope(), Terraria.Main.tile, Terraria.WorldGen.tileCounts, Terraria.Main.tileSolid, Terraria.Tile.type, Terraria.Tile.wall, Terraria.Tile.wallColor(), Terraria.Tile.wire(), Terraria.Tile.wire2(), Terraria.Tile.wire3(), Terraria.Tile.wire4(), and Terraria.Main.worldSurface.
Referenced by Terraria.IO.WorldFile.LoadWorld_Version2().