Jump to content

Laserzwei

Members
  • Posts

    399
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by Laserzwei

  1. local minute = 0 local attackType = 1 function initialize(attackType_in) attackType = attackType_in or 1 deferredCallback(1.0, "update", 1.0) end This method defines the attacktype which will spawn. Especially "attackType_in" needs to be your type (4-6). It gets set in eventscheduler.lua on top. add some lines like these: That way you will get all your waves spawning. You might want to experiment with the random, minimum and to variables to get more desirable amounts in size/frequency of spawns. Edit: This will not work the way you think. The "a or b" operator in context of an assignment works the same as: if a ~= nil then return a else return b end It's pretty much syntactic sugar for nil-object-checks.
  2. Too bad: I recommend you to look into my mods for some examples :P Edit: For an example on how to use callbacks, I recommend looking at the server.lua and player/asteroidMover.lua in the moveAsteroids mod[mOS], since their code base is very small and might be providing what you need. but now for some real talk: You should only attach Callbacks to loaded objects. Of the 1,000,000 Sectors ingame only those where Players are in are loaded. Try using: "onSectorEntered"-Callback from player or Entities. I recommend using the player one. Because if you get an callback to an unloaded Entity the game freezes. Player(playerIndex):registerCallback("onSectorEntered", "methodnameWithoutBrackets") your receiver method gets 3 Parameters: methodnameWithoutBrackets(playerIndex, x, y) playerIndex: selfexplaining x: the x Coordinate of the sectory the Player(playerIndex) just entered y: the y Coordinate of the sectory the Player(playerIndex) just entered Don't forget to unregister your Hooks as soon as a Player logs off. Player(playerIndex):unregisterCallback("onSectorEntered", "methodnameWithoutBrackets") Using the Server():registerCallback("onPlayerLogOff", "onPlayerLogOffMethod") If you need to watch every Sector entered: You should add your script to the player in the "onPlayerLogIn"-Method in server.lua. Your file, since it runs on a player, should go into /scripts/player/. But that is not mandatory. If this all didn't help you much. I suggest you tell us about your So we can help you with your specific problems.
  3. That means it is installed corectly on the server. Does everyone get this message or only some? Are you using hamachi? This can only happen if 1) The message receiver has OOSP not installed 2) OOSP crashed on the client side 3) The server didn't get the answer from the client fast enough. If 2) is the case please send me the crashlog 3) can be resolved if you change derefferedTimeout = 10 in "oosproduction.lua" on the server to a higher value. Also don't worry about [0.9_6c] in the message. I forgot to rename it.
  4. I think you misunderstood the post. I was talking about getting to know the total Energy production/consumption of a ship/station. Not a single consumer. I added a picture for clarification
  5. Sadly the getEnergy() functions in the modules only tell the game how much Energy that one Module needs when installed. It doesn't tell anything about total Energy production/consumption of an Entity.
  6. The title says it. Has anyone been able to read: -the current energy Production -the current energy consumption -Energy consumption by components or change: -the current energy consumption -energy consumption by components of an Entity? I was able to change the current energy production via "addMultiplyableBias(int type, float value)". And most Entities seem to have a component called "EnergySystem". But that is the furthest I have come. I am talking about these Values:
  7. I'm glad I could help.
  8. I would love to see this little annoyance being removed ;)
  9. Als modder weiss ich, dass ein Callback auf ein nicht mehr verfügbares Object (z.b. weil der zugehörige Sektor nicht mehr geladen ist), genau zu diesem Bug führen kann. Wenn ihr könnt probiert mal den Bug ohne mods zu reproduzieren.
  10. all hail the float point precision: explanation
  11. Devious brought the idea/need up to me and now here it is :D Something similar to this mod has been added to the vanilla game. It's called "secure sectors". This is a small script that will protect playerowned Property when he logs off. It is limited to only those Entities(Stations, Asteroids, ships etc.) which are in the same Sector as the Player when he logs off. Therefore the Playership is always protected. Other Entities in different Sectors are not protected.(game limitation) Has a DANGERZONE-Value. Everything between the core and the DANGERZONE will not be secured. To make only the core a PvP zone use DANGERZONE = 147-150. Version 1.2 -Clients need this installed to work properly. They always had to. Added an Client Folder, for clients of an server only. 1.1 -added DANGERZONE value. default is 0 1.0 -release Filestructure [overrides] /data/server/server.lua (only 1 line added; simple to merge with other mods) [added] /data/player/pvpSecure.lua License Public Domain pvpSecure_1.2.zip
  12. I was looking through the avorion Documentation and saw that in "enum BlockType" all Blocktypes were shown except for "integrity Field generators". The Question is where or how do I find the Blocktype of "integrity Field generators"?
  13. Version 0.9_7 released. Splitted the mod into move Asteroids and its core component of updating out-of-sector-production If you upgrade: make sure you install "move Asteroids" as well or you might loos your claimed asteroids. If you really don't like the move Asteroid aspect http://www.avorion.net/forum/index.php/topic,2685.0.html
  14. I don't read posts here. look into my signature for ways to contact me
  15. This is the main overview of my mods. Have a look around. There is probably something useful for you :D Economic Mods move Asteroids [mOS] You found 3 claimable asteroids in a Sector that is within Pirate territory, but you need them to build Mines ontop? Here is the solution. [mOS] all Production Chains: Since the game lacked 3 Resources (Coal, Raw Oil, Diamonds) as player Buildable Factories, I saw myself in the need to supply them. all Production Chains Simple Asteroid Respawner: This mod modifies the vanilla asteroid respawn script, to also work in loaded sectors. Simple Asteroid Respawner CompleX3s [CPX3] Discontinued [CPX3] This mod allows you to combine multiple factories into a single Complex. Utility Mods Advanced Shipyard This mod allows shipyards to build your own or workshop designs. Advanced Shipyard Carrier Commander This mod allows you to efficiently order your fighters on your ships. Carrier Commander Sector Manager This mod allows you to select which sectors you want to keep loaded. Sector Manager Overpowered weaponry [OPW] Discontinued This mod adds commands to create overpowered weapons. [OPW] License QPL-1.0 DEPRECATED mods have been included into vanilla out-of-sector-production [OOSP] DEPRECATED [OOSP] A mod that emulates factories even when you are not in a sector! PvP Secure [PvPS] DEPRECATED This mod prevents playergrieving on logged off players [PvPS]
  16. The current game is missing 2 (supply-)factories that prevent you from building fully independent Productionchains: 1) Diamonds 2) Gems* This small addon adds A different way of getting Biogas: Bio Gas Fermenter 40xPlant -> 4xBio Gas + 10xWater + garbage: 1xToxic Waste Version M 1) Diamond Mine Version S 1)Diamond Factory 2xEnergy Cell + 2xCoal -> 2xDiamond *Gems are not provided. You can only install one Version at a time! From Avorion 0.23 on, this mod will be continued in the workshop S (https://steamcommunity.com/sharedfiles/filedetails/?id=1692693432) M (https://steamcommunity.com/sharedfiles/filedetails/?id=1692693709) Since 0.23+ became the main gameversion, there is no download here. Version History Installation: like any other mod drop the content of the zip file into your /Avorion/ installation folder. By default Version S is selected. To swtich to Version M you have to uncomment line 130 and comment line 131 out: if not pcall(require, "mods/extraminesM/scripts/lib/productionsindex") then print("Failed to load extraminesM") end --if not pcall(require, "mods/extraminesS/scripts/lib/productionsindex") then print("Failed to load extraminesS") end There should only be 2 if at the end of the file. Files /data/scripts/lib/productionsindex.lua Uninstall: just replace /data/scripts/lib/productionsindex.lua with the Vanilla one. Already build Player/NPC stations will KEEP the mod's Production. License Public Domain
  17. Version history -- 0.20.1 [2019-01-22] - Default max transfer range now 50 sectors - Now uses "onSelectMapCoordinates" event, instead of busy waiting - Now remembering your selected sector -- 0.19.0 [2018-11-08] - dropped complicated and dated way of deleting and recreating asteroids and the as tedious way of detecting sector changes. As a result the code is much smaller and uses less hooks (no modification of server.lua required anymore!) - Instead uses Galaxy():transferEntity(type 1) - The target sector can be individually selected and jumping out of a system does not inherently transfer asteroids with you. - This lifts the previously implied jump-range limit. To prevent unlimited transfer range there is now a config option (MAXTRANSFERRANGE) Filestructure
  18. This mod allows you to move asteroids between Sectors. 1) Be closer than 15km 2) Click the menu-option "move Asteroid" 3) Select your target sector 4) Pay the fee of 500.000Cr and watch it getting transferred Installation Copy the content of "mos_X.X.X.zip" into your Avorion's matching folders (you might need to create the mods folder). This mod has a Wiki. With more detailed install instructions and a How-To. Asteroids that were claimed before the mod got installed do not offer the "move asteroid" option and therefore can't be jumped. From Avorion 0.23 on, this mod will be continued in the workshop (https://steamcommunity.com/sharedfiles/filedetails/?id=1691539727) Since 0.23+ became the main gameversion, there is no download here. Licensed under: QPL-1.0
  19. Laserzwei

    [Mod] Cargo UI

    glad I could help
  20. your logfiles are usually located in %appdata%/roaming/Avorion/galaxies/<yourGalaxyName>/ they are named "serverlog" and ordered by date and time.
  21. Laserzwei

    [Mod] Cargo UI

    I'm using the beta branch .7633 You probably get a crash like this: Fri Mar 03 09:25:49 2017| Error: EXCEPTION_ACCESS_VIOLATION Fri Mar 03 09:25:49 2017| addr2line -i -e "E:\Program Files (x86)\Steam\steamapps\common\Avorion\bin\Avorion.exe" 000000000066cb93 2>&1 Fri Mar 03 09:25:49 2017| ScriptLine.cpp:? Fri Mar 03 09:25:49 2017| addr2line -i -e "E:\Program Files (x86)\Steam\steamapps\common\Avorion\bin\Avorion.exe" 000000000066eccb 2>&1 Fri Mar 03 09:25:49 2017| ScriptLine.cpp:? Fri Mar 03 09:25:49 2017| addr2line -i -e "E:\Program Files (x86)\Steam\steamapps\common\Avorion\bin\Avorion.exe" 0000000000afe54d 2>&1 Fri Mar 03 09:25:49 2017| ldo.c:? right? This happens when you call an invalid Entry count: invalidEntrycount = -1 myListBox:getEntry(invalidEntrycount) If you click in the Empty space below your List, myListBox.selected will return -1 and trigger the crash. I'm doing a wild guess and say you didn't sanitize such an input?
  22. The logical steps are initialization: -remember your created Label (myLabel) globally -remember the parental UIcontainer(window) globally when you update: -myLabel.visible = false -myLabel = nil -myLabel = window:createlabel(vec2(10, 10), "new Text", 20)
  23. how to activate the jump manually ? i lost two asteroid i didn't find it anywhere Did you try this: If you tried it and still have trouble locating your asteroids, please pm me and send me the logfile where you jumped.
  24. Laserzwei

    [Mod] Cargo UI

    Useful mod I don't have any problems with my Listbox:
  25. Content of the zips' Data folder. <installdir>\Avorion\data = <steaminstalldirectory>\SteamApps\common\Avorion\data
×
×
  • Create New...