Giter Site home page Giter Site logo

enginehub / worldedit Goto Github PK

View Code? Open in Web Editor NEW
3.0K 101.0 819.0 28.18 MB

πŸ—ΊοΈ Minecraft map editor and mod

Home Page: https://enginehub.org/worldedit/

License: Other

JavaScript 0.45% Java 98.60% Kotlin 0.84% ANTLR 0.10% Shell 0.02%
worldedit java minecraft forge bukkit sponge spigot gradle hacktoberfest

worldedit's Introduction

WorldEdit

A Minecraft Map Editor... that runs in-game!

  • With selections, schematics, copy and paste, brushes, and scripting!
  • Use it in creative, survival in single player or on your server.
  • Use it on your Minecraft server to fix griefing and mistakes.

Java Edition required. WorldEdit is compatible with Forge, Fabric, Bukkit, Spigot, Paper, and Sponge.

Download WorldEdit

This place contains the Java code for WorldEdit, but if you want to just use WorldEdit, get the mod or plugin from these pages:

Edit the Code

Want to add new features to WorldEdit or fix bugs yourself? You can get the game running, with WorldEdit, from the code here, without any additional outside steps, by doing the following four things:

  1. Download WorldEdit's source code and put it somewhere. We recommend you use something called Git if you already know how to use it, but you can also just download a .zip file. (If you plan on contributing the changes, you will need to figure out Git.)
  2. Install any version of Java greater than or equal to 16.
    • Note that if you do not install JDK 16 exactly, Gradle will download it for you on first run. However, it is still required to have some form of Java installed for Gradle to start at all.
  3. Open terminal / command prompt / bash and navigate to the directory where you put the source code.
  4. Run one of these following commands:
    • Mac OS X / Linux: ./gradlew :worldedit-fabric:runClient
    • Windows - Command Prompt: gradlew :worldedit-fabric:runClient
    • Windows - PowerShell: .\gradlew :worldedit-fabric:runClient

πŸŽ‰ That's it. πŸŽ‰ It takes a long time to actually transform WorldEdit into a mod. If it succeeds, the Minecraft game will open and you can create a single player world with WorldEdit.

When you make changes to the code, you have to restart the game by re-running the command for your changes to take effect. If there are errors in your Java syntax, the command will fail.

For additional information about compiling WorldEdit, see COMPILING.md.

Using a Java IDE

To edit WorldEdit in a Java IDE, follow these steps:

  1. Download and install IntelliJ IDEA Community Edition.
  2. In the IDE, open the folder that you saved WorldEdit's code in. This creates a new project in IDEA.

That's pretty much it.

If you want to be able to run the game also, follow these instructions:

  1. Go to Run -> Edit Configurations.
  2. Add a Gradle task:
    1. Choose worldedit-fabric for the project.
    2. For the tasks, type in runClient
  3. Click OK
  4. Under the Run menu again, go to "Debug [your new task]".

Speeding up the Edit-Test-Edit-Test Cycle

It's a little annoying have to restart the game to test your changes. The best way to reduce the time is to run the server instead (using runServer instead of runClient) and then reconnect to the server after restarting it.

Submitting Your Changes

WorldEdit is open source (specifically licensed under GPL v3), so note that your contributions will also be open source. The best way to submit a change is to create a fork on GitHub, put your changes there, and then create a "pull request" on our WorldEdit repository.

Please read CONTRIBUTING.md for important guidelines to follow.

Links

Supporters

YourKit Logo

YourKit supports open source projects with innovative and intelligent tools for monitoring and profiling Java and .NET applications. YourKit is the creator of YourKit Java Profiler, YourKit .NET Profiler, and YourKit YouMonitor.

worldedit's People

Contributors

ammaraskar avatar anon1efergwerfwer avatar aumgn avatar boy0001 avatar brokkonaut avatar darkarc avatar dordsor21 avatar dumbo52 avatar enveeed avatar gamerforea avatar hretsam avatar i509vcb avatar jjkoletar avatar joo200 avatar kashike avatar masteroftime avatar mattbdev avatar me4502 avatar meaglin avatar notmyfault avatar octylfractal avatar orthoplex64 avatar renezeidler avatar sk89q avatar stephan-gh avatar tomylobo avatar tonybruess avatar warpfork avatar wizjany avatar zml2008 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

worldedit's Issues

Most commands not working

Cant see console, using linux and running it without an attached console to anywhere. Keep getting this when trying to do a real command other than selecting the positions. In the time this has been broken, two huge forest fires i can extinguish, bedrock misplaces, cant take down towers, etc.

"Please report this error: [See Console]
java.lang.VerifyError: (class: ServerInterface, method: generateTree signature: (LEditSession;Lcom/sk89q/worldedit/Vector;)Z) Incompatible object argument for function call"

Snapshots: Support incremental backups

The //restore command is really powerful, but doesn't support backup schemes which include incremental backups.

For example, if you have a set of backups:
201101010000.zip 100mb (full backup)
201101010200.zip 1mb (incremental)
201101010400.zip 10mb (incremental)
201101010600.zip 2mb (incremental)

Then you can only really use 201101010000.zip as your restore source.

It would be great if the chunk wasn't found in the currently selected restore source, //restore would automatically look for the chunk in earlier .zip files.

We would probably want to have this feature turn off/on-able.

ForestGen not working

Hey there,

WorldEdit is awesome... except for the forest generator :(. I get the following error when trying to run it:

    java.lang.NoSuchMethodError: Server.setBlockData(IIII)Z
    at SMServerInterface.setBlockData(SMServerInterface.java:64)
    at EditSession.rawSetBlock(EditSession.java:119)
    at EditSession.smartSetBlock(EditSession.java:208)
    at EditSession.setBlock(EditSession.java:169)
    at EditSession.setBlockIfAir(EditSession.java:185)
    at EditSession.makePineTree(EditSession.java:1213)
    at EditSession.makePineTreeForest(EditSession.java:1282)
    at WorldEdit.performCommand(WorldEdit.java:778)
    at SMWorldEditListener.onCommand(SMWorldEditListener.java:156)
    at PluginLoader.callHook(PluginLoader.java:312)
    at id.d(id.java:374)
    at id.a(id.java:345)
    at ba.a(SourceFile:24)
    at bb.a(SourceFile:218)
    at id.a(id.java:53)
    at dc.a(SourceFile:85)
    at net.minecraft.server.MinecraftServer.h(SourceFile:264)
    at net.minecraft.server.MinecraftServer.run(SourceFile:205)
    at bm.run(SourceFile:480)

Snapshots: Make the commands consistant

Could we please group the snapshot commands together with a common prefix:

  • "//restore" -> "/ss restore"
  • "//use " -> "/ss use "
  • "//use latest" -> "/ss use latest"
  • "/listsnapshots [count]" -> "/ss list"

Issue with //chunk and //copy

//chunk followed by //copy breaks, we were moving servers and intended to generate a new world but keep the chunk that we had constructed in, i expected this to work but it doesn't

Schematic listing and storage

I would like to be able to type //listschematics to see all the stored schematics, also it would be nice if there were an option to default save schematics under a folder named the same as the user who created it eg:
'//save mything' would be stored in 'schematics/iccle/mything.schematic', and corrisponding '//load mything' would search first in my named folder, then in the main schematic folder (or make this configurable via options)

//replace NullPointerException

2011-01-05 22:10:23 [INFO] Command used by 4am //replace mossy 0
java.lang.NullPointerException
    at com.sk89q.worldedit.WorldEditController.getBlock(WorldEditController.java:254)
    at com.sk89q.worldedit.WorldEditController.getBlockIDs(WorldEditController.java:354)
    at com.sk89q.worldedit.WorldEditController.performCommand(WorldEditController.java:1066)
    at com.sk89q.worldedit.WorldEditController.handleCommand(WorldEditController.java:1952)
    at HMWorldEditListener.onCommand(HMWorldEditListener.java:121)
    at PluginLoader.callHook(PluginLoader.java:482)
    at Player.command(Player.java:136)
    at Player.chat(Player.java:108)
    at kk.a(kk.java:485)
    at br.a(SourceFile:24)
    at bs.a(SourceFile:232)
    at kk.a(kk.java:61)
    at eh.a(eh.java:71)
    at net.minecraft.server.MinecraftServer.h(SourceFile:275)
    at net.minecraft.server.MinecraftServer.run(SourceFile:216)
    at cj.run(SourceFile:490)

Selection of about 170 blocks; underwater object I didn't want to use //drain on so I filled it (by hand) with mossy and then tried to replace with air.

Compass right-click != /jumpto

The new PDF mentions that the compass is shortcut for /jumpto.
However, jumpto is much more powerful than the compass. The compass has a much lower range than jumpto. it would be great if the compass would let you jump the same distance as jumpto.

Config Schematic Folder

I would like the ability to change the folder where schematics are stored using a setting in the config file.

[INFO] WorldEdit WEVERSIONMACRO loaded.

Small issue but I get this in the log when loading - I take it that's supposed to show an actual version number :-).

Just downloaded WorldEdit 2.8 and I compiled craftbukkit from the repo about an hour ago, so I know I'm up to date this time ;-)

Cannot modify with mobspawners nearby (/replacenear, //sphere, etc)

When running a /replacenear, //sphere, or seemingly any other command that modifies the world, if a mobspawner is in the affected range WorldEdit fails to perform the operation.
Using latest WorldEdit / hMod

    2010-12-07 18:00:14 [INFO] WorldEdit: SonicXVe: /replacenear 10 stone air
    java.lang.NoSuchFieldError: e
            at ServerInterface.getMobSpawnerType(ServerInterface.java:236)
            at EditSession.rawGetBlock(EditSession.java:261)
            at EditSession.getBlock(EditSession.java:238)
            at EditSession.replaceBlocks(EditSession.java:794)
            at WorldEditListener.performCommand(WorldEditListener.java:1077)
            at WorldEditListener.onCommand(WorldEditListener.java:1988)
            at PluginLoader.callHook(PluginLoader.java:490)
            at Player.command(Player.java:126)
            at Player.chat(Player.java:98)
            at ji.a(ji.java:481)
            at bh.a(SourceFile:24)
            at bi.a(SourceFile:223)
            at ji.a(ji.java:45)
            at ds.a(ds.java:76)
            at net.minecraft.server.MinecraftServer.h(SourceFile:269)
            at net.minecraft.server.MinecraftServer.run(SourceFile:210)
            at bx.run(SourceFile:484)

NullPointerException on //undo of large operation

Hit the following error after changing a large area (a mountain) into glass with //replace glass, then attempting to //undo. Part of the mountain restored and the rest remains glass. (Unfortunately we're not yet running a backup system. Lesson learned)


java.lang.NullPointerException
        at EditSession.rawSetBlock(EditSession.java:135)
        at EditSession.flushQueue(EditSession.java:353)
        at EditSession.undo(EditSession.java:275)
        at WorldEditSession.undo(WorldEditSession.java:97)
        at WorldEditListener.performCommand(WorldEditListener.java:660)
        at WorldEditListener.onCommand(WorldEditListener.java:1988)
        at PluginLoader.callHook(PluginLoader.java:482)
        at Player.command(Player.java:136)
        at Player.chat(Player.java:108)
        at kk.a(kk.java:485)
        at br.a(SourceFile:24)
        at bs.a(SourceFile:232)
        at kk.a(kk.java:61)
        at eh.a(eh.java:71)
        at net.minecraft.server.MinecraftServer.h(SourceFile:275)
        at net.minecraft.server.MinecraftServer.run(SourceFile:216)
        at cj.run(SourceFile:490)

Note: This area crosses a chunk boundary, but the part of the selection which was restored was not aligned with the chunk boundary.

Edit 2: Another interesting note: In the section which was restored, none of the torches restored (they remained glass blocks), and judging by the way the glass and restored sections touch, it looks as though the routine crashed in the middle of restoring a double chest, with one-half of the chest restored and the other still glass, and the glass continuing to the south.

pyramids

cuboid had a way to make pyramids, any chance you could add that?

Feature-Request - wool color

  1. Item flag +1
    -- need an item, (maybe a mode for pickaxe) that adds 1 damane (or changes flag) of a block for changing wool colors
  2. area item flag
    -- need to be able to /setflag X on a selected area to change wool colors

Snapshots: Support easily moving to an earlier/later backup without typing in the full name

Usually, backup names are quite long as they will at least include the date.

It would be great if we could move backwards/forwards through the backup files by using commands such as:

  • "//use later", or "//ss later" - moves to the next later backup
  • "//use earlier", or "//ss earlier" - moves to the next earlier backup

Example:

  • 201101010000.zip
  • 201101020000.zip
  • 201101030000.zip
  • 201101040000.zip

"//use latest" - would select 201101040000.zip

"//use earlier" - would select 201101030000.zip

"//use later" - would select 201101040000.zip again

This would allow you to very easily select a backup, restore a region, if it's not right go to an earlier one, restore... keep going 'til you find the right one.

//replace with random blocks

The //set randomization function is amazing!

It'd be even more amazing if //replace, /replacenear, and a few others supported it. :)

Script Timeout Config Setting Doesn't Work

Or at least didn't seem to.
Edited config.yml/scripting/timeout to 0, it still timed out after 3000.
Changed it to 60000, still timed out after 3000.

Did a full server restart after changing the config file each time. I'm also sure that I did not alter spaces in any way. Using latest bukkit as of...some time today.

/thru command no longer working

Error report:

java.lang.VerifyError: (class: ServerInterface, method: generateTree signature: (LEditSession;Lcom/sk89q/worldedit/Vector;)Z) Incompatible object argument for function call

Using hey0 b129, with MCadmin, CuboidPlugin, and iConomy all active.

trouble with snapshots

I'm generating a snapshot file with 7zip -

7z a -tzip -xr!imgcache -xr!public_html/map -mx0 $backupdir/$filename . > /dev/null

and seeing the filename, subsequently, in-game with /listsnapshots,

but when I do //use latest, and //restore, I get

"Failed to load snapshot: invalid CEN header"

The zip file is valid (unzip can list the files and extract from it) as far as I can tell.

Maybe if I try a different compression level..

paste-function that ignores copied air

I would like to be able to copy let's say a checker-board pattern where the white fields are air and the black fields are obisidian and paste it into an area of stone. the fields that were air should remain stone and the wood should be pasted into the stone.

/fixwater

Add a command to fix and level water pools.

Not able to restore blocks from backups generated by BackupPlugin and BackupArea

I used to be able to restore backups created with BackupArea, and now it gives us an error : no chunks could be loaded (bad archive ?). The corresponding chunks are present in the zip file, as a render of the zip shows them.

It worked with SMWorldEdit (I don't know the version), but don't work with the latest version. The snapshot path is configured correctly, and we can set the backup with //use.

Here is a backup with only the spawn area made with BackupArea if you need it to test : http://dl.dropbox.com/u/4422249/2010-11-27-19-27.zip

Yogoda

Add a function to regenerate landscape

It would be great to have a function to regenerate landscape using the inbuilt generator. Manually deleting a chunk ingame would almost do the same thing though so I don't know.

/editcut

Add a cut function that replaces the area with air.

/butcher bug

java.lang.NullPointerException
at com.sk89q.worldedit.WorldEditController.performCommand(WorldEditController.java:1326)
at com.sk89q.worldedit.WorldEditController.handleCommand(WorldEditController.java:1952)
at HMWorldEditListener.onCommand(HMWorldEditListener.java:121)
at PluginLoader.callHook(PluginLoader.java:482)
at Player.command(Player.java:136)
at Player.chat(Player.java:108)
at kk.a(kk.java:485)
at br.a(SourceFile:24)
at bs.a(SourceFile:232)
at kk.a(kk.java:61)
at eh.a(eh.java:71)
at net.minecraft.server.MinecraftServer.h(SourceFile:275)
at net.minecraft.server.MinecraftServer.run(SourceFile:216)
at cj.run(SourceFile:490)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.