Automate the UOAM map file for UOR houses

Discussion in 'Renaissance Discussion' started by Quick, Apr 2, 2018.

  1. Chadarius

    Chadarius Active Member
    UO:R Subscriber

    Joined:
    Nov 7, 2015
    Messages:
    118
    Likes Received:
    97
  2. Quick

    Quick Well-Known Member
    UO:R Donor

    Joined:
    Jan 6, 2018
    Messages:
    534
    Likes Received:
    1,136
    My understanding is that the process that generates the house file and item database info is down at the moment and will be fixed next patch. The last update I believe is from 2/9.
    Ahirman likes this.
  3. Chadarius

    Chadarius Active Member
    UO:R Subscriber

    Joined:
    Nov 7, 2015
    Messages:
    118
    Likes Received:
    97
    Hey @Quick I did a thing! I started messing around with your powershell script and downloaded and scaled some house icons. The ClassicUO World Map doesn't scale the icons with the zoom so things can get a little weird.

    [​IMG]

    I only had to change a few lines in your script.
    First the file path for ClassicUO World Map files

    Code:
    $UOAMHousesFile = "C:\UORenaissance\ClassicUO\Data\Client\UORHouses.csv"
    Then the offsets

    Code:
    $HouseOffsets = @{
        "castle"          = "0,-5";
        "fortress"        = "0,-5";
        "keep"            = "0,-5";
        "large house"     = "0,-5";
        "log cabin"       = "0,-5";
        "marble patio"    = "0,-5";
        "marble shop"     = "0,-5";
        "patio house"     = "0,-5";
        "sandstone patio" = "0,-6";
        "small house"     = "0,-5";
        "small tower"     = "0,-5";
        "stone shop"      = "0,-5";
        "tower"           = "0,-5";
        "two story house" = "0,-5";
        "villa"           = "0,-5";
    }
    
    The the output line.
    Code:
    "$NewXPosition,$NewYPosition,0,$HouseType,$HouseType,yellow,7" | Out-File -FilePath $UOAMHousesFile -Encoding ASCII -Append
    Here are the scaled png files I used. I just downloaded the pictures from the compendium and scaled them. So they are very close to correct at a certain zoom level. https://nextcloud.suttonsassemble.com/s/2SeCXjiX3r59xi9. Just pop those into "C:\UORenaissance\ClassicUO\Data\Client\MapIcons" and it should just work. They all started out as 100x100 and I adjusted them to fit a little better. Its probably not perfect yet but it is getting closer!

    If anyone else wants to help mess with this and test I think we could probably create something that works OK and would be a great replacement of the awesome UOAM functionality. We probably just need to tweek the icon scaling a little and perhaps the offsets a little. My kids were very excited by this because they remember how cool UOAM was and they miss it a little bit. :)

    Really the only thing stopping this from being totally amazing is the icon scaling in the ClassicUO World Map. Maybe there is a work around or a tweak? I haven't looked into that much yet.
    Last edited: Sep 15, 2020
    Quick and Ahirman like this.
  4. Chadarius

    Chadarius Active Member
    UO:R Subscriber

    Joined:
    Nov 7, 2015
    Messages:
    118
    Likes Received:
    97
    For some reason the "marble shop" wasn't picking up the "marble shop.png" icon. It was because I had a "marble shop.cur" icon also. So don't be a dumb like me and make sure you only have the house names with .png extensions! :)
    Buga likes this.
  5. silencesg

    silencesg Active Member
    UO:R Donor

    Joined:
    Dec 20, 2017
    Messages:
    142
    Likes Received:
    88
    this looks awesome!!

    can someone explain slowly how i can do this with my limited knowledge of anything.

    using CUO client
  6. Chadarius

    Chadarius Active Member
    UO:R Subscriber

    Joined:
    Nov 7, 2015
    Messages:
    118
    Likes Received:
    97
    Buga likes this.
  7. Chadarius

    Chadarius Active Member
    UO:R Subscriber

    Joined:
    Nov 7, 2015
    Messages:
    118
    Likes Received:
    97
    I have updated the WorldMap UORHousePositions.ps1 project at https://github.com/Chadarius/uorhousepositions/tree/worldmap.

    I added -UseBasicParsing to the Invoke-WebRequest to avoid issues on workstations where Internet Explorer is not available or not configured. It happened on my daughter's computer when I tried to run it so I thought I had better fix it so no one else runs into the problem!

    I will probably make a quick video on how to install and use it tomorrow and post here too. :)

Share This Page