mirror of
https://e.coding.net/circlecloud/YumCore.git
synced 2024-11-24 02:08:48 +00:00
fix: 地区初始化失败返回null
Signed-off-by: 502647092 <admin@yumc.pw>
This commit is contained in:
parent
309530e610
commit
fbe19de5db
@ -39,10 +39,7 @@ public class L {
|
||||
*/
|
||||
public static Location deserialize(Map<String, Object> args) {
|
||||
World world = Bukkit.getWorld((String) args.get("world"));
|
||||
if (world == null) {
|
||||
throw new IllegalArgumentException("unknown world");
|
||||
}
|
||||
|
||||
if (world == null) { return null; }
|
||||
return new Location(world, NumberConversions.toDouble(args.get("x")), NumberConversions.toDouble(args.get("y")), NumberConversions.toDouble(args.get("z")), NumberConversions
|
||||
.toFloat(args.get("yaw")), NumberConversions.toFloat(args.get("pitch")));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user