Skip to content

Commit

Permalink
📦 Changed serialized cosmetic id name
Browse files Browse the repository at this point in the history
  • Loading branch information
MrCrayfish committed May 30, 2022
1 parent 35f6b46 commit 02bdc4e
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 38 deletions.
6 changes: 3 additions & 3 deletions src/generated/resources/.cache/cache
Original file line number Diff line number Diff line change
Expand Up @@ -100,14 +100,14 @@ e41fccac8e1c78a9c5ad942df056926eacf2a128 data/vehicle/vehicles/properties/fluid_
c64e2761068709f9ce6db357280c8cd4fa92b7de data/vehicle/vehicles/properties/golf_cart.json
05bf4456e6e05870b22739e729d2ec264b531268 data/vehicle/vehicles/properties/jet_ski.json
e3d5fd001aad8250f099a60e29a521a466c9322b data/vehicle/vehicles/properties/lawn_mower.json
34be302a9917ee655214ae295353c3c2c7ddf7b0 data/vehicle/vehicles/properties/mini_bus.json
e947a437536713e9ae97b20edef8dab02653c60a data/vehicle/vehicles/properties/mini_bus.json
8c818b3350c3571cbc92cc59ebf596075c60da7e data/vehicle/vehicles/properties/moped.json
084e7e61093f3b2dab91d0ab846c6edb5c0eeff6 data/vehicle/vehicles/properties/off_roader.json
b248e675fed0cccfc19963e30374446b538cea6f data/vehicle/vehicles/properties/quad_bike.json
1a5f78ecc2b73309811ea06ce4fe3a541137f42d data/vehicle/vehicles/properties/seeder.json
29a5b0e606163f0f482eb73fc496b86e366805da data/vehicle/vehicles/properties/sofacopter.json
aa8f53b63e063f72bf79a05b71b2c7a4d92a37be data/vehicle/vehicles/properties/sports_car.json
4e4b8c4584b8ca434110084afc5d69bda51b0134 data/vehicle/vehicles/properties/sports_plane.json
e7317ff254eee431fcf37bd8505060dfab13ae1e data/vehicle/vehicles/properties/sports_car.json
8a71d5ff3c26867948f86316e1ba1769f0b737ae data/vehicle/vehicles/properties/sports_plane.json
5ee93d53a0a2270f5b3aaa32df659cfeb03c452b data/vehicle/vehicles/properties/storage_trailer.json
b49c1dbaf2c403a3f5ab8ba58eabdaa5c6b05bbb data/vehicle/vehicles/properties/tractor.json
e028ecb3cb59a24f0d0ec42f1eacaad546a86e59 data/vehicle/vehicles/properties/vehicle_trailer.json
Original file line number Diff line number Diff line change
@@ -1,35 +1,19 @@
{
"replace": false,
"valid_models": {
"vehicle:left_door": [
"vehicle:vehicle/mini_bus/cosmetics/stock_left_door"
],
"vehicle:dashboard": [
"vehicle:vehicle/mini_bus/cosmetics/stock_dashboard"
],
"vehicle:left_sliding_door": [
"vehicle:vehicle/mini_bus/cosmetics/stock_sliding_door"
],
"vehicle:right_door": [
"vehicle:vehicle/mini_bus/cosmetics/stock_right_door"
],
"vehicle:roof": [
"vehicle:vehicle/mini_bus/cosmetics/roof_racks"
],
"vehicle:rear": [
"vehicle:vehicle/mini_bus/cosmetics/aircon_ladder"
],
"vehicle:left_door": [ "vehicle:vehicle/mini_bus/cosmetics/stock_left_door" ],
"vehicle:dashboard": [ "vehicle:vehicle/mini_bus/cosmetics/stock_dashboard" ],
"vehicle:left_sliding_door": [ "vehicle:vehicle/mini_bus/cosmetics/stock_sliding_door" ],
"vehicle:right_door": [ "vehicle:vehicle/mini_bus/cosmetics/stock_right_door" ],
"vehicle:roof": [ "vehicle:vehicle/mini_bus/cosmetics/roof_racks" ],
"vehicle:rear": [ "vehicle:vehicle/mini_bus/cosmetics/aircon_ladder" ],
"vehicle:roof_frame": [
"vehicle:vehicle/mini_bus/cosmetics/stock_roof",
{
"model": "vehicle:vehicle/mini_bus/cosmetics/front_roof",
"disables": [
"vehicle:rear", "vehicle:roof"
]
"disables": [ "vehicle:rear", "vehicle:roof" ]
}
],
"vehicle:seat": [
"vehicle:vehicle/mini_bus/cosmetics/stock_seat"
]
"vehicle:seat": [ "vehicle:vehicle/mini_bus/cosmetics/stock_seat" ]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
"offset": [ 11.5, 5.0, 20.5 ],
"actions": [
{
"type": "vehicle:openable",
"id": "vehicle:openable",
"rotation": {
"axis": "y",
"angle": -75.0,
Expand All @@ -109,7 +109,7 @@
"offset": [ 11.5, 5.0, -7.5 ],
"actions": [
{
"type": "vehicle:openable",
"id": "vehicle:openable",
"rotation": {
"axis": "y",
"angle": 105.0,
Expand All @@ -127,7 +127,7 @@
"offset": [ -11.5, 5.0, 20.5 ],
"actions": [
{
"type": "vehicle:openable",
"id": "vehicle:openable",
"rotation": {
"axis": "y",
"angle": 75.0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
"offset": [ 15.0, 1.0, 10.0 ],
"actions": [
{
"type": "vehicle:openable",
"id": "vehicle:openable",
"rotation": {
"axis": "y",
"angle": -75.0,
Expand All @@ -92,7 +92,7 @@
"offset": [ 0.0, 15.5, -23.5 ],
"actions": [
{
"type": "vehicle:openable",
"id": "vehicle:openable",
"rotation": {
"axis": "x",
"angle": 90.0,
Expand All @@ -114,7 +114,7 @@
"offset": [ -15.0, 1.0, 10.0 ],
"actions": [
{
"type": "vehicle:openable",
"id": "vehicle:openable",
"rotation": {
"axis": "y",
"angle": 90.0,
Expand All @@ -140,7 +140,7 @@
"offset": [ 0.0, 13.5, 13.5 ],
"actions": [
{
"type": "vehicle:openable",
"id": "vehicle:openable",
"rotation": {
"axis": "x",
"angle": -60.0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
"offset": [ 0.0, 14.0, 31.0 ],
"actions": [
{
"type": "vehicle:rotate",
"id": "vehicle:rotate",
"source": "propeller",
"axis": "z",
"scale": 1.0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,11 @@ public void serialize(JsonObject object)
JsonArray actions = new JsonArray();
this.actions.forEach(actionSupplier -> {
Action action = actionSupplier.get();
ResourceLocation type = CosmeticActions.getId(action.getClass());
if(type == null)
ResourceLocation id = CosmeticActions.getId(action.getClass());
if(id == null)
return;
JsonObject actionData = new JsonObject();
actionData.addProperty("type", type.toString());
actionData.addProperty("id", id.toString());
action.serialize(actionData);
actions.add(actionData);
});
Expand Down

0 comments on commit 02bdc4e

Please sign in to comment.