Animation in building rotation?

Plug-in related stuff can be discussed here.

Moderator: Plugin Moderators

User avatar
MXD77
Inhabitant of a Megacity
Reactions:
Posts: 255
Joined: 15 May 2017, 00:05
Location: Gdańsk
Plugins: Showcase Store

Platform

Animation in building rotation?

#1

Post by MXD77 »

It's possible to add animation to the buildings which has rotation :bq

User avatar
CommanderABab
AB
Reactions:
Posts: 11106
Joined: 07 Jun 2016, 21:12
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Animation in building rotation?

#2

Post by CommanderABab »

Yes

User avatar
MXD77
Inhabitant of a Megacity
Reactions:
Posts: 255
Joined: 15 May 2017, 00:05
Location: Gdańsk
Plugins: Showcase Store

Platform

Re: Animation in building rotation?

#3

Post by MXD77 »

CommanderABab wrote:
05 Aug 2017, 15:36
Yes
So how code was look?

User avatar
CommanderABab
AB
Reactions:
Posts: 11106
Joined: 07 Jun 2016, 21:12
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Animation in building rotation?

#4

Post by CommanderABab »

bcgrndflrallorn.png
bcgrndflrallorn.png (1 KiB) Viewed 4090 times
upanimorn.png
upanimorn.png (241 Bytes) Viewed 4090 times
bcwallsorn.png
bcwallsorn.png (463 Bytes) Viewed 4090 times
MXD77 wrote:
05 Aug 2017, 15:50
CommanderABab wrote:
05 Aug 2017, 15:36
Yes
So how code was look?

Code: Select all

[{ 
      "id": "helevatoranim.01",
      "type" : "animation",
      "speed": .5,
      "frames": [
        {"bmp":"upanimorn.png","w":1, "h":5,"count":32}
      ]
   },
   {
      "id": "hbcanimat.01",
      "type":"animation",
      "speed":1,
      "frames":[
        {"bmp":"bcgrndflrallorn.png"}
      ]
   },{
      "id": "hbcanimat.00",
      "type":"animation",
      "speed":1,
      "frames":[
        {"bmp":"bcwallsorn.png"}
      ]
   },{
      "id":"harborres48",
      "type": "harbor ind",
      "author": "CommanderABab",
      "width": 1,
      "height": 1,
      "speed": 1,
      "draw ground": true,
      "rotation aware":true,
      "need water":true,
      "frames": [ 
      { 
        "x": 0, 
        "y": 0, 
        "w": 0, 
        "h": 56, 
        "count": 4
      } 
      ], 
      "animation": [
      {"id":"hbcanimat.01","x":0,"y":-7},
      {"id":"helevatoranim.01","x":22,"y":-2},
      {"id":"hbcanimat.00","x":0,"y":-7},
      {"id":"helevatoranim.01","x":22,"y":-2}, 
      {"id":"hbcanimat.00","x":0,"y":-14},
      {"id":"helevatoranim.01","x":22,"y":-9},
      {"id":"hbcanimat.00","x":0,"y":-21},
      {"id":"helevatoranim.01","x":22,"y":-16}, 
      {"id":"hbcanimat.00","x":0,"y":-28},
      {"id":"helevatoranim.01","x":22,"y":-23},
      {"id":"hbcanimat.00","x":0,"y":-35},
      {"id":"helevatoranim.01","x":22,"y":-30},
      {"id":"hbcanimat.00","x":0,"y":-42},
      {"id":"helevatoranim.01","x":22,"y":-37},
      {"id":"hbcanimat.00","x":0,"y":-49},
      {"id":"helevatoranim.01","x":22,"y":-44},
      {"id":"hbcanimat.00","x":0,"y":-56},
      {"id":"helevatoranim.01","x":22,"y":-51}
      ],
      
      "power": -20,
      "water": -10,
      "level": 2
   }]
Uses rotation aware to keep the building which is placed level by level from flickering. It actually looks the same at each rotation. If a different look was needed each view, you would need to make the animations rotation aware and provide 4 times the frames I did.
Attachments
Not used.  It messed up the elevator animation.
Not used. It messed up the elevator animation.
bcrooforn.png (173 Bytes) Viewed 4090 times

User avatar
MXD77
Inhabitant of a Megacity
Reactions:
Posts: 255
Joined: 15 May 2017, 00:05
Location: Gdańsk
Plugins: Showcase Store

Platform

Re: Animation in building rotation?

#5

Post by MXD77 »

CommanderABab wrote:
05 Aug 2017, 16:02
bcgrndflrallorn.png
upanimorn.png
bcwallsorn.png
MXD77 wrote:
05 Aug 2017, 15:50
CommanderABab wrote:
05 Aug 2017, 15:36
Yes
So how code was look?

Code: Select all

[{ 
      "id": "helevatoranim.01",
      "type" : "animation",
      "speed": .5,
      "frames": [
        {"bmp":"upanimorn.png","w":1, "h":5,"count":32}
      ]
   },
   {
      "id": "hbcanimat.01",
      "type":"animation",
      "speed":1,
      "frames":[
        {"bmp":"bcgrndflrallorn.png"}
      ]
   },{
      "id": "hbcanimat.00",
      "type":"animation",
      "speed":1,
      "frames":[
        {"bmp":"bcwallsorn.png"}
      ]
   },{
      "id":"harborres48",
      "type": "harbor ind",
      "author": "CommanderABab",
      "width": 1,
      "height": 1,
      "speed": 1,
      "draw ground": true,
      "rotation aware":true,
      "need water":true,
      "frames": [ 
      { 
        "x": 0, 
        "y": 0, 
        "w": 0, 
        "h": 56, 
        "count": 4
      } 
      ], 
      "animation": [
      {"id":"hbcanimat.01","x":0,"y":-7},
      {"id":"helevatoranim.01","x":22,"y":-2},
      {"id":"hbcanimat.00","x":0,"y":-7},
      {"id":"helevatoranim.01","x":22,"y":-2}, 
      {"id":"hbcanimat.00","x":0,"y":-14},
      {"id":"helevatoranim.01","x":22,"y":-9},
      {"id":"hbcanimat.00","x":0,"y":-21},
      {"id":"helevatoranim.01","x":22,"y":-16}, 
      {"id":"hbcanimat.00","x":0,"y":-28},
      {"id":"helevatoranim.01","x":22,"y":-23},
      {"id":"hbcanimat.00","x":0,"y":-35},
      {"id":"helevatoranim.01","x":22,"y":-30},
      {"id":"hbcanimat.00","x":0,"y":-42},
      {"id":"helevatoranim.01","x":22,"y":-37},
      {"id":"hbcanimat.00","x":0,"y":-49},
      {"id":"helevatoranim.01","x":22,"y":-44},
      {"id":"hbcanimat.00","x":0,"y":-56},
      {"id":"helevatoranim.01","x":22,"y":-51}
      ],
      
      "power": -20,
      "water": -10,
      "level": 2
   }]
Ok thanks :bc

User avatar
CommanderABab
AB
Reactions:
Posts: 11106
Joined: 07 Jun 2016, 21:12
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Animation in building rotation?

#6

Post by CommanderABab »

Updated what you quoted.

User avatar
Hadestia
Inhabitant of a Megalopolis
Reactions:
Posts: 727
Joined: 17 Jul 2017, 16:16
Location: Philippines
Plugins: Showcase Store
Contact:

Plugin Creator

Platform

Re: Animation in building rotation?

#7

Post by Hadestia »

more writings my mind wanna blow up to understand

User avatar
Lobby
Developer
Reactions:
Posts: 3705
Joined: 26 Oct 2008, 12:34
Plugins: Showcase Store
Version: Beta

Platform

Re: Animation in building rotation?

#8

Post by Lobby »

Yes, this stuff is a bit tricky and there are multiple solutions to it. But most of the time you won't need this feature (at least I didn't).

User avatar
MXD77
Inhabitant of a Megacity
Reactions:
Posts: 255
Joined: 15 May 2017, 00:05
Location: Gdańsk
Plugins: Showcase Store

Platform

Re: Animation in building rotation?

#9

Post by MXD77 »

It's looking really hard so that's need hard work :mine

User avatar
Designer Anthony
Reactions:

Re: Animation in building rotation?

#10

Post by Designer Anthony »

Do you need four frames to make rotation aware work? If less, will it still work?

User avatar
The_Real_Michael_1
Black Hole
Reactions:
Posts: 1511
Joined: 23 Mar 2020, 15:16
Location: Bing Chilling
Plugins: Showcase Store

Plugin Creator

Platform

Re: Animation in building rotation?

#11

Post by The_Real_Michael_1 »

Designer Anthony wrote:
24 Feb 2021, 22:51
Do you need four frames to make rotation aware work? If less, will it still work?
Bruh.
This topic is over three years old.

Post Reply Previous topicNext topic

Return to “Plug-In Discussion”