refactor: migrate JodaTime to java.time (rebuild on subdate2 ab96cfc)
Complete the JodaTime -> java.time migration across 30 files on the correct subdate2 base. No org.joda references remain.
This commit is contained in:
1 parent
ab96cfcda4
commit
8a136d84f4
30 files changed
+184
-196
No files matched your search
@@ -19,7 +19,7 @@ import engine.net.client.msg.PlaceAssetMsg;
|
||||
import engine.net.client.msg.PlaceAssetMsg.PlacementInfo;
|
||||
import engine.objects.*;
|
||||
import engine.server.MBServerStatics;
|
||||
import org.joda.time.DateTime;
|
||||
import java.time.Instant;
|
||||
import org.pmw.tinylog.Logger;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
@@ -1142,7 +1142,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
Blueprint blueprint;
|
||||
Building newMesh;
|
||||
DateTime completionDate;
|
||||
Instant completionDate;
|
||||
float vendorRotation;
|
||||
float buildingRotation;
|
||||
|
||||
@@ -1157,9 +1157,9 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
if ((blueprint.getBuildingGroup().equals(BuildingGroup.SIEGETENT))
|
||||
|| (blueprint.getBuildingGroup().equals(BuildingGroup.BULWARK)))
|
||||
completionDate = DateTime.now().plusMinutes(15);
|
||||
completionDate = Instant.now().plusSeconds(15 * 60);
|
||||
else
|
||||
completionDate = DateTime.now().plusHours(blueprint.getRankTime(1));
|
||||
completionDate = Instant.now().plusSeconds(blueprint.getRankTime(1) * 3600);
|
||||
|
||||
Vector3fImmutable localLoc = new Vector3fImmutable(ZoneManager.worldToLocal(buildingInfo.getLoc(), currentZone));
|
||||
|
||||
@@ -1228,7 +1228,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
ArrayList<AbstractGameObject> shrineObjects = DbManager.ShrineQueries.CREATE_SHRINE(
|
||||
currentZone.getObjectUUID(), player.getObjectUUID(), blueprint.getName(), blueprint.getMeshForRank(0),
|
||||
localLoc, 1.0f, blueprint.getMaxHealth(0), ProtectionState.PROTECTED, 0, 0,
|
||||
DateTime.now().plusHours(blueprint.getRankTime(1)), blueprint.getMeshForRank(0), vendorRotation, buildingRotation, shrineType.name());
|
||||
Instant.now().plusSeconds(blueprint.getRankTime(1) * 3600), blueprint.getMeshForRank(0), vendorRotation, buildingRotation, shrineType.name());
|
||||
|
||||
if (shrineObjects == null) {
|
||||
PlaceAssetMsg.sendPlaceAssetError(player.getClientConnection(), 1, "A Serious error has occurred. Please post details for to ensure transaction integrity");
|
||||
@@ -1288,7 +1288,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
float buildingRotation = buildingInfo.getRot().y;
|
||||
float vendorRotation = buildingInfo.getW();
|
||||
DateTime completionDate = DateTime.now().plusHours(blueprint.getRankTime(1));
|
||||
Instant completionDate = Instant.now().plusSeconds(blueprint.getRankTime(1) * 3600);
|
||||
|
||||
|
||||
newMesh = DbManager.BuildingQueries.CREATE_BUILDING(
|
||||
@@ -1333,7 +1333,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
|
||||
warehouseBuilding = DbManager.BuildingQueries.CREATE_BUILDING(
|
||||
currentZone.getObjectUUID(), player.getObjectUUID(), blueprint.getName(), blueprint.getMeshForRank(0),
|
||||
localLoc, 1.0f, blueprint.getMaxHealth(0), ProtectionState.NONE, 0, 0,
|
||||
DateTime.now().plusHours(blueprint.getRankTime(1)), blueprint.getMeshForRank(0), vendorRotation, buildingRotation);
|
||||
Instant.now().plusSeconds(blueprint.getRankTime(1) * 3600), blueprint.getMeshForRank(0), vendorRotation, buildingRotation);
|
||||
|
||||
if (warehouseBuilding == null) {
|
||||
PlaceAssetMsg.sendPlaceAssetError(player.getClientConnection(), 1, "A Serious error has occurred. Please post details for to ensure transaction integrity");
|
||||
|
||||
Reference in new issue
Block a user