Compare commits

...

2 Commits

1 changed files with 8 additions and 3 deletions

View File

@ -240,9 +240,10 @@ public class Converter {
))
.realisticSteering(baseVehicle.getSteeringType())
.permissions(Permissions.builder()
.buy(baseVehicle.getPermissions().getBuyPermission())
.ride(baseVehicle.getPermissions().getRidePermission())
.sitWithoutRidePermission(baseVehicle.getPermissions().getEnterWithoutRidePermission())
// this was hardcoded because if a config had no permission it produced a null pointer.
.buy("vp.buy." + baseVehicle.getName())
.ride("vp.ride." + baseVehicle.getName())
.sitWithoutRidePermission(false)
.adjust("vp.adjust." + baseVehicle.getName())
.spawn("vp.spawn." + baseVehicle.getName())
.build())
@ -250,6 +251,10 @@ public class Converter {
.gearbox(new Gearbox(true, 10))
.build();
// Idk why but it was detecting type as "car" and it should be "cars" to work
if (model.getTypeId().equals("car"))
model.setTypeId("cars");
saveToVehiclesPlus(model, "vehicles/" + model.getTypeId(), model.getId());
} catch (Exception e) {
e.printStackTrace();