OSDN Git Service

Updates for V1.13 series (Prerelease...!) PR7.3
authormelchior <melchior@users.osdn.me>
Fri, 7 Aug 2020 22:07:48 +0000 (18:07 -0400)
committermelchior <melchior@users.osdn.me>
Fri, 7 Aug 2020 22:07:48 +0000 (18:07 -0400)
Automap/Subsystems/AutomapSystem.cs
Automap/modinfo.json

index 6636ea9..4bab7de 100644 (file)
@@ -107,7 +107,7 @@ namespace Automap
                        outputText.Flush();
 
                        Prefill_POI_Designators();
-                       startChunkColumn = new Vec2i((ClientAPI.World.Player.Entity.LocalPos.AsBlockPos.X / chunkSize), (ClientAPI.World.Player.Entity.LocalPos.AsBlockPos.Z / chunkSize));
+                       startChunkColumn = new Vec2i((ClientAPI.World.Player.Entity.Pos.AsBlockPos.X / chunkSize), (ClientAPI.World.Player.Entity.Pos.AsBlockPos.Z / chunkSize));
                        chunkTopMetadata = new ColumnsMetadata(startChunkColumn);
                        Logger.Notification("AUTOMAP Start {0}", startChunkColumn);
                        Reload_Metadata();
@@ -572,18 +572,18 @@ namespace Automap
                                }
 
                                /*************** Chunk Entities Scanning *********************/
-                               if (chunkData.BlockEntities != null && chunkData.BlockEntities.Length > 0)
+                               if (chunkData.BlockEntities != null && chunkData.BlockEntities.Count > 0)
                                {
 #if DEBUG
-                                       Logger.VerboseDebug("Surface@ {0} = BlockEntities: {1}", key, chunkData.BlockEntities.Length);
+                                       Logger.VerboseDebug("Surface@ {0} = BlockEntities: {1}", key, chunkData.BlockEntities.Count);
 #endif
 
                                        foreach (var blockEnt in chunkData.BlockEntities)
                                        {
-                                               if (blockEnt != null && blockEnt.Block != null && BlockID_Designators.ContainsKey(blockEnt.Block.BlockId))
+                                               if (blockEnt.Value != null && blockEnt.Value.Block != null && BlockID_Designators.ContainsKey(blockEnt.Value.Block.BlockId))
                                                {
-                                                       var designator = BlockID_Designators[blockEnt.Block.BlockId];
-                                                       designator.SpecialAction(ClientAPI, POIs, blockEnt.Pos.Copy(), blockEnt.Block);
+                                                       var designator = BlockID_Designators[blockEnt.Value.Block.BlockId];
+                                                       designator.SpecialAction(ClientAPI, POIs, blockEnt.Value.Pos.Copy(), blockEnt.Value.Block);
                                                }
                                        }
                                }
@@ -653,7 +653,7 @@ namespace Automap
                                var dMatch = Entity_Designators.SingleOrDefault(se => se.Key.Equals(loadedEntity.Value.Code));
                                if (dMatch.Value != null)
                                {
-                                       dMatch.Value.SpecialAction(ClientAPI, this.EOIs, loadedEntity.Value.LocalPos.AsBlockPos.Copy(), loadedEntity.Value);
+                                       dMatch.Value.SpecialAction(ClientAPI, this.EOIs, loadedEntity.Value.Pos.AsBlockPos.Copy(), loadedEntity.Value);
                                }
 
                        }
@@ -666,7 +666,7 @@ namespace Automap
                        var playerNodePoi = new PointOfInterest()
                        {
                                Name = "Note",
-                               Location = ClientAPI.World.Player.Entity.LocalPos.AsBlockPos.Copy(),
+                               Location = ClientAPI.World.Player.Entity.Pos.AsBlockPos.Copy(),
                                Notes = notation,
                                Timestamp = DateTime.UtcNow,
                        };
index 810b7c2..b715fe2 100644 (file)
@@ -4,10 +4,10 @@
   "description" : "Automap; Generates a static HTML map dynamically, with Points of Interest!",
   "authors": ["Melchior","VeryGoodDog"],
   "contributors":["VeryGoodDog"],
-  "version": "0.1.3",
+  "version": "0.1.4",
     "side":"Client",
   "dependencies": { 
-       "game": "1.12.0"        
+       "game": "1.13.0-pre.5"  
   },
   "website": "http://nowebsite.nope"
 }
\ No newline at end of file