There has been lately a lot of persons asking how to make night animations on the discord, therefore i'll post a tutorial on how to make night animations rotation aware, but first, a few details :
-Rotation aware buildings can only have 2 or 4 frames, the same apply for rotation aware light animations. Otherwise, you might not get the expected result.
-This tutorial will admit you have already created 2 distinct png, one with the rotations of your prop / building, and another with the night animations, just like I did with the newspaper kiosk right under, which i'll use as an example.
Code: Select all Reset
[ { "id": "$Themax_PrpDecs1_Paris_Newspaper_Kiosk1_Night", "type": "animation", "light": true, "light switching": true, "frames": [ { "bmp": "Themax_PrpDecs1_Paris_Newspaper_Kiosk1_Night.png", "count": 4, "h": 32, "w": 32 } ], "rotation aware": true }, { "id": "$Themax_PrpDecs1_Paris_Newspaper_Kiosk1", "type": "decoration", "category": "$cat_Themax_Props_And_Decorations_0", "author": "Themax", "width": 1, "height": 1, "frames": [ { "bmp": "Themax_PrpDecs1_Paris_Newspaper_Kiosk1.png", "count": 4, "h": 32, "w": 32 } ], "animation": [{"id": "$Themax_PrpDecs1_Paris_Newspaper_Kiosk1_Night", "x":0,"y":-25}], "price": 400, "monthly price": 0, "rotation aware": true, "draw ground": true, "water": "0", "power": "0", "build time": 0, "ordinal": 101, "needs road": false, "text": "A newspaper kiosk based on those you can find in Paris.", "title": "Paris newspaper kiosk" } ]
JSON checker
Once that is done, adds an animation line to your json and you should be good to go, adjust the "y" part accordingly so it match your texture.
There you go, you have a basic json for a rotation aware building with night animations. In addition, this functionnality works also for cars, and it can really lower the work burden if done correctly, at the expanse of a sometimes bigger plugin texture space usage, for this reason, i would recommend not using this solution for plugins that have a large size.
If i discover other, better ways to make rotation aware night animations, i'll post about those.