Jump to content

Rinart73

Members
  • Posts

    416
  • Joined

  • Last visited

  • Days Won

    4

Everything posted by Rinart73

  1. Currently there is a problem on multiplayer servers - when you jump into a sector, it may take some time (quite a lot if the sector is big) for player to load data and resources. But during this time ship is vulnerable. My suggestion is: Make ship invincible while player is loading resources. Since this happens on clientside, game will need to get a signal from client that everything is loaded. To prevent cheating I suggest to ignore all player actions until they will send 'sector is loaded' message. After that game will make ship vulnerable again. Optinally, It would be nice to have a serverside callback for that too.
  2. 0.19.1 I'm using "Server():setValue" to implement important player to player interactions on Rusty's Galaxy servers. Values are not big - they're either boolean or numbers. The problem is that after some time these variables reset. And they shouldn't. Mog logs doesn't show that they were resetted by players. You said that I can store as many variables as I want. Are you sure? Please check it.
  3. 2018-10-31 10-08-00| error constructing Entity: Entity with index "7242ff47-b7a8-43ab-822b-9c3cb9e26635" doesn't exist at 2018-10-31 10-08-00| stack traceback: 2018-10-31 10-08-00| [C]:-1: in function Entity 2018-10-31 10-08-00| data/scripts/entity/merchants/factory.lua:1306: in function updateDeliveryShuttleStarts 2018-10-31 10-08-00| data/scripts/entity/merchants/factory.lua:1102: in function ? 2018-10-31 10-08-00| So I think the reason why this error happens is because you're trying to construct an deleted entity instead of trying to search it in a sector: So replacing this: local station = Entity(id) with this should help: local station = Sector():getEntity(Uuid(id)) The same should be done on lines: 902, 919, 1241, 1254, 1396 UPD: I think this has been reported already in this thread. UPD: Fixed the code
  4. To be honest, this is a really old thread. But some of the things that I noticed: Not sure that this is possible, since "calculation" is really a time while server loads or generates a sector. Open Galaxy Map, in the left top corner you can find a seach box. Fair warning, it's case-sensitive if you're playing in language that is different from English. Look at the Keybindings in the settings. I'm pretty sure there were hotkeys. Again, look at the Keybindings. If I remember correctly it's F9 by default. Devs said that it will be in the next update
  5. File "mods\MilitaryMissions\scripts\player\missions\pirateWarlord.lua" - please add local generator = require ("shipgenerator") Otherwise lines 64-70 will throw an error: PirateGenerator.createRaider(generator:getPositionInSector(5000)) for i = 1, numShips do PirateGenerator.createMarauder(generator:getPositionInSector(5000)) PirateGenerator.createPirate(generator:getPositionInSector(5000)) PirateGenerator.createBandit(generator:getPositionInSector(5000)) end --- Also, just curious, why the update interval is 5 times per second instead of 1 per second like the default one? function MilitaryOutpost.getUpdateInterval() return 0.2--1 end I'm asking because on the Rusty's Galaxy servers "data/scripts/entity/merchants/militaryoutpost.lua" takes 1st-3rd place by execution time and I'm not sure why. Maybe because of this? Or because when sectors loads game tries to simulate 50 minutes of bulletin changes. I get that it's vanilla behaviour but maybe something can be done here? local minutesSimulated = 50 for i = 1, minutesSimulated do -- simulate bulletin posting / removing MilitaryOutpost.updateBulletins(60) end UPD: Maybe replace it with something like this? local minutesSimulated = 50 minutesSimulated = minutesSimulated * 60 -- convert to seconds local simulations = math.floor(minutesSimulated / updateFrequency) minutesSimulated = minutesSimulated - simulations * updateFrequency for i = 1, simulations do -- simulate bulletin posting / removing MilitaryOutpost.updateBulletins(updateFrequency) end -- add the rest MilitaryOutpost.updateBulletins(minutesSimulated) This way with "updateFrequency = 60 * 30" and "minutesSimulated = 50" we will call "MilitaryOutpost.updateBulletins" function only two times. First we will pass "updateFrequency" as an argument which will result in update. Second - the rest of it (60 * 20 seconds)
  6. Mining System will highlight asteroids for every player in the sector, even if they're not in the ship that has this upgrade installed. How to fix: In "data\scripts\systems\miningsystem.lua", function "onPreRenderHud": Replace line if not player.craftIndex == ship.index then return end with if player.craftIndex ~= ship.index then return end
  7. There is no way to know if the chat is open. So for example I want to track when presses "T" key. And it will fire even when player types in the chat. I'm not saying it shouldn't fire, just add the way to know when player types in the chat and when they just press a key during the game.
  8. A long time ago you introduced "namespaces" - system that allows to have semi-isolated scripts in one Lua VM to reduce memory consumption and increase script to script communication. But you didn't use this mechanics for system upgrades. And I'm sure they eat a lot of memory, because ship/station can have up to 15 of them. I want to help, so I changed "basesystem.lua" and all vanilla upgrades to utilize system that you used in your "shop.lua". I'm talking about this: ScriptNamespace = ShopAPI.CreateNamespace() Plus I made some changes to make transition more smooth. Which upgrades benefit from this the most: Unique systems such as Xsotan upgrades. Upgrades that don't stack: Wormhole Power Diverter, Minig System, Shield Impenetrator, Smuggler Blocker, Trading Overview, Valuables Detector, Velocity Bypass. Other upgrades will require less memory too for the first one installed. Example (arbitrarytcs.lua): package.path = package.path .. ";data/scripts/systems/?.lua" package.path = package.path .. ";data/scripts/lib/?.lua" local BaseSystem = require ("basesystem") require ("utility") -- Don't remove or alter the following comment, it tells the game the namespace this script lives in. If you remove it, the script will break. -- namespace ArbitraryTcs ArbitraryTcs = {} ArbitraryTcs = BaseSystem.CreateNamespace() -- optimization so that energy requirement doesn't have to be read every frame ArbitraryTcs.FixedEnergyRequirement = true function ArbitraryTcs.getNumBonusTurrets(seed, rarity, permanent) if permanent then return math.max(1, math.floor(rarity.value / 2)) end return 0 end function ArbitraryTcs.getNumTurrets(seed, rarity, permanent) return math.max(1, rarity.value) + ArbitraryTcs.getNumBonusTurrets(seed, rarity, permanent) end function ArbitraryTcs.onInstalled(seed, rarity, permanent) ArbitraryTcs.addMultiplyableBias(StatsBonuses.ArbitraryTurrets, ArbitraryTcs.getNumTurrets(seed, rarity, permanent)) end function ArbitraryTcs.onUninstalled(seed, rarity, permanent) end function ArbitraryTcs.getName(seed, rarity) return "Turret Control System A-TCS-${num}"%_t % {num = ArbitraryTcs.getNumTurrets(seed, rarity, permanent)} end function ArbitraryTcs.getIcon(seed, rarity) return "data/textures/icons/turret.png" end function ArbitraryTcs.getEnergy(seed, rarity, permanent) local num = ArbitraryTcs.getNumTurrets(seed, rarity, permanent) return num * 350 * 1000 * 1000 / (1.1 ^ rarity.value) end function ArbitraryTcs.getPrice(seed, rarity) local num = ArbitraryTcs.getNumTurrets(seed, rarity, permanent) local price = 7500 * num; return price * 2.5 ^ rarity.value end function ArbitraryTcs.getTooltipLines(seed, rarity, permanent) return { {ltext = "Armed or Unarmed Turret Slots"%_t, rtext = "+" .. ArbitraryTcs.getNumTurrets(seed, rarity, permanent), icon = "data/textures/icons/turret.png", boosted = permanent} }, { {ltext = "Armed or Unarmed Turret Slots"%_t, rtext = "+" .. ArbitraryTcs.getNumBonusTurrets(seed, rarity, true), icon = "data/textures/icons/turret.png"} } end function ArbitraryTcs.getDescriptionLines(seed, rarity, permanent) return { {ltext = "All-round Turret Control System"%_t, rtext = "", icon = ""}, {ltext = "Adds slots for armed and unarmed turrets"%_t, rtext = "", icon = ""} } end You can download the archive with all files in the attachments. It also includes fix for this bug. I hope that you'll find time to integrate it in the vanilla. new-systems-0.19.1.zip
  9. Is there any chance/plans on swithcing from Lua 5.2 to LuaJIT? It would make a huge performance difference for both mods and vanilla. People say that this helped Garry's Mod a lot with performance issues.
  10. If you have two identical turrets, you can mark them as trash and sell to the Equipment Dock via "Sell Trash" button. Then after you'll buy them back, there will be a turret with -1 amount and you will be able to buy it again and again.. This happens because we're using the same "SellableInventoryItem" table for all these items. So when player buys 1 back, we get amount = 0. And when player buys the second back, we get -1. How to Fix "data\scripts\lib\shop.lua" - function 'Shop:buyTrashFromPlayer()', line ~727. Replace this: local item = SellableInventoryItem(iitem, index, buyer) item.amount = 1 for i = 1, slotItem.amount do with this: local item for i = 1, slotItem.amount do item = SellableInventoryItem(iitem, index, buyer) item.amount = 1
  11. We're using your mod on Rusty's Galaxy servers and I updated it a bit, hope you don't mind. 1.1.0 Changed: Updated to 0.19.1 (including 'permanent install' bonuses) Changed: Now blocks only in PVP sectors Improved: Some performance optimizations Added: Now blocks only certain amount of ships Added: Localization support HyperBlocker-1.1.0-0.19.1.zip
  12. UPD: apparently I was wrong and op doesn't have any modpacks installed
  13. Because Rusty's Servers client modpack doesn't work well as serverside modpack. It doesn't have all files. You could ask Devious.
  14. Hi. It's from Rusty's Server modpack. Apparently you installed it incorrectly.
  15. I noticed that after 35 minutes have passed WormHole deletes and reappears immediately. And it will not have a timer. I guess, you just implement some failsafe in case something will be corrupted so the game will restore the wormholes. But it shouldn't restore this one. I even tried to delete it manually using following command in chat. It reappears. /run Sector():deleteEntity(Sector():getEntitiesByComponent(ComponentType.WormHole))
  16. Version: 0.19.1 There are few places that either weren't localized or have errors that lead to non-working localiztion. 1. "data\scripts\entity\story\adventurer1.lua" - Line 110 - "Greet" is not localized. ScriptUI():registerInteraction("Greet", "onGreet") Fix: ScriptUI():registerInteraction("Greetings. "%_t, "onGreet") 2. "data\scripts\entity\story\the4.lua" - Line 20 - "Hello." is not localized. ScriptUI():registerInteraction("Hello.", "onInteract") Fix: ScriptUI():registerInteraction("Hello"%_t, "onInteract") 2. "data\scripts\lib\story\the4.lua" - Lines 317-327 and 376 - Mission description localization doesn't work: local description = [[ Fellow Galaxy Dweller, In times like these, where the Xsotan threat is looming at all times, we are trying to protect you. Dangerous artifacts of the Xsotan have been found all over the galaxy, causing great harm to everyone near them. Should you find any of those artifacts, you must bring them to us. We will take care of them and destroy them, to eradicate the Xsotan threat and to make the galaxy a better place. Even if your life may be at risk, what is your life compared to the safety of trillions? You can find one of our outposts at (${x}, ${y}). We will pay a reward of 100.000.000 credits for each delivered artifact. - The Brotherhood ]]%_t Replace with: local description = [[Fellow Galaxy Dweller, In times like these, where the Xsotan threat is looming at all times, we are trying to protect you. Dangerous artifacts of the Xsotan have been found all over the galaxy, causing great harm to everyone near them. Should you find any of those artifacts, you must bring them to us. We will take care of them and destroy them, to eradicate the Xsotan threat and to make the galaxy a better place. Even if your life may be at risk, what is your life compared to the safety of trillions? You can find one of our outposts at (${x}, ${y}). We will pay a reward of 100.000.000 credits for each delivered artifact. - The Brotherhood ]]%_t and local bulletin = { brief = "Looking for Xsotan Artifacts"%_t, description = description % location, Replace with: local bulletin = { brief = "Looking for Xsotan Artifacts"%_t, description = description,
  17. Update: 0.23.3 - Bug is still there Version: 0.19.1 - 0.23.3 It's possible to get resources from mining/salvaging invincible stations. How to reproduce: Find any station Make it invincible Destroy it's shields Mine/Salvage it
  18. My mod unfortunately can't do anything with turrets in Auto/Defend mode. Devs should do something with them, so they will take ShipAI settings in the account as usual turrets.
  19. 0.19.1 I don't know what could cause it. I just tried to register a callback in the sector-attached script. It worked fine on a new galaxy. Unfortunately it's hard to reproduce. -- namespace ServerGuard ServerGuard = {} function ServerGuard.initialize() local sector = Sector() if not sector:getValue("serverguard_generated") then sector:registerCallback("onPlayerEntered", "peformLateInit") end end Here is the stacktrace of two crashes: 2018-10-17 17-09-43| === STACKTRACE ===================================== 2018-10-17 17-09-43| #1: operator new(unsigned long) [0xaf67c9] 2018-10-17 17-09-43| #2: [ext] std::string::_Rep::_S_create(unsigned long, unsigned long, std::allocator<char> const&) [0x7f4be8662e39] 2018-10-17 17-09-43| #3: [ext] std::string::_Rep::_M_clone(std::allocator<char> const&, unsigned long) [0x7f4be8663c6b] 2018-10-17 17-09-43| #4: [ext] std::basic_string<char, std::char_traits<char>, std::allocator<char> >::basic_string(std::string const&) [0x7f4be866436c] 2018-10-17 17-09-43| #5: Script::makeExecutionContext(std::string const&) [0x9f2909] 2018-10-17 17-09-43| #6: void GameCallbackSender::safeCallback<std::tuple<int>&>(std::string const&, std::tuple<int>&) [0x36ef33] 2018-10-17 17-09-43| #7: DelayedCallbackSender::sendDelayedCallbacks() [0x6d80f6] 2018-10-17 17-09-43| #8: ut::Worker<ut::queue<std::shared_ptr<ut::WorkPacket> > >::workSinglePacket() [0x3bcc3a] 2018-10-17 17-09-43| #9: std::thread::_Impl<std::_Bind_simple<ut::Worker<ut::queue<std::shared_ptr<ut::WorkPacket> > > ()> >::_M_run() [0x3bdcf0] 2018-10-17 17-09-43| #10: [ext] ?? [0x7f4be864cc80] 2018-10-17 17-09-43| #11: [ext] ?? [0x7f4be7e5f6ba] 2018-10-17 17-09-43| #12: [ext] ?? [0x7f4be7b9541d] 2018-10-17 17-39-04| bad_alloc thrown for a size of 140378898202592 2018-10-17 17-39-04| === STACKTRACE ===================================== 2018-10-17 17-39-04| #1: operator new(unsigned long) [0xaf67c9] 2018-10-17 17-39-04| #2: [ext] std::string::_Rep::_S_create(unsigned long, unsigned long, std::allocator<char> const&) [0x7fad01f71e39] 2018-10-17 17-39-04| #3: [ext] std::string::_Rep::_M_clone(std::allocator<char> const&, unsigned long) [0x7fad01f72c6b] 2018-10-17 17-39-04| #4: [ext] std::basic_string<char, std::char_traits<char>, std::allocator<char> >::basic_string(std::string const&) [0x7fad01f7336c] 2018-10-17 17-39-04| #5: Script::makeExecutionContext(std::string const&) [0x9f2909] 2018-10-17 17-39-04| #6: void GameCallbackSender::safeCallback<std::tuple<int>&>(std::string const&, std::tuple<int>&) [0x36ef33] 2018-10-17 17-39-04| #7: DelayedCallbackSender::sendDelayedCallbacks() [0x6d80f6] 2018-10-17 17-39-04| #8: ut::Worker<ut::queue<std::shared_ptr<ut::WorkPacket> > >::workSinglePacket() [0x3bcc3a] 2018-10-17 17-39-04| #9: std::thread::_Impl<std::_Bind_simple<ut::Worker<ut::queue<std::shared_ptr<ut::WorkPacket> > > ()> >::_M_run() [0x3bdcf0] 2018-10-17 17-39-04| #10: [ext] ?? [0x7fad01f5bc80] 2018-10-17 17-39-04| #11: [ext] ?? [0x7fad0176e6ba] 2018-10-17 17-39-04| #12: [ext] ?? [0x7fad014a441d] 2018-10-17 17-39-04| ===================================================Exception in Game WorkPool worker thread 0: std::bad_alloc
  20. (I also sent you a mail about it) There is an API-related problem that I is really confusing. I'm trying to register Server callback in the script that is attached to a Sector object: function ServerGuard.initialize() Server():registerCallback("onPlayerLogOff", "onPlayerLogOff") end But server instantly writes following message: ---- I tried to delay callback registration (so it would happen a bit later): local lateInit = false function ServerGuard.updateServer() if lateInit then return end lateInit = true Server():registerCallback("onPlayerLogOff", "onPlayerLogOff") end And half of the time this works. I'm confused, because I thought that all these functions should fire after the sector was generated. Is there any way to know when sector is ready? Unfortunately I can't spam with "registerCallback" function again and again, because I need to execute some other code, but only once. UPD: Contacted the devs, it's not a bug, it's an intended behaviour.
  21. It seems that the old "Gate is not ready but passable" bug is back. Basically gates show in tooltips that they're not ready, but they work just fine.
  22. And one more bug: https://www.avorion.net/forum/index.php?topic=5213 This one kinda breaks the balance.
  23. There is a chance that a low-rarity Hyperspace System Upgrade will have a price 0, because the one and only bonus it will have will by Hyperspace Cooldown. And since this bonus only works when upgrade is permanently installed and we have don't count "permanent" factor when we're calculating price: function getPrice(seed, rarity) local reach, cdfactor, efactor, radar = getBonuses(seed, rarity) local price = math.abs(cdfactor) * 100 * 350 + math.abs(efactor) * 100 * 250 + reach * 3000 + radar * 450 return price * 2.5 ^ rarity.value end We will get upgrades with price 0
  24. Thanks for the update :) However Shield Booster tooltip bug is not fixed: https://www.avorion.net/forum/index.php/topic,5206.0.html It's small but confusing.
  25. Then please find someone to be communiy manager, koonschi. So they could be a bridge between you and community when you don't have time yourself. And I still vote for a public issue/feature tracker. You're saying that you're doing a lot and you don't want to waste time writing changelogs. Then show us your issue tracker, you'll not need to write anything. You're saying that this will enrage people, but people are enraged already. Sometimes you (or Martin) respond to the community, implementing new API functions, discussing stuff. But you often leave it half-way. For example after I spent some time trying to contact you, you opened "Entity():setToFlyToLocation(vec3 location)" for modders. But it's either bugged or there is something else, because it just makes the ship to spin around like crazy. We talked about it and then you just stopped responding. I know that developing takes time and you had other things to do, but you never returned to that topic nor any other member of your team. I understand that you need to advertise the game, so you visit all these public events. But existing part of the community just leaves because game is still pretty unfinished. If Steam achievements work correctly, then something is definetely wrong, because less then 7% players got to Avorion and only half destroyed 5 pirate ships or equipped shields. Please focus on fixing current bugs, otherwise they will snowball and it will be harder and harder to fix them in the future. And hire new community managers apparently. And as a part of modding comminity I'm trying to help you in bugfixing. I write Bug reports and if bug is Lua-related I usually post ready-to-go solution, that you just need to check and integrate into the game. And other modders such as Hammelpilaw do the same. But you don't use our solutions. Did you know that Turret Factory doesn't properly check client data and you can build Legendary quality turrets or without using any ingredients, just credits?
×
×
  • Create New...