Posts by LordFoobar

A new update is now available, introducing fishing, climbing gear, clothes and more!
Latest hotfix: 0.8.5.3 (2025-05-09)

    Thanks!


    I also thought that the collision might occur right before the specific location (i.e. to place lights, etc.) so I tried changing the line 3 of the first source code provided like so


    Code
    local worldData = getWorldData(event.player:getPosition():add(event.player:getViewDirection():mult(raycastResult.distance + 0.2)));


    to make the actual hit test a little further, but no real change. I did get a correct result at a very specific location, but I'm not sure why. Since I need to restart the game every time I change a little thing, this debugging is too time consuming for me at the moment.


    Having a debugging console (writing commands into the Lua console) would be quite useful :)

    Playing around with the API, I have this bit of code :



    (Don't mind the commented lines.)


    And here is getWorldData



    (Again, don't mind other pieces of the code, suffices to say that getBlockTypeAndId returns the absolute block id into a type and texture id, etc.)


    However, I always get Terrain=0 and Block=block 0. So, is the hit position represented by raycastResult.collisionPoint a position before hitting something, or am I missing something? How do I get the block position where the collision occurs?

    You can't do key bindings at the moment.


    My guess is that this will get implemented when scripts will be able to register themselves to the game's configuration interfaces. Until then, this is just not really possible without creating a lot of issues. One of these issues would be keyboard layout; where a key does not appear physically at the same place on a keyboard depending on country and/or locale. Not every one have a US keyboard :) (mine is CA-fr)


    Well, yes, you are missing the dependencies. Read the installation steps again. Pay attention to the file tree structure further down. If you know Git, cloning is by far the easiest option. There will be easier ways to install scripts later.

    As a player you never know if you play on a server with a "good" server admin. But if they use this script you are able to save your work as a file. If then something happens you could maybe could upload your file on another server then asking a admin there to enable it and all is fine. If you think it into the future you could even say "Hey, this is my blueprint, place it here..." and then you can start gathering ressources and it will be build if you collected all stuff.


    All scripts are executed on the server, not the client. Which means that you even if you save your construction to file, that will will be on the remote server, and not on your computer. This also applies to "importing" some data; you cannot import data from your computer; imported data are loaded from the remote server's hard drive. Would it be any other way, this would be a terrible... terrible backdoor. The only option, as I said, is if serialized constructions are uploaded and saved on a central, public, repository. But, then again, I would strongly advise making this feature yet, as there are security concerns that needs to be addressed first. The golden rule is simple, never trust anything that you download from the Internet, unless you have reasonable reasons to believe it is safe; nothing is 100% safe. And this is no paranoia, this is by experience and by professional wisdom :)

    Good that others like the idea, another advantage would be that we could save building before a new update is released, so we may prevent losing our creations and share them with others. (Or Steamworkshop implementation?) I think i can remember Red already planned something like this blueprint thing but why not doing a basic functional implementation in this lua script.


    A good server admin does create backups before upgrading. A better server admin set up frequent backups, too. However, with the new HTTP method, I surely could see a central repository of serialized data... however such feature is really not ready to get implemented, yet.


    Edit: a crazy idea would be to add an undo feature...

    thx
    as a admin
    yes a script is a goo idea, but i don't know do that :(


    Bravo for the world edit script. it is very good. But, i should like place flowers in the world ... It's possible....
    cordialement



    Thanks!
    Placing objects might be in plans for later, sure, why not? Right now, I'm quite busy with other things, but will take a look at it later.


    Tu parles français??

    As a server admin or as a player?


    As a player, this is some information that you should not have access to, unless some script have you able to get a friend list or something... But if a player has never been on the server, you should not be able to know this. This is simple security information and a matter of privacy.


    As a server admin, go grab SQLite Browser and open your world's database file and do whatever you want with it (at your own risk).


    As to if anyone will make such script, it is surely possible to fetch all that information directly from Lua, but I'd advise against that unless under special circumstances. For example, we have been talking about synchronizing ban information across server, into a global ban system (that someone ought to implement at some point anyway), then the admins should know if a given player was banned, or ever banned, and if he/she has ever been on the server. In all other cases, this is player privacy.


    So, bottom line, there is a way to know, but nothing concrete at this point. Hope this helps.


    Cheers.

    I have another idea for an extension of the script maybe someone has the time to implement these:


    So you can take the marking event to get all blocks of an area, maybe you can take the data and in addition to copy the blocks ingame, you can create s called "Blueprint"/"Schematic" for the selection and save it as file. So you can give it a name and load it into another world and place it. This would be awesome! At multiplayer worlds this has to be limited to area size and count of blueprints a player is allowed to upload.


    I think that would be a great addition.


    This is a great idea! The Lua API already has methods to serialize data to file. I've never played with it, but this is surely something to investigate! And, actually, would be a useful way to implement copy/paste as well :) For example, Bob select an area, copy it given a name (data saved to file given the name); Jack select an area, then paste the copied data given a name (the file is read, then written at the selected location).


    Thanks for the idea!

    This would create exceptions in the game rules. If you want to lay roads, you lay blocks or you use the proper terrain type.


    At the moment, if you want to lay stone roads, just mine stone and lay it down on the ground.... Then, it's only a matter of finding gravel or other raw material. But having a tool for that... I think is too specific for a particular need, that can be done already with the existing methods anyway. My opinion.

    Yes, there's already a place in hell for that :P the landscape is a just a little too random at the moment, but this could be interesting. (Kind of like Diablo.) And players would require a pretty darn strong armure just to walk down there (because of the heat).


    With flying dragons or other creatures, lava/steam geysers that could instantly kill you regardless of the armor. And diamonds should only be extracted from hell stones. That plus other materials and loot obtained from slayed creatures, hell could truly be the ultimate place to venture in Rising World. There should also be formidable random encounters just above hell, wherever hell stone can be found (il.e. fire/stone golems, etc.)


    These hell creatures should only go after players found down there and, if brought toward the surface, should crawl back in before reaching light of day, to prevent players from luring the creatures somewhere they can easily be killed, thus cheat the AI and gain valuable loot too easily.

    Good morning. When I try to clone world edit I get this:
    fatal: reference is not a tree: e86f2b2fbb4cf69f666e6670a0d2ea653bd3b480
    Unable to checkout 'e86f2b2fbb4cf69f666e6670a0d2ea653bd3b480' in submodule path 'table-ext'


    and the server fails to start. Did I miss something?


    Well.. no, you did not. And you are correct; I too get this error when cloning from a clean path. I'll investigate. Meanwhile, you can manually extract table-ext (there's really only one file...) inside the folder and you'll be good to go. I'll create the issue on github. Thanks for reporting this.



    **UPDATE**


    All is good, I just updated the submodule reference and it all checks out fine now. Sorry for that!


    That happens when something is built directly below the ground, so it's not related to this script ;) This can be disabled in the settings when your turn "Grass Masking" off (but then grass is also visible through objects etc, so that's not really a solution). We will fix this issue in the next time^^


    Yes, exactly. You can fix this by selecting the area where you have blocks underground (your selection should be 3 blocks high--on the y axis--minimum), then perform /we fill dirt (or stone, etc. You should apply any other terrain id than grass. I usually prepare the terrain with dirt, or stone, then place blocks, and I never have this problem.

    New update on World Edit!! For the geeks, you may peek into the changes here.


    The most notable changes for version 0.5.71 are :

    • It is now possible to use /we fill with all ores... and grass. "What, grass? But we already can do /we fill grass, right?", you might say. Indeed. But you can now put "real" grass now, at the length you want, too! All names are listed with /we help fill

      • New ores : iron, copper, aluminium, silver, gold, tungsten, cobalt, mithril
      • New grass : grass1, grass2, grass3, grass4, grass5, grass6, grass7, grass8, grass9, grass10 (i.e. 1 to 10, the higher, the higher the grass)
    • New /we about so you know what version of World-Edit is installed.

    Some minor refactor have been made internally, but nothing noticeable, if not perhaps some milliseconds speed improvement globally when executing commands.


    You may use the forum, or Github directly for issues, and suggestions. Please, use the forums for general comments and questions.


    Cheers!


    NOTE: some might have expected copy/paste already, but there are some issues that need to be addressed, first. Know that the feature is being worked on and will be released as soon as it is deemed stable enough.