[Mod] Random Rotate Buildings

Discussion in 'Modding' started by BombaRuLz, Oct 2, 2016.

  1. BombaRuLz

    BombaRuLz New Member

    I was digging some other things when i found something interesting and i started digging into that after. Posted everything here but i'll post it here aswell

    I wanted to make 3-4 default positions of building rotations and i couldn't do it since i am not very good at pascal (random value from 3-4 predefined values), if somebody knows bit more please share it here. Saying 3-4 positions (angles) because buildings can be seen on the back sides also, i'd prefer to see them on front and sides only.

    So since i couldn't make custom Random function, i've used "Random" before RollAngle and i think it's predefined function somewhere (same as Default). The line i've added is :
    RandomRollAngle = true

    It's added on each file (maybe there is shorter way for all at once), for each building that you would like to have auto rotation. Buildings can be found here:

    So, lets say we open polbar.prop. (polish barracks) On the last section find DefaultRollAngle = 135. This is the default angle for all buildings, you can set it to different value and it will be using that static value forever if you like. However, if you want new rotation on every build, just add
    RandomRollAngle = true
    below that defaultrollangle line and it's working perfectly.

    Here is a picture of that working well:

    Short version:
    1. Open .\data\objects\buildings\polbar.prop
    2. Add RandomRollAngle = true below DefaultRollAngle = 135 near the end
    3. Repeat for all buildings / files
    4. In game try build Barracks with Poland

    Post your questions or modifications here, best case scenario would be if we can lets say make "button" for rotating (increasing angles) on the building.
    Last edited: Nov 18, 2021
    emulert, DennisUA, Ebel and 2 others like this.
  2. Ebel

    Ebel Moderator Staff Member

    Question: what happens to the soldiers that come out of a rotated barracks: do they walk through walls or through the door?
  3. A. Soldier

    A. Soldier Active Member

    I'm guessing they walk through the front door.

    Another interesting thing I noticed yesterday was musketeers walking out of the artillery depot in the campaign.
  4. BombaRuLz

    BombaRuLz New Member

    Last edited: Nov 18, 2021
  5. A. Soldier

    A. Soldier Active Member

    I believe they were orange and it seems like most of American Conquest's mechanics, so it might be a disabled feature, not s big. But I'm not 100% sure.

    And ah, I thought they would come out of the gate/door.
  6. DennisUA

    DennisUA Member

    i would like this as game Feature not as a mod
  7. A. Soldier

    A. Soldier Active Member

    All in good time my friend
  8. DennisUA

    DennisUA Member

    lets hope so my friend
  9. A. Soldier

    A. Soldier Active Member

    Well they said they're going to try to modernize it and bring the game up to 2016 standards, ain't no 3D game in 2016 without rotating buildings.

    So just keep calm and wait on, slow and steady is better than rushed and not ready.
  10. Tchey

    Tchey New Member

    I'd use the mod but i don't want random rotation, i want to decide so i can build pretty "village". Any chance you manage to hack it ?
  11. A. Soldier

    A. Soldier Active Member

    We're modders, not hackers.

    And no, at least not for now. I've asked a friend of mine that is a bit better at pascal to take a look at it. His best suggestion was to have a look at how walls rotate, but unlike normal buildings walls can be built in custom patterns.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice