Jump to content
  • Sky
  • Blueberry
  • Slate
  • Blackcurrant
  • Watermelon
  • Strawberry
  • Orange
  • Banana
  • Apple
  • Emerald
  • Chocolate
  • Charcoal
augustas656

New debug card functions for maximal adventure map making potential

Recommended Posts

The debug card already is much more efficient than some of the commands you can do and command blocks. However, if added a lot more functions and features to edit the world anyway you want, this mod's debug card would surpass the power of command blocks.

Features that would be amazing with debug:
 

  • getOnlinePlayers()
    This functions exists both in component.debug and world objects, if done in world objects will return a list of all the online players in the world, if done from debug will return all online players in all worlds.
  • getOfflinePlayers()
    This function exists both in component.debug and world objects, if done in world objects will return a list of all the offline players that logged out in the world, if done from debug will return all known offline players.
  • getPlayers()
    This function exists both in component.debug and world objects, if done in world objects will return a list of all known online or offline players that are or were last in the world, if done from debug will return all known players.
  • getComputerPosition()
    This function returns the co-ordinates of the position that the computer case is at in the world, this can be used to calculate the distance of player's co-ordinates from the computer's.
  • getOnlineStatus()
    This function exists in player objects, returns true or false based on wether the player is online or offline.
  • getEntities()
    This function exists both in component.debug and world objects, if done in world objects will return a list of all entities, as an entity objects table with a key string value of their ID, if done in debug will return all entities.
  • getEntity(id_string)
    This function exists in debug, if done in world objects will return an entity object (new feature) of the entity with the specified id.
  • getData(path)
    This function returns NBT data specified by the path of any player, world or entity object.
  • setData(path)
    This function sets NBT data specified by the path of any player, world or entity object. Returns true if successful
  • summonEntity(type, x, y, z, data)
    This function is used from world objects to summon an entity in the specified location of the specified type and data. This returns true if successful and ID of entity.
  • setParticle(type, x, y, z, data)
    This function is used to summon a particle in the specfied location of the specified type and data. This returns true if successful.
  • setSound(type, x, y, z, data)
    This function is used to play a sound in the specified location of the specified type and data. This returns true if successful
  • say(jsonMessageString, player)
    This function is used in debug to send a message to a player with all possible additions and other features.
  • setWeather(weather_name, duration)
    This function sets the weather in a world, and exists in the world object for the duration specified.
  • setTitle(jsonTitleString, player, duration)
    This function sets a large bold text title for players on the top centre of their screen like the 1.8 title command.
  • OTHER: Features to maximise the potential of getting and setting data in the world!

Regards
augustas656

Link to post
Share on other sites

getComputerPosition is already available via the debug component's getX/Y/Z methods.

setWeather I'm not sure if that's the same thing, but there is already is/setRaining and is/setThundering.

I've no issue with the other methods, but my focus will be on cleaning up stuff and work on OC1.4 in the next time, so if someone else could look into implementing these and contribute that, that'd be great. I've started on NBT editing, the most annoying part of that being the transition of NBT<->Lua, since userdata isn't really feasible due to cycles being an utter pain when persisting the userdata values. I'd be happy to share what I have so far, if anyone's interesting in picking this up, it's just too unfinished to push as-is.

Link to post
Share on other sites

With control over NBT data, read/write, it's already such a major step. This suggestion is like command blocks plus, because the commands in 1.8 and NBT data tags, command blocks and all those features are very useful for adventure map making and for me I find modding, plugin-making and adventure-map making equally fun. I'm relatively new to modding, and sometimes I get really annoyed because I can't find tutorials to what I'm looking for. If I knew how to make mod add-ons or atleast, if I understand correctly, even an easier way of modding that I can do to make addons for mods: OpenComputers, ComputerCraft then I would already have made this add-on with millions of more features. As I've said, I'm new to modding but, I might be wrong, but how do command blocks get NBT data, write to it and use it, in minecraft 1.8, that might be helpful for your work with getting data, but I don't really know, just an idea, a guess.

Regards
augustas656

Link to post
Share on other sites

cherbert, I believe you can create a function that does exactly what the /clone command does. I think it is very unlikely that it exists, but with the existing functions you can create a clone function. You can check for blocks in the area being cloned and the area where being cloned to, and set blocks, this is literally all you need to re-create /clone as a function. So if you wanted to literally clone an area and overwrite a different area with the clone you could loop through the x, y, z co-ordinates provided in the arguements and then get type of every block and store this block data in a table. Then you can loop through the secondary co-ordinates with ipairs by getting the index value and searching through the table using the index and so setting blocks and over-writing them. You can also do all the other arguements that exist in the 1.8 /clone command.

Regards
augustas656

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.