Jump to content

Aki

Members
  • Posts

    166
  • Joined

  • Last visited

Everything posted by Aki

  1. Aki

    Lifter Dance

    I didn't find (yet?) any particular reason why this happens so posting here instead with bugtracker. Image describes the problem: For now it happens for every passing trader in that spot. Pretty sure it is just this spot, near this station, in this sector, in this galaxy, but still... It may happen somewhere else in the full game (if it wasn't repaired already in there).
  2. It's past. No purpose in thinking about that.
  3. For pirates just open data/scripts/startsector.lua find line Sector():addScript("data/scripts/sector/events.lua", "events/pirateattack.lua") change to Sector():addScript("data/scripts/sector/events.lua") And it should work. For ayy lmaos in data/scripts/player/attack.lua if Server().difficulty == Difficulty.Insane then updateSuperAction() else updateNormal() end change to if Server().difficulty == Difficulty.Insane then updateSuperAction() else local x,y = Sector():getCoordinates() if x ~= -139 or y ~= 427 then updateNormal() end end Note that you will need to change -139 and 427 to your home sector coordinates.
  4. Protip: Use lua. 8) But seriously, right now there isn't a lot to write about. What I am doing is simply reading and analysing what I see. Wait for the API documentation which will be hopefully released one day. I really don't see anything special I could share with you, but if you have some specific questions then just ask. Someone will answer them for sure.
  5. You can reroll system asteroid fields with some gymnastics (in the demo; it will be a lot easier in full game) in scripts. Also I believe that you are able to make selected asteroids turn into iron ones (changing their plans but again - gymnastics; for now, due to demo limitations).
  6. Aki

    Clean-up script

    ca. 1,200 asteroids in sector. I have just deleted over 4,000 wrecks from home sector 8). I wonder if I can do it more selective way, just to leave some newer wrecks in their place. Anyway, thanks again. (:
  7. Aki

    Clean-up script

    Actually I almost did it after writing this post using some really weird logic and ideas but it seems to work. Anyway, thanks a lot. Your suggestion will help it making cleaner (haha, got it? Cleaner code for clean-up script 8)) for sure!
  8. Aki

    Clean-up script

    I'm in need and I have ran out of ideas. Maybe someone in here has an idea or even completed script. I need to clean up wreckages in a sector. Can't call Sector() in command or even serverstartup.lua. Most of Galaxy() function names I have tried do no work too. I was thinking of attaching script to a ship but I would need to modify existing one (Station Founder maybe?). But the part of guessing name of getWreckages() (I would laugh if it is the one) function will still be a problem. Another thing will be trying to run proper loop if wreckages function does not return proper array. Any ideas?
  9. The more content will be available on the web and will be indexed by spiders the faster "Avorion" will be a solid result and search for e.g. Google. So let's just post, review and promote game with videos, stream etc. ;)
  10. RarityType is a hard-coded table; at least that's what lua says about its type. Rarity(n) function takes <-1; 5> as a parameter and returns selected RarityType value. n color .. RarityType key -1 Grey ... RarityType.Petty 0 White .. RarityType.Common 1 Green .. RarityType.Uncommon 2 Blue ... RarityType.Rare 3 Yellow . RarityType.Exceptional 4 Red .... RarityType.Exotic 5 Purple . RarityType.Legendary
  11. Aki

    Working Turret Merchant

    Any existing Turret Merchant will use it.
  12. After trying creating station with a custom scripts it throw an error that the custom script is illegal and cannot be used. Is there any work-a-round for that? Or is it hard-coded demo limitation? (same goes for system upgrades)
  13. Aki

    Server that runs.

    I have moved daily maintenance to 04:00 - 05:00 AM
  14. Working, simple turret merchant script. Just change your current turret merchant's source to this one. package.path = package.path .. ";data/scripts/lib/?.lua" require ("galaxy") require ("utility") require ("faction") require ("player") require ("randomext") total = 15 if onClient() == 1 then current = 1 end function interactionPossible(playerIndex) local relationLevel = Player():getRelations(getParentFaction().index) local station = getParentEntity() local dist = Player().craft:getNearestDistance(station) if dist > 500 then return 0, "You need to be at maximum of 5km from station." end local threshold = -5000 if relationLevel < threshold then return 0, "This faction doesn't like you enough." end return 1 end -- create all required UI elements for the client side function initUI() local res = getResolution(); local size = vec2(500, 300) local menu = Menu() window = menu:createWindow(Rect(res * 0.5 - size * 0.5, res * 0.5 + size * 0.5)); menu:registerWindow(window, "Buy Turrets"); window.caption = "Turret Merchant" window.showCloseButton = 1 window.moveable = 1 local fontSize = 14 window:createFrame(Rect(60, 10, 500-60, 300-10)); window:createButton(Rect(60+10, 300-10-10-50, 500-60-10, 300-10-10), "Buy", "onBuyTurretButtonPressed") window:createButton(Rect(10, 100, 50, 200), "<", "onPrevButtonPressed") window:createButton(Rect(500-50, 100, 500-10, 200), ">", "onNextButtonPressed") label_title = window:createLabel(vec2(70, 20), "", fontSize+6) label_damage = window:createLabel(vec2(70, 50), "", fontSize) label_rate = window:createLabel(vec2(70, 70), "", fontSize) label_range = window:createLabel(vec2(70, 90), "", fontSize) label_cost = window:createLabel(vec2(70, 110), "", fontSize) invokeServerFunction("getTurretInfo", Player().name, current) end function getTurretInfo(name, number) local turret = turrets[number] -- TITLE local title = turret.weaponPrefix .. " Turret"; -- add number predicate local prefix = ""; if turret.numVisibleWeapons == 1 then prefix = "" elseif turret.numVisibleWeapons == 2 then prefix = "Double " elseif turret.numVisibleWeapons == 3 then prefix = "Triple " elseif turret.numVisibleWeapons == 4 then prefix = "Quad " else prefix = "Multi " end if turret.weaponType == WeaponType.MiningLaser then prefix = prefix .. turret.material.name .. " " end if prefix ~= "" then title = prefix .. title; end -- RANGE local range = "Range: " .. round(turret.reach * 10 / 1000, 2) -- DAMAGE and RATE local damage local rate if turret.weaponType == WeaponType.Laser then damage = "Damage/s: " .. round(turret.dps, 1) rate = "" elseif turret.weaponType == WeaponType.MiningLaser then damage = "Damage/s: " .. round(turret.dps, 1) rate = "Efficiency: " .. round(turret.efficiency * 100) .. "%" elseif turret.weaponType == WeaponType.ChainGun then damage = "Damage: " .. round(turret.damage, 1) .. "x" .. turret.shotsPerFiring rate = "Fire rate: " .. round(turret.fireRate, 1) end -- COST local cost = "Cost: " .. getTurretCost(number) local requester = Player(Galaxy():findFaction(name).index) invokeClientFunction(requester, "setTurretInfo", title, damage, rate, range, cost) end function setTurretInfo(title, damage, rate, range, cost) label_title.caption = title label_damage.caption = damage label_rate.caption = rate label_range.caption = range label_cost.caption = cost end function getTurretCost(number) local cost = 100 local turret = turrets[number] if turret.weaponType == WeaponType.Laser then cost = cost * turret.dps * round(turret.reach * 10 / 1000, 2) * 1.5 elseif turret.weaponType == WeaponType.MiningLaser then cost = cost * turret.efficiency * 10 * turret.dps elseif turret.weaponType == WeaponType.ChainGun then cost = cost * turret.damage * turret.shotsPerFiring * turret.fireRate * 0.4 * round(turret.reach * 10 / 1000, 2) * 1.5 end return round(cost, 0) end -- this function gets called on creation of the entity the script is attached to, on client and server function initialize() local station = getParentEntity() local x, y = Sector():getCoordinates() local dps, tech = Balancing_GetSectorWeaponDPS(x, y) if onServer() == 1 then turrets = {} for i=0, 4 do table.insert(turrets, InventoryTurret(GenerateTurretTemplate(random():createSeed(), WeaponType.ChainGun, dps, tech, Rarity(0), Material(MaterialType.Iron)))) end for i=0, 4 do table.insert(turrets, InventoryTurret(GenerateTurretTemplate(random():createSeed(), WeaponType.Laser, dps, tech, Rarity(0), Material(MaterialType.Iron)))) end for i=0, 4 do table.insert(turrets, InventoryTurret(GenerateTurretTemplate(random():createSeed(), WeaponType.MiningLaser, dps, tech, Rarity(0), Material(MaterialType.Iron)))) end end if station.title == "" then station.title = "Turret Merchant" end end function onBuyTurretButtonPressed() invokeServerFunction("buyTurret", Player().name, current) end function onPrevButtonPressed() current = current - 1 if current < 1 then current = total end invokeServerFunction("getTurretInfo", Player().name, current) end function onNextButtonPressed() current = (current % total) + 1 invokeServerFunction("getTurretInfo", Player().name, current) end function buyTurret(name, number) local buyer = Player(Galaxy():findFaction(name).index) local station = getParentEntity() local requiredMoney = getTurretCost(number) local canPay, msg = buyer:canPay(requiredMoney) if canPay == 0 then Server():sendChatMessage(buyer, msg, station.title, 1); return end buyer:pay(requiredMoney) buyer:getInventory():add(turrets[number]) end
  15. Aki

    Server that runs.

    Stay with us, Storm, you can learn things here too! Anyway, I have got screenshot that is terribly wrong and only people who were on server can get what's wrong in it. Its title is "Hauling cargo to The Luseodcyebh Station"
  16. Sadly server configuration is in galaxy folder and is not global. Windows: %appdata%/AvorionDemo/galaxies Linux: ~/.avoriondemo/galaxies
  17. Aki

    Server that runs.

    Server cleaned up, with new seed and more bonus on start for players. We have now cool green home sector. 8) And we are friendly with Pirates faction, YARRR!
  18. In Keyboard Steering, unlike Mouse one, you can only roll ship. You can't move it up/down/left/right with thrusters. And it isn't even bindable in options when keyboard steering is enabled. Suggestion is to add it to the options to allow binding them somewhere. They don't need to be binded anywhere by default.
  19. One doesn't simply delete own thread. Moved to http://www.avorion.net/forum/index.php?topic=378.0
  20. If you don't mind I would strongly suggest to release dedicated server separately as a tool on Steam (a lot of games do that, actually). It will help server hosters in updating and managing Avorion servers (making it easier even for normal person) which may possibly result in bigger amount of servers leading to easier popularity gain.
  21. Yeah, that nightmare is result of persistently running server. 8) Like you said it would be good if there would be any AI that could clean up this mess but currently the only way is to wipe out whole galaxy. :(
  22. Aki

    Server that runs.

    I have couple of 32GB, i7-4790K running mostly on Ubuntu 14.04.4 LTS. If I find time then I could help a little bit, but, like I said, "if I find time"... I'm preparing guide on hosting Avorion servers on linux, but to be honest, I'm waiting for Steam version arrival to write it only once. ;) Anyyyyway. It took 14 day of pirates and alien attack to destroy repair dock in our home sector. Shall we do a reset?
  23. Ok, so you are going to be on Steam. And here goes the question. How will be server software provided? With the game after purchase or will it be available for any Steam user as a Tool for game? Or maybe it will be downloadable from the website. Or maybe it won't be available separately from the game? And I mean just the server files. Not game itself.
  24. Gratz, I hope you can make it in remaining days! I will do what I can.
  25. StarMade is a voxel-based 3D sandbox space shooter (copied from their site). From the Depths is about boats but it is also focused on combat. On the other hand Avorion is more into space-sim genre. At least I feel so. By space-sim I mean games like X, Elite, Freelancer, Pioneer, XFrontier, Evochron series (Starwraith games), Vendetta Online or even EVE Online. A game in which you can do anything you want and building your own ship is just an addition. I hope it will have much higher focus on economic, management or long-term combat aspects than just pure building. Avorion describes itself as procedurally generated sci-fi sandbox.
×
×
  • Create New...