Jump to content

Hammelpilaw

Members
  • Posts

    595
  • Joined

  • Last visited

  • Days Won

    2

Posts posted by Hammelpilaw

  1. Let me improve the comments of my example mine.lua:

     

    local MyModTemplateFindMinedAsteroid = AIMine.findMinedAsteroid -- Save original function in a local variable
    function AIMine.findMinedAsteroid() -- Override original function; we still have it in 'MyModTemplateFindMinedAsteroid'
        -- Add some custom code here...
        
        if myCustomVariable == true then -- When this is true, skip searching for asteroids, but do not throw warnings to player
            noAsteroidsLeft = true
            noAsteroidsLeftTimer = 10 * 60 -- ten minutes
            
            ShipAI():setPassive()
        else
            -- Execute original function, we stored before
            -- You could skip this to completely override it, but that may decrease mod compatibility to other mods. Sometimes its required though
            MyModTemplateFindMinedAsteroid()
        end
        -- Add more custom code here
    end

     

    I think that should make it clear. If not feel free to ask.

     

  2. Am I overthinking this and missing something simple?

     

    If you just want to change the existing mine command, yes. You dont have to modify these:

    data/scripts/entity/craftorders.lua
    data/scripts/player/map/mapcommands.lua

     

    You can simply overwride just the mine.lua like I did in the attached example. This will modify the vanilla game file. All other scripts and the game itself will use the modded script this way.

    miningExample.zip

  3. Ah got it. Did anything wrong yesterday.

     

    As far as I can see you can reproduce even easier. Let me describe this a bit more accurate:

     

    • Have a ship with 30 blocks or less
    • Be outside of the ship (drone or in another ship)
    • Enter build mode (neutral)
    • Ship is not visible

     

    Some weird behavior:

     

    • Add blocks until ship has 31 blocks -> ship appears
    • Remove one block -> ship disappears
    • Block type, size or material does not affect it

    It is not related to newly founded ships or so, only to the block amount.

     

  4. The new client frame log is bugged on windows. Backspaces in windows paths mistakely escapes the following char, wich leads to a parse error:

     

    SyntaxError: JSON.parse: bad escaped character at line 59184 column 89 of the JSON data

     

    Here the related line of the file (file is too big, can upload with external tool if required):

     

    {"pid":1,"args":{"selectable":"yup"},"ph":"X","tid":1,"ts":27104521,"dur":12,"name":"S:\Games S\Steam\steamapps\workshop\content\445220\1722256729\data/scripts/entity/sectoroverview.lua"},

  5. we will see.  I would like to do that, but it's not my mod originally.

     

    The author has not been here since 2017.You could just add him to credits and mention that in the description.

  6. a great mod - if u ask me.

    so i did a little work,

    and now we have a working version, again  ;)

     

    Awesome  :) Planning to update it for workshop mod support?

  7. I was curious if there is a way to add a way to add a turret Slot size factor to the search ?

    [edit]

    Just though that the range could be usefull too

    [/edit]

     

    Would be usefull for those ships with smaller turrets slots or just being smaller and using smaller turrets. And finding

    those long range salvage and other turrets

     

    Thanks for any tip on how to do it.

     

    Thanks for sharing your ideas. Although I did not publish any update to this mod for some months I still plan to highly improve it in future. Im very sorry to let you wait so long for updates, but right now a lot of new stuff is annaunced to scripting API, like Steam workshop mods. So I currently focus on the upcoming worshop mods, not on adding new features, but they will come - sooner or later.

  8. I agree. And I somehow got -120k by killing one big NPC defender ship in the starting sector! Maybe formula on C++ side needs to be removed or changed in favor of the Lua formula?

     

    The 2 formulas do 2 different things. relationschanges.lua only handles killing traders, the C one handles damage on npc entities. Im not sure if the C one should be move into scripts... thinking of performance when every shot takes a lot more calculations via scripts instead of compiled C code. Wouldnt it be enaugh to improve the C code? Wich leads back to the bug report.

  9. I can confirm this very rare issue. But I have absolutely no idea how to reproduce. Its been ingame for months or years, cant say. Its some months ago it happened last time to me.

     

    What I can say is, that when the sector gets unloaded and later be restored from disk, the station will work again without any issue.

     

    To me it did not seem to be related to the maximum cargo, I remember having same issue with much more then 100 goods. But I may be wrong... its long ago.

     

    Could not confirm this on player stations yet, only on npc stations. Although it does not mean for sure it does not exist for player stations.

  10. I'm sorry, but this is getting pretty restrictive.  Have you at least made cargo shuttles able to automatically collect loot and raw materials like they're supposed to?  That would allow a reasonable workaround for mining carriers in the meantime, until they can manage to jump through all these new hoops you're throwing at them.

     

    You still can use the refined mining/salvaging lasers. But hmm... well maybe the efficiency of refined laser is reduced a very little bit too much... I think an efficiency for refined mining lasers like 20-50% sounds good, and for refined salvaging like 7-24%.

     

    At all I really like the efficiency bonus of the raw laser compared to the refined ones. But ingame it looks like that: when starting in a new galaxy you have to farm material the hard way cause cargo for raw materials is rare, credits for turning it into refined resources is rare too. This means it will be harder to start in game.

    But in endgame, you got a lot of cerdits, cargo, and can easily install the transporter upgrade to let fighters do the work for you. With even more efficiency it will buff you in endgame, but nerf you in early game. This may be lead into the wrong direction since endgame is already much to easy.

     

    Yes I think this may still need some better balancing, but the idea is really great. Will think about it on the incoming weekend  :)

     

     

×
×
  • Create New...