Jump to content

Langbart

Community Members
  • Posts

    225
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by Langbart

  1. The polygon is no longer visible outside the minimap, this was fixed by @vladislavbelov with rP25241, so mods for the current dev version and for A25 can have a nice round minimap.

    385019447d03d9014119e2257d21665d.thumb.jpg.0c7b479d27f8a4660816941e25f3a481.jpg

    On 16/03/2019 at 3:56 AM, Sebastián Gómez said:

    I'd be more than willing to help with the creation of the graphical content in case you like the idea. So please let me know what you think.

    @Sebastián Gómez are you still around, can you provide some graphical content?

    • Like 1
  2. Just now, azayrahmad said:

    I never did it before, but I'm going to try.

    1. Reading the wiki/Phabricator article helped me and it also taught me how to use Arcanist to upload my patch. 
    2. You would need someone to review your patch, here is a quote from a former developer describing the situation:
    Quote

    @elexis (8/Okt/17) wrote at patch D889:

    There are hundreds of patches disregarded in the review queue and the number increases steadily since 0AD source was published - even with multiple developers having exclusively worked more than full time on the review queue for years. [...]
    The only thing that gets a patch committed is a team member that stops working on his own feature to review something. That often means repeated begging.

    PS: Wiki doesn't seem to work properly at the moment, archive.org might be a temporary solution. Also I can't review your patch, I'm just a player/ tester and someone who learns JavaScript by modding the game. I mostly just test patches  for @wraitii or @Freagarach and write my results in Phabricator.

    • Like 1
  3. You could change your "Display" settings in "System Preferences"

    1488629725_Screenshot2021-04-12at10_19_17.thumb.jpg.6dacf1a6941b33029b4cb885c5c6165a.jpg

    or you could add gui.scale to your user.cfg file (see wiki/GameDataPaths) and play around with that number till you are happy with it.

    1096057154_Screenshot2021-04-10at07_17_35.thumb.jpg.883c30f1d09758ebcfba838560c41f6b.jpg.4d255ada37f6b208a9f0008f2ce1d0b1.jpg

    The options is currently being worked on at Phabricator and might end up in the next game version. 

    D3037 Add gui scale to options

     

    EDIT1: If you are using macOS 11, can you take a look at this thread? Looking for a macOS 11 user with missing polygon on the minimap (26/Mar/21)

     

  4. 1 hour ago, wowgetoffyourcellphone said:

    I liked the "God ray" effect from Rise & Fall: Civilizations at War

    I found it.  A bit difficult to capture it on video, I tried messing with saturation/contrast/brightness of the video but not much success. It would be a good addition, I personally prefer the effect on the statue more.

  5. Yes, you can create a mod.

    Create a folder and add a mod.json file in there. Or you could just download it from an existing mod and make small changes to it. e.g. from the "City Builder" mod on GitHub.

    Your mod.json file should look like this, a more detailed explanation can be found here: wiki/Modding_Guide

    {
    	"name": "dutch_fix",
    	"version": "1.0",
    	"label": "Dutch typo mod",
    	"description": "Fixing typos in the dutch language",
    	"dependencies": ["0ad=0.0.24"]
    }

    Next you will need the .po files, which contain the text that will be displayed in the game. Download the files from here: trac.wildfiregames.com/browser

    Create a folder called "l10n" and add all the files in it, that you have made changes to. It should look like this, you don't need all the Dutch files, just the ones you made changes to.

    248049592_Screenshot2021-04-11at16_42_22.thumb.jpg.af1746a8f3189c2083a937d837db43a3.jpg

    Add this folder to your 0AD mods folder  (see wiki/GameDataPaths) and enable the mod via the 0 A.D. "Mod Selection" page.

     1510927635_Screenshot2021-04-11at16_55_46.thumb.jpg.3d7dbb20d836ea54ac70171f28f774b9.jpg

    Now the game will call the contents of your mod before it calls the contents of the game. If you did everything correctly, you should see your changes in the game.

    1234.thumb.jpg.22d11b83d2b1f78a4083d70d19b08aa0.jpg

    • Like 1
  6. I noticed that my scout can kill any domestic animal (chicken, cow, ...) but no other animal. Shouldn't he at least be able to kill the dear wolf when attacked? 

    Edit1: Forget it, I think you have already fixed this problem with your latest update. :rolleyes:

  7. 18 hours ago, fatherbushido said:

    if you are interested,there are some similar things here (on 3900 games)

    Thanks for sharing.

    On 26/02/2021 at 11:55 AM, fatherbushido said:

    Here are some results from tests done one year ago.

    [...]

    - tested on a fork of zeroad

    What is the current status of your project?

    I read about ForkAD shortly after I joined the forum, and haven't heard anything about it since. From reading the "Wildfire Games Meetings" (9/Jun/19), I understand that there was at least an intention to cooperate:

    What's going on?

    • Like 1
  8. 35 minutes ago, wowgetoffyourcellphone said:

    I believe that is in the works. There is a patch for it already.

    I think it this one D3037 Add gui scale to options 

    In the meantime, you could try finding your user.cfg file (see wiki/GameDataPaths) and add gui.scale to it. Play around with this number until it suits your purpose.

    1096057154_Screenshot2021-04-10at07_17_35.thumb.jpg.883c30f1d09758ebcfba838560c41f6b.jpg

    I was going to add this to my mod, but haven't done it yet.

    PS: another nice quality of life gain, was the discovery of the hotkey section (see wiki/HotKeys), especially those:

    Change speed of scrolling, rotating and zooming.

    • scroll.speed.increase = "Ctrl+Shift+S" 
    • scroll.speed.decrease = "Ctrl+Alt+S" 
    • rotate.speed.increase = "Ctrl+Shift+R" 
    • rotate.speed.decrease = "Ctrl+Alt+R" 
    • zoom.speed.increase = "Ctrl+Shift+Z" 
    • zoom.speed.decrease = "Ctrl+Alt+Z" 
  9. I followed the instructions from the article wiki/GettingStartedReinforcementLearning, but I run into an issue after this command

    picus@Picus zero_ad_rl-master % python3 -m zero_ad_rl.train --help
    
    Traceback (most recent call last):
      File "/Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/runpy.py", line 193, in _run_module_as_main
        return _run_code(code, main_globals, None,
      File "/Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/runpy.py", line 86, in _run_code
        exec(code, run_globals)
      File "/Users/picus/0ad/source/tools/rlclient/zero_ad_rl-master/zero_ad_rl/train.py", line 5, in <module>
        from ray.rllib.train import create_parser, run
      File "/Library/Python/3.8/site-packages/ray/__init__.py", line 63, in <module>
        import ray._raylet  # noqa: E402
      File "python/ray/_raylet.pyx", line 20, in init ray._raylet
    ImportError: dlopen(/Library/Python/3.8/site-packages/ray/thirdparty_files/setproctitle.cpython-38-darwin.so, 2): Symbol not found: _Py_GetArgcArgv
      Referenced from: /Library/Python/3.8/site-packages/ray/thirdparty_files/setproctitle.cpython-38-darwin.so
      Expected in: flat namespace
     in /Library/Python/3.8/site-packages/ray/thirdparty_files/setproctitle.cpython-38-darwin.so
    picus@Picus zero_ad_rl-master % 

    Procedure macOS 10.15.7 (8/Apr/21)

    Spoiler

    Download & Install 0ad

    Download & Install Python 3.8

    • Install Homebrew and Python@3.8
      • I had to install "python@3.8" because "python@3.9" did not work for me. Make sure you uninstall "python@3.9" completely, otherwise I had problems installing "ray". (See docs.ray.io/en/master/installation.html)

    Install 'zero_ad' Python Client

    • navigate to this folder in the 0 A.D. source folder.
      • ~/0ad/source/tools/rlclient/python
    • run
      • sudo -H python3 -m pip install .
      • Confirmation message: Successfully installed zero-ad-0.0.1
    • run
      • sudo -H python3 -m pip install -r requirements-dev.txt
      • Confirmation message: Successfully installed iniconfig-1.1.1 pluggy-0.13.1 py-1.10.0 pytest-6.2.3 toml-0.10.2
    • running tests
      • 0ad/binaries/system/pyrogenesis --rl-interface=127.0.0.1:6000 --autostart-nonvisual --mod=public
      • python3 -m pytest
      • Output
        • picus@Picus python % python3 -m pytest
          ============================== test session starts ===============================


          platform darwin -- Python 3.8.2, pytest-6.2.3, py-1.10.0, pluggy-0.13.1
          rootdir: /Users/picus/0ad/source/tools/rlclient/python
          collected 10 items

          tests/test_actions.py ...... [ 60%]
          tests/test_evaluate.py .... [100%]

          ============================== 10 passed in 22.50s ===============================

    • We can check that our installation worked by running one of the example scripts.
      • python3 ./simple-example.py
      • Output
        • picus@Picus samples % python3 ./simple-example.py
          female citizen's max health is 34.99985
          {'id': 4753, 'template': 'units/spart/support_female_citizen', 'position': [612.9468231201172, 619.9051971435547], 'angle': 0.756927490234375, 'hitpoints': 34.99985, 'invulnerability': False, 'owner': 1, 'idle': False, 'stance': 'passive', 'unitAIState': 'INDIVIDUAL.REPAIR.APPROACHING', 'unitAIOrderData': [{'target': 4776, 'autocontinue': True, 'force': True}], 'resourceCarrying': [], 'garrisonHolderID': 0}

    Download & Install 'zero_ad_rl'

    • Download "zero_ad_rl" from here: github.com/brollb/zero_ad_rl 
      • First install the “ray[rllib]” and then install "zero_ad_rl" via command
      • sudo -H python3 -m pip install 'ray[rllib]' (pypi.org/project/ray/)
      • sudo -H python3 -m pip install -e .
      • Confirmation message: Successfully installed zero-ad-rl
    • In the "zero_ad_rl" folder you will find a zip file named '0ad_rl_maps.zip', unzip it and change the name of the folder from "0ad_rl_maps" to "rl-scenarios" and add it to your 0ad mods folder (the mod.json file names this mod "rl-scenarios", but if the mod folder is not changed as well, the maps will not be displayed).
      • if you open the game with the mod enabled you should see under Scenario some new maps e.g. "Cavalry Vs Spearmen" or "Cavalry Vs Slingers"
      • Some maps use the old version 6 in their XML files, you have to update them from version 6 to version 7 with Phab:P232 otherwise it will fail
        • But after I did that I still get 'entity' and 'CCacheLoader' errors for maps like "CavalaryVSInfantry", only "CavalryVsSlingers.xml" and "CavalryVsSpearmen.xml" worked for me.
      • UPDATE: Stan fixed this problem, by updating the maps 

    Training our agent

    • pyrogenesis --rl-interface=127.0.0.1:6000 --autostart-nonvisual --mod=rl-scenarios --mod=public
    • python3 -m zero_ad_rl.train --help
      • error 

    UPDATE: As described here (github.com/ray-project/ray/issues/10428), it does work with 3.8.5 but not with 3.8.9 (the current python@3.8 homebrew version)

  10. 1 hour ago, fasl said:

    This was the latest github version downloaded yesterday... Really unsure what I did wrong. I installed in the my documents/my games/0ad/mods and enabled in mod manager. Thanks for your help with this

    Seems like a small mistake probably be fixed very soon.

    /delenda_est/simulation/data/civs/sueb.json

    12.thumb.jpg.76267ee54995b036819fe82ba787d7f8.jpg

    • Like 1
    • Thanks 1
  11. Recently a macOS 11 user reported in IRC #0ad being unable to see the polygon on the minimap, it would be helpful to solve this problem if someone with Alpha 24 on macOS 11 could reach out to @vladislavbelov or me. You would only have to install Apitrace, which is a tool for tracing OpenGL, Direct3D, and other graphics APIs.

    Installation and procedure is a manageable task. 

    macos_cursor-1.thumb.jpg.58a46b123a5b6097d3d830ce7eab53f7.jpg

    • Thanks 1
  12. 8 hours ago, cl2488 said:

    What is port forwarding? Can you explain more about it? How to do port forwarding in a Mac?

    I regularly get requests from users on #0ad asking for help with this problem, below is a small collection of other websites. I will probably send them the link to this thread so they can more easily find out what port forwarding is and how to do it. Thanks for asking.

    portforward.com - How To Forward a Port

    Quote

    A port forward is a way of making a computer on your home or business network accessible to computers on the internet, even though they are behind a router. It is commonly used in gaming, security camera setup, voice over ip, and downloading files. After you have forwarded a port you are said to have an open port.

     computer.howstuffworks.com -  How BitTorrent Works

    Quote

    A firewall protects your system from intruders by disallowing unauthorized access to your computer's ports. A port is a way for Internet communications to travel into and out of your computer. Ports are numbered, and each communication type has a standard port number. BitTorrent also uses specific port numbers, normally ports 6881 through 6889. Because firewalls block these ports by default, you'll need to configure your firewall to accept this incoming traffic in order to receive .torrent files. You may also have to enable port forwarding of your computer's IP address for ports 6881 through 6889 so that other BitTorrent computers can find you.

    r/explainlikeimfive (18/Aug/2018) - ELI5: What are ports? Port forwarding? What are they and what are they used for?

    Quote

    Any internet device has an IP address (something like 198.51.63.25). Think of it like a house. And you can go out and visit other houses or you could even get visitors to your house.

    Now to enter a house you, of course, the house needs doors. And your "internet house" has 65535 of them. Most of them remain closed the whole time (web servers mostly have ports 80 (http) and 443 (https) open). All open ports lead to a room. Two may even lead to the same room. It's all a matter of configuration.

    So in order to let someone in your house, you need to open a door so they can come in.

    Many ports have standardised purposes like for example:

    • 21 - FTP (File Transfer Protocol)
    • 22 - SSH (A protocol to connect to other computers/servers to control the system or some parts of a system)
    • 80 - HTTP (All websites which don't have a green lock in the address bar)
    • 443 - HTTPS (All websites which have a green lock in the address bar)

    stackoverflow.com (5/9/2012) - When is port forwarding necessary?

    Quote

    Port forwarding is needed when a machine on the Internet needs to initiate a connection to a machine that's behind a firewall or NAT router. If the connection is initiated by the machine behind the firewall, the firewall/router automatically recognizes the reply traffic and sends it to the machine that opened the connection.

    But if a packet arrives on the external interface, and it's not a part of such a connection, the router needs to know what to do with it. By default, it will reject it. But if forwarding is configured for the port, that tells it what internal machine to send it to.

    Put another way: you need port forwarding if you want to run a server behind the NAT firewall/router, you don't need it if you're just running a client.

     

  13. #5306 UDP Problem 

    @elexis wrote this:

    Quote

    If you forward the port, everyone will be able to join you. If you use STUN when hosting, probably many but not everyone will be able to join you. If you can't join someone else's game, there's nothing you can do about it other than informing the host that he should forward or host your own game.

    Port forwarding looks like this on my router, it might look different on yours. 
    989753182_Screenshot2021-03-23at02_51_04.thumb.jpg.7b584144b5344ecf9839ebc3bab81f50.jpg

×
×
  • Create New...