Skip to content

Commit 4543126

Browse files
author
hamstar0
committed
v1.1.3.3 - Minor tweak to attempt to remedy invalid MP mirrors
1 parent 7c74ab6 commit 4543126

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

MountedMagicMirrors/MyPlayer_Mirrors.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,7 @@ public bool TeleportToMirror( int tileX, int tileY ) {
107107

108108
Tile tile = Framing.GetTileSafely( tileX, tileY );
109109
if( tile.type != mmmTileType ) {
110-
//bool isInvalid = Main.netMode != 1 || TileChunkHelpers.IsTileSyncedForCurrentClient( tileX, tileY );
111-
//if( isInvalid ) { }
112-
if( MMMPlayer.IsMirrorTileInvalid(tileX, tileY) != false ) {
110+
if( MMMPlayer.IsMirrorTileInvalid(tileX, tileY) == true ) {
113111
if( MMMConfig.Instance.DebugModeInfo ) {
114112
Main.NewText( "Cannot teleport - Invalid mirror tile at " + tileX + "," + tileY );
115113
}

MountedMagicMirrors/MyWorld_TileSectionMap.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,10 @@ partial class MMMWorld : ModWorld {
1515
////////////////
1616

1717
public void RegisterTileSectionTile( int tileX, int tileY ) {
18-
this.TileSectionMapByTile.Set2D( tileX, tileY );
18+
int sectionX = Netplay.GetSectionX( tileX );
19+
int sectionY = Netplay.GetSectionY( tileY );
20+
21+
this.TileSectionMapByTile.Set2D( sectionX, sectionY );
1922
}
2023

2124
////

MountedMagicMirrors/build.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
displayName = Mounted Magic Mirrors
22
author = hamstar
3-
version = 1.1.3.2
3+
version = 1.1.3.3
44
modReferences = HamstarHelpers@5.6.1
55
buildIgnore = *.csproj, *.user, *.bat, obj\*, bin\*, .vs\*, .git\*
66
homepage = https://forums.terraria.org/index.php?threads/mounted-magic-mirrors-fast-travel.83296/

0 commit comments

Comments
 (0)