Jump to content

Recommended Posts

7 hours ago, Sequani said:

@SeleucidsHi ! The mod doesnt work for me. I installed it alright (I guess), but when launching a game, the numbers doesnt change. Is there anything I should do ? Im on windows. 

Hi, I believe that if you clone from nani's latest repository https://github.com/nanihadesuka/autociv/tree/master

You should not encounter this problem. I will look into this.

Link to comment
Share on other sites

35 minutes ago, Sequani said:

Well, I don't get it x) But I finnaly made the 27.0.2 version working, doing the same thing over and over again.

I just built a new release, 27.0.4. Please check if you can download that. You can install the mod from its source code in the link above, by downloading it as a zip. Newest version is 27.0.4

 

That 27.0.2 you have is very outdated 

Edited by Seleucids
Link to comment
Share on other sites

28 minutes ago, Seleucids said:

I just built a new release, 27.0.4. Please check if you can download that. You can install the mod from its source code in the link above, by downloading it as a zip. Newest version is 27.0.4

 

That 27.0.2 you have is very outdated 

Yea, all working now, ty :) 

Link to comment
Share on other sites

  • 1 month later...

New update: Additional camera settings:

image.thumb.png.5c4bd40e5d7dd14bc34e11e91fe54dcf.png

These are configurable options that are normally hidden from the settings interface, presumably because it might confuse new players. However, I personally found these camera settings to be essential for players improve their micro. 

 

In short: 

  • Scroll speed changes how fast your camera pans around the map when you press WASD. The value is the speed of the camera in m/s and the default was 120. I personally use 620 so that I can quickly move myself around my base. I allow up to 1000 but that's a bit too crazy for me. 
  • The zoom options control your altitude from the map. Default minimum is 50, but if you have a high resolution screen, you can still see content clearly for up to 10 or even 8. 
  • FOV = Field of view

 

 

 

 

  • Like 3
  • Thanks 2
Link to comment
Share on other sites

New feature: added an options button to the lobby that launches the settings page in an async subroutine

image.png.e51a796980ed1a0417744c47ef2fa4e1.png

In the base game, there is no way to change your settings once you are logged into the lobby! This provides you with the possibility of adjusting settings to optimum before game starts. 

If you have reached the gamesetup page, you can press Alt + L to launch the lobby page then press on Options. 

  • Like 4
  • Thanks 1
Link to comment
Share on other sites

Bug fix and adjustments: 

  1. Statistics counter used to crash when you switch the perspective to Gaia, because the original rating symbolism code couldn't handle gaia's null value. My solution was to give Gaia a rating of 1200 and that prevented the crash. 
  2. Player overlay was overcrowded with incidences of long names being split between lines or 2 short player names on one line. Now, I implemented an AoE style overlay without the shadows, restricting to 1 line per player. I also separated out the sections of Spectators and Missing Players
  3. Deleted some unused functions and variables to decrease performance impact. 
  4. Return of Max and Min colour highlighting

image.thumb.png.381a7feeaab947dd875863d5facb893f.png


A new release has been built for the aforementioned changes; we are now on 27.0.5

The build environment was changed to Ubuntu 22.04 because GitHub removed Ubuntu 20.04 on 15th April 2025. This shouldn't affect any users, especially if you clone the code from source. 

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

Minor change: I aligned the spectator names to the right side of the panel and truncated the maximum length of names to 20 characters. This prevents players with extra-long names (especially customrating users) to take up too much of your screen. 

 

I have also started an A28 branch on the git repo; this branch aims to be compatible with the A28 game under development. There are some changes to engine code and general layout of code, which would cause incompatibility with the A27 version. This A28 branch contains most of the A27 features already and can be used when you are doing test plays on A28 dev version. 

image.thumb.png.1e814abc10bb482c0ead3282e24e38db.png

 

Edited by Seleucids
Link to comment
Share on other sites

I can answer, even if I'm not nani. Very important questions - which eventually can be rephrased as "why use proxies?". I hope the rest of this post will clarify. There are various reasons, I'll just state the two I find most important.

One reason is compatibility with other mods. Imagine two mods overwriting the same init function: then, only the last loaded mod will work, whereas the first loaded mod will not work - not nice for users. Additionally: if you develop a mod, you expect to develop your code based on options.js from the public mod, right? But if this file is replaced by some arbitrary custom file, you can never know if your code will work properly. In other words, if you want your mod to be compatible with other mods, then you should let the other files exist, and not overwrite them.

Another reason is compatibility with 0 A.D. itself. When a new patch or version of the public mod is released, it may happen that options.js gets changed too, as part of the update. If so, you (the mod developer) must take care of replacing that file too, and release a new version of your mod with the new file. And you have to do the same will all other files that have changed... dirty job indeed! Instead, if you build your mod around existing files, your code will (most likely) work straightforward - without having to check for all files that have changed and replace them one by one.

 

So, what does it mean to build around existing files? And what should modders do? Answer is: use PROXIES! Javascript Proxies (similar to Python decorators - I seem to remember you like Python) ensure that modded objects wrap existing objects without overwriting them.

An example: by using a proxy, you can run your custom init function after, before or around the original init function. And this is exactly what happens inside options~autociv.js! patchApplyN is a brilliant example of a proxy: it executes custom code around the original init function in options.js.

You can find another concrete example of a proxy for the init function in options.js here.

On 15/05/2025 at 11:55 AM, Seleucids said:

Some of these files are causing funny bugs such as not allowing the user to leave a page.

Most likely, it is caused by another mod which replaces existing objects/functions/variables/etc. - and if this is the case, you can gently ask the author to get acquainted with proxies. :)

  • Thanks 1
  • Haha 1
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...