Schematic changes and some final fixes

This commit is contained in:
DominicKarma42 committed 2020-07-27 18:54:17 -05:00
1 parent 604e3a4040
commit 4bad613534
21 files changed
+11918 -12082

No files matched your search

File diff suppressed because it is too large. Load diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

File diff suppressed because it is too large. Load diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

File diff suppressed because it is too large. Load diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

File diff suppressed because it is too large. Load diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 KiB

After

Width:  |  Height:  |  Size: 4.1 KiB

File diff suppressed because it is too large. Load diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 2.6 KiB

File diff suppressed because it is too large. Load diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

File diff suppressed because it is too large. Load diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

File diff suppressed because it is too large. Load diff
+4 -3
View File
@@ -12,6 +12,7 @@ namespace CalamityMod.TileEntities
public int Time;
public int ActiveTimer;
public const int ActiveTimerMax = 45;
public const float Radius = 660f;
public override bool ValidTile(int i, int j)
{
Tile tile = Main.tile[i, j];
@@ -21,20 +22,20 @@ namespace CalamityMod.TileEntities
{
Player player = Main.player[Player.FindClosest(Position.ToVector2() * 16, 1, 1)];
Vector2 positionWorldCoords = Position.ToVector2() * 16f;
if (Vector2.Distance(player.Center, positionWorldCoords) < 960f && !player.dead)
if (Vector2.Distance(player.Center, positionWorldCoords) < Radius && !player.dead)
{
if (ActiveTimer < ActiveTimerMax)
ActiveTimer++;
Time++;
if (Time % 40 == 39)
if (Time % 75 == 74)
{
float speed = 5f;
Vector2 aimOffset = (player.velocity + player.oldVelocity) * 0.5f * player.Distance(positionWorldCoords) / (speed * speed);
Vector2 velocity = Vector2.Normalize(player.Center - positionWorldCoords + aimOffset) * speed;
Projectile.NewProjectileDirect(positionWorldCoords, velocity, ModContent.ProjectileType<DraedonLaser>(), 27, 4f);
}
if (Time % 95 == 94)
if (Time % 150 == 149)
{
for (int i = 0; i < 9; i++)
{
+1 -1
View File
@@ -8,7 +8,7 @@ namespace CalamityMod.TileEntities
public class TEDraedonTurret : TEBaseTurret
{
public override int ShootWaitTime => 15;
public override int ShootRate => 60;
public override int ShootRate => 90;
public override int ProjectileDamage => 20;
public override float ShootSpeed => 5f;
public override float ShootSpawnOffset => 32f;
+10 -10
View File
@@ -85,12 +85,12 @@ namespace CalamityMod.Tiles
for (int k = 0; k < pointsToDraw.Length; k++)
{
float angle = k / (float)pointsToDraw.Length * MathHelper.TwoPi;
pointsToDraw[k] = angle.ToRotationVector2() * 1000f;
pointsToDraw[k] = angle.ToRotationVector2() * TEDraedonFieldGenerator.Radius;
pointsToDraw[k] += drawOffset;
pointsToDraw[k] += Main.rand.NextVector2Circular(1f, 1f);
angle = (k + 1) % pointsToDraw.Length / (float)pointsToDraw.Length * MathHelper.TwoPi;
pointsToDraw[(k + 1) % pointsToDraw.Length] = angle.ToRotationVector2() * 1000f;
pointsToDraw[(k + 1) % pointsToDraw.Length] = angle.ToRotationVector2() * TEDraedonFieldGenerator.Radius;
pointsToDraw[(k + 1) % pointsToDraw.Length] += drawOffset;
pointsToDraw[(k + 1) % pointsToDraw.Length] += Main.rand.NextVector2Circular(1f, 1f);
@@ -101,18 +101,18 @@ namespace CalamityMod.Tiles
DelegateMethods.c_1 = Color.Cyan;
DelegateMethods.f_1 = 1f;
DelegateMethods.c_1 *= Utils.InverseLerp(1600f, 1000f, Math.Abs(positionWorldCoords.X - player.Center.X), true) *
Utils.InverseLerp(1000f, 660f, Math.Abs(positionWorldCoords.Y - player.Center.Y), true);
DelegateMethods.f_1 *= Utils.InverseLerp(1600f, 1000f, Math.Abs(positionWorldCoords.X - player.Center.X), true) *
Utils.InverseLerp(1000f, 660f, Math.Abs(positionWorldCoords.Y - player.Center.Y), true);
DelegateMethods.c_1 *= Utils.InverseLerp(TEDraedonFieldGenerator.Radius, TEDraedonFieldGenerator.Radius - 300f, Math.Abs(positionWorldCoords.X - player.Center.X), true) *
Utils.InverseLerp(TEDraedonFieldGenerator.Radius, TEDraedonFieldGenerator.Radius - 300f, Math.Abs(positionWorldCoords.Y - player.Center.Y), true);
DelegateMethods.f_1 *= Utils.InverseLerp(TEDraedonFieldGenerator.Radius, TEDraedonFieldGenerator.Radius - 300f, Math.Abs(positionWorldCoords.X - player.Center.X), true) *
Utils.InverseLerp(TEDraedonFieldGenerator.Radius, TEDraedonFieldGenerator.Radius - 300f, Math.Abs(positionWorldCoords.Y - player.Center.Y), true);
Utils.DrawLaser(spriteBatch, laserTexture, pointsToDraw[k], pointsToDraw[(k + 1) % pointsToDraw.Length], new Vector2(0.3f), new Utils.LaserLineFraming(DelegateMethods.LightningLaserDraw));
DelegateMethods.c_1 = Color.White * 0.7f;
DelegateMethods.f_1 = 0.7f;
DelegateMethods.c_1 *= Utils.InverseLerp(1600f, 1000f, Math.Abs(positionWorldCoords.X - player.Center.X), true) *
Utils.InverseLerp(1000f, 660f, Math.Abs(positionWorldCoords.Y - player.Center.Y), true);
DelegateMethods.f_1 *= Utils.InverseLerp(1600f, 1000f, Math.Abs(positionWorldCoords.X - player.Center.X), true) *
Utils.InverseLerp(1000f, 660f, Math.Abs(positionWorldCoords.Y - player.Center.Y), true);
DelegateMethods.c_1 *= Utils.InverseLerp(TEDraedonFieldGenerator.Radius, TEDraedonFieldGenerator.Radius - 300f, Math.Abs(positionWorldCoords.X - player.Center.X), true) *
Utils.InverseLerp(TEDraedonFieldGenerator.Radius, TEDraedonFieldGenerator.Radius - 300f, Math.Abs(positionWorldCoords.Y - player.Center.Y), true);
DelegateMethods.f_1 *= Utils.InverseLerp(TEDraedonFieldGenerator.Radius, TEDraedonFieldGenerator.Radius - 300f, Math.Abs(positionWorldCoords.X - player.Center.X), true) *
Utils.InverseLerp(TEDraedonFieldGenerator.Radius, TEDraedonFieldGenerator.Radius - 300f, Math.Abs(positionWorldCoords.Y - player.Center.Y), true);
Utils.DrawLaser(spriteBatch, laserTexture, pointsToDraw[k], pointsToDraw[(k + 1) % pointsToDraw.Length], new Vector2(0.6f), new Utils.LaserLineFraming(DelegateMethods.LightningLaserDraw));
}
}
@@ -47,7 +47,7 @@ namespace CalamityMod.Tiles.DraedonStructures
short frameY = 0;
for (int dy = -4; dy < 4; dy++)
{
if (Main.tile[i, j + dy].type == ModContent.TileType<AgedLaboratoryDoorClosed>())
if (Main.tile[i, j + dy].type == ModContent.TileType<AgedLaboratoryDoorOpen>())
{
if (Main.tile[i, j + dy] == null)
{
@@ -47,7 +47,7 @@ namespace CalamityMod.Tiles.DraedonStructures
short frameY = 0;
for (int dy = -4; dy < 4; dy++)
{
if (Main.tile[i, j + dy].type == ModContent.TileType<LaboratoryDoorClosed>())
if (Main.tile[i, j + dy].type == ModContent.TileType<LaboratoryDoorOpen>())
{
if (Main.tile[i, j + dy] == null)
{
+1 -1
View File
@@ -215,7 +215,7 @@ namespace CalamityMod.World
TryAgain:
int underworldTop = Main.maxTilesY - 200;
int placementPositionX = WorldGen.genRand.Next((int)(Main.maxTilesX * 0.82), (int)(Main.maxTilesX * 0.925));
int placementPositionY = WorldGen.genRand.Next(Main.maxTilesY - 150, Main.maxTilesY - 105);
int placementPositionY = WorldGen.genRand.Next(Main.maxTilesY - 150, Main.maxTilesY - 125);
placementPoint = new Point(placementPositionX, placementPositionY);
Vector2 schematicSize = new Vector2(TileMaps[mapKey].GetLength(0), TileMaps[mapKey].GetLength(1));