Jump to content

Better Civil Centre Boundary


Tapothei
 Share

Recommended Posts

There is an empty space around the CC which I can select but I'm trying to rally point the woman to behind it to make a farm which I can't seem to do. Unless I move my camera.
1489457777_Emptyspace.thumb.png.a3447247574c16ef2142292480a4b745.png

To illustrate how big it is, that I can't set a rally point behind the CC.

1095581046_Emptyspace2.thumb.png.d850b54548d0e8e717daac05db78e0fe.png

Suggestion: Reduce the hitbox to follow the blue line(red colour) which is on the surface or limit it until the blue or even yellow.

1172879667_EmptyspaceModified.thumb.png.c6c11be862167757f04eb564cc025860.png

Edited by Tapothei
Link to comment
Share on other sites

38 minutes ago, phosit said:

I think the engine only allows the bounding box to be prism.

Then I would like to request to shorten it, maybe about until 50-65% if possible.

I don't know much about modding, but if anyone can guide me how to change the boundary then I would be happy.

Happy to modify all CC so their hitbox is on the surface/bigger, and make people's life miserable muahahaha! (joke)

Edited by Tapothei
Link to comment
Share on other sites

15 hours ago, Stan` said:

https://gitea.wildfiregames.com/0ad/0ad/src/commit/13453a3c7bbd31ca84c4dd6ec3e92d1f3e615648/binaries/data/mods/public/simulation/templates/structures/han/civil_centre.xml#L5 That's this value that drives the height. (You cannot change the <Square depth="35.0" width="43.0"/> though as it will mess up with the blue outline)

I'm on linux using flatpak, tried various things:
- Searched for the file, in which I needed permission to enter to the /var/
- Found the 3.6gb file in a /flatpak/, Decompress the zip file, edit the file, compress it 1.8gb = Missmatch compress = Error won't load 
- Made my own mod, following community mod = It doesn't register.
- Dismantle community mod, removing what I don't need and edit the zip file inside by overwriting without decompressing it = Works
So uh... it seems the height is not editable, its locked somewhat. Tried editing the house height too but it also doesn't work.
Other stuffs I can change like the name, resource, description even the border.

2090113878_Funny1.thumb.png.e6b13b3b237ca8bc829a11ef0e1821bb.png

Here's the normal file, the height is set to 1, yet in game it doesn't register.
The name registers, Guan Zhu instead of Guan Shu.

city-councel-boundary-fix.zip mod.json

Edited by Tapothei
Link to comment
Share on other sites

Noice, I'll be sharing the files later. I'll be including all CC. Since I notice also some are not clickable.

21 hours ago, Stan` said:

Not sure what the height is for then...

It seems the height will be applied only after the code:

  <VisualActor>
   <SelectionShape>
      <Footprint/>
    </SelectionShape>
  </VisualActor>

This was supposed to happen with the <Height>8.0</Height> if the code was applied.
Expected.thumb.png.f72532c18b58d001ec63462e3b4b29d5.png

This is <Height>1.0</Height> which is my preference.

Noice.thumb.png.e67d6b1ee13db222d785a2b4472fcae0.png

Thank you @phosityou are such a bro.

Edit:
- Done with the default, more info; Some of them don't state the height, Persians stays the same...(you can edit the height to 8)
- Next my preference. now its proper with similar height of 1, every CC.
Extra info:
Mod.js is inside the zip, if need to, just copy it outside together with the zip.
Removed cached.xmb, since no error occur in the better version, if it does there is a copy in the default version.
I'll come back and tweak the files at some point, by editing this thread.
If error occurs, I don't know bro, just ask this thread.
Good luck have fun amigos.
@Stan`request to also move this thread to Game Modification, thank you.

barebone-civil-centre-boundary.zip

default-civil-centre-boundary-fix.zip

better-civil-centre-boundary.zip

Edited by Tapothei
Link to comment
Share on other sites

Hmm... now this is a problem, how do I play multiplayer with this...
Please this is a QOL type of mod... I don't like the way Han's CC blocks my right click... xd.
I'm so tired, anyways single player rejoice! Have a good day/night.

Link to comment
Share on other sites

2 hours ago, Tapothei said:

Hmm... now this is a problem, how do I play multiplayer with this...
Please this is a QOL type of mod... I don't like the way Han's CC blocks my right click... xd.
I'm so tired, anyways single player rejoice! Have a good day/night.

Well you touched serialized components, so my guess would be that you will go out of sync, sorry. So few options

- Get the community mod people onboard with this @real_tabasco_sauce

- Submit your own mod to mod.io

- Get it merged for R29 next year.

  • Like 1
Link to comment
Share on other sites

The Han CC is particularly egregious because of its sloped design. BTW @Tapothei it used to be that the garrison flags would make the height even taller, so what you see in a27 is better than it used to be.

It would be great if we could make some changes to accept multiple rectangular prisms as selection volumes, but until then, I could go through particularly problematic buildings and trim some height.

  • Like 1
Link to comment
Share on other sites

14 hours ago, Stan` said:

- Get the community mod people onboard with this @real_tabasco_sauce

- Submit your own mod to mod.io

- Get it merged for R29 next year.

If they can integrate them to the mod that would be great, however I don't use that mod currently since I want to experience mostly vanilla.

Will do that, but if I ever leave and the mod is still needed, then will give the author to someone.

Looking forward to it.

11 hours ago, real_tabasco_sauce said:

it used to be that the garrison flags would make the height even taller, so what you see in a27 is better than it used to be.

oof, I would cry like the fox if I was there.

Edit: In case you didn't notice I've updated the file(Forgot to remove in the Han CC name Zhu and WONDERMAN text), be sure to grab the better version.
I'm waiting for the appeal of mod.io will be sending the link once accepted, from there the info is detailed. But in simpleton Barebone is the code inputed without changing height, Default makes all height to 8, Better set all height to 1.

Edited by Tapothei
Link to comment
Share on other sites

  • 1 month later...

So A28 has been updated for my linux, then I'll be updating German's CC Boundary Box.
For the future me or any linux modders(Debian), to obtain the zip file for 0AD(flatpak-3.5gb) which you can disect later.
Go to terminal type nautilus admin:/ then in files go to var/lib/flatpak/app/com/play.0ad.zeroad/current/active/files/share/games/0ad/mods/public.
Then copy public.zip to anywhere you want, in my case its download and there you have it.

Hmm when I go to editor, it crashes, I've checked CC changes and Rome is the only effected.
Fixed it, now its working properly as well as included German's CC.
I mean the code can be clean but I'll leave it to the programmers grey beard's wisdom of placing it properly.
Please integrate this to A29, so I can play it in multiplayer.
To be honest, the CC is big so the height being 1.0 is pretty much enough, all you need is clicking the ground.

Edit: Followed Stan's suggestion and made one.

bet-civ-cen-bou.zip

Edited by Tapothei
  • Thanks 1
Link to comment
Share on other sites

  • Tapothei changed the title to Better Civil Centre Boundary

Hey @Tapothei!, thanks for working on this.

If you'd like, you can even go a step further and open the Pull Request yourself.
That would make things easier, since you wouldn’t need to rely on someone else to do it.
Of course, this isn’t mandatory.

Here is a guide to get the latest code and how to compile it
And here's the commit guidelines

Keep in mind that opening a PR doesn’t guarantee that the code will be merged. :)

Edited by guerringuerrin
typos
Link to comment
Share on other sites

16 minutes ago, guerringuerrin said:

@Tapothei!If you'd like, you can even go a step further and open the Pull Request yourself.

Here is a guide to get the latest code and how to compile it
And here's the commit guidelines

Keep in mind that opening a PR doesn’t guarantee that the code will be merged. :)

Cough* I tried to but its not available for me, since its my first contribution, and I don't know github works other then sending report issues.

I'm not a coder.... compiling is too difficult for my brain... commit guideline, I'll be sure to understand it later.

Understandable, thank you for giving me a reality check, I must weep near the ocean. Oh sea swept me away~!

Blocked.jpg

Edited by Tapothei
  • Like 1
Link to comment
Share on other sites

On 03/03/2026 at 6:04 AM, Tapothei said:

Cough* I tried to but its not available for me, since its my first contribution, and I don't know github works other then sending report issues.

I'm not a coder.... compiling is too difficult for my brain... commit guideline, I'll be sure to understand it later.

Understandable, thank you for giving me a reality check, I must weep near the ocean. Oh sea swept me away~!

Blocked.jpg

Neither did most of us, but Gitea isn't too hard to figure out especially if you use something like VS code or codium 

Link to comment
Share on other sites

7 hours ago, ShadowOfHassen said:

Neither did most of us, but Gitea isn't too hard to figure out especially if you use something like VS code or codium 

Thx for the push, also I don't use either of them, I just have my default text editor.
This took me awhile to understand(somewhat a partial comprehend)... and now after that it request for checks... man I'm so exhausted...

  • Thanks 1
Link to comment
Share on other sites

That was fast, @Tapothei!
Thanks for putting in the effort to learn how to create a PR. Eventually, you'll get familiar with the workflow:

The usual workflow is to fork the repository, clone your fork locally, and create a branch for your changes ( You don't want to work directly on the website for practical reasons). You commit your work and push the branch to your fork. Each contributor works on their own fork. Once the changes are ready, you open a pull request from your branch to the upstream repository, where the maintainers can review it.

Also, right now your changes are on the main branch of your repository. `Check this:

Spoiler

image.thumb.png.6e2b40632e235a9ab124595853413aa4.png


Normally main should not be used for development. Instead, it is kept in sync with upstream (the official 0 A.D. repository), and new changes are developed in separate branches. Pull requests are then opened from those branches. 
This is an example of a PR from another contributor, notice his PR comes from another branch, called "lazy-actual-size":

Spoiler

image.thumb.png.0f3e366b8fa7e175831992703b35fbd0.png

This way your main branch always stays clean and can be used to create new branches. Otherwise, if main contains previous work that wasn’t merged, those changes could end up included again in future pull requests. An if you later want to work on something else and sync your main branch with upstream, you may run into problems because git will detect local changes that don’t match upstream.

By creating separate branches from main, you isolate each set of changes. This makes it easier to keep main clean, revisit your work later, and work on multiple things in parallel.



I also noticed that your PR contains many separate commits. Like this:

Spoiler

image.thumb.png.b791bb76228632c3d049602248ef8539.png


In these cases, it is usually recommended to squash (git command) them into a single commit. This makes it easier for maintainers to review the changes and keep a clean history of the proposed modifications.

 

I know this might seem completely confusing right now. But if you plan to keep contributing, learning it will make things much easier in the long run.It can take months and plenty of frustration to get comfortable with the basics of git. So if you decide to learn it, be patient with yourself. It gets a little easier every day.


Well, I don’t want to overwhelm you any further. You’ve already made it this far, and that’s worth recognizing. Thank you!

 

2 hours ago, Tapothei said:

I just have my default text editor.

You could get a source-code editor like Visual Studio Code to make things easier for you.
Also, when creating a PR that solves an issue, you normally want to include this in the PR message like this: "Fixes #8781"


 

Edited by guerringuerrin
adding some more tips
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...