• 0

    posted a message on Guidebook that "unlocks" as player progresses through the mod?

    Hey all,


    The mod I'm working on is planned to eventually have a LOT of mobs in it. I want to create a sort of bestiary (almost like the pokedex from Pokemon) that stores info about the animals the player has encountered/fought/tamed. It would be a sort of book item, but I don't want the knowledge to be lose-able-- as in, if you lose your bestiary, you can make a new one and it will still contain the data you've uncovered. Or maybe it's not item-centric and could just be a GUI interface. I would like entries to unlock one at a time as applicable, and maybe have additional tiers of info per entry, like below:


    1. Basic info upon seeing the animal (where does it live, when does it sleep, what does it eat, is it naturally aggressive, etc.)

    2. Advanced info upon taming the animal (how you tamed it, more specific dietary needs, etc.)

    3. Genetic info upon breeding the animal (how do you breed it, can it be hybridized and if so with what?)


    What I'd need to do is have info saved per-player as to what they've unlocked. I know you can do this with capabilities, but I'm not sure if that's the most efficient method to do so or not for something like this (or if I should be concerned about overloading the player data somehow). The data would need to be accessed when a player completes an objective, views the bestiary, or encounters a circumstance that requires data to be updated (i.e. if the player dies the data needs to be restored to the new version of the player). It does need to be server compatible as well.


    I imagine the actual bestiary text wouldn't need to be stored in the variable itself. There's nothing about the text that would change per player-- it would just unlock at different rates. So I wouldn't need to be generating dynamic strings of info and storing them, or anything. It'd most likely just be a simple int for each entry that would tell you if it's unlocked or not and if so, how much is unlocked.


    Given these factors, are capabilities still the way to go? Or is there another system that I'd be better off using for a system that potentially could require a high number of variables? Are there any concerns I should keep in mind for the possible methods I could use?


    Thanks, and have a great day!

    Posted in: Modification Development
  • 0

    posted a message on [Capability sync issue] Custom block inventory broken on server

    Update:


    Still investigating the issue, and found a lot about capabilities not syncing from the server. This is likely the core of my problem. However, I'm unsure of how to properly set that up at this point (or even where I should do that). Ideally I'd like to set something up from a custom slot class or something-- that way I could just make sure to override the class I'm extending and it would auto-sync, no matter what inventory I'm using. I just really don't know how to do that.


    Does anyone have a good example of a sync system set up for syncing inventories from tileentities using IItemHandler? Most of the examples I've seen are for IInventory, which doesn't help me since it uses methods I can't access from IItemHandler (I don't want to switch over since I've seen a lot of people saying that IInventory is pretty dated), or any other recommendations on how I can efficiently deal with this problem? Should I consider investing my time into creating a base extension for the Container class itself, and how could I go about setting up a "universal sync" for my custom class?

    Posted in: Modification Development
  • 0

    posted a message on [Capability sync issue] Custom block inventory broken on server

    Hey, all!

    I ran into an extremely stubborn and strange glitch that I can't seem to find much info about. I have a block with a custom inventory that works fine in singleplayer, but completely spazzes out on servers, not saving, etc. Something is not getting translated between server and client, but I'm not sure what exactly is going wrong. No errors to be seen.


    This is the normal function in a singleplayer world:

    Normal, basic inventory stuff. Works absolutely fine. (also I'm aware that I haven't set up my lang file yet :P And the GUI is very placeholder-y)


    Whereas on a server...

    Clicking the item sends it immediately back into the slot. It just bounces. Can't be dragged at all. Shift clicking is possible, but effectively duplicates the item-- except the one that gets sent to the slot is some form of ghost item that disappears when clicked. Something is not right but I'm still fairly confounded by server coding so I'm hoping someone else here has an idea of what's going on...


    Code:


    Block

    TileEntity

    Container

    GUI

    GUIHandler


    Kind of a bizarre problem I know, but I'm hoping someone who has more experience with servers can help me out. I'm definitely at a loss. I'm thinking I may need to manually send a packet or something, but I have yet to find a good example of this sort of problem so I'm not sure.

    Thanks in advance!

    Posted in: Modification Development
  • 0

    posted a message on WildCraft: Detailed wildlife with advanced AI, genetics, and more! [WC1.1 NEWS!]

    @drmattcatt Holy wow I'm sorry for the late reply! I haven't been on the forums for a while, apparently 9.9 But thank you so much! I'm glad to hear your enjoying the mod :D


    And in other news...


    WildCraft is coming back!

    I know we've had radio silence for quite a while, and that's been primarily (as I've explained on our Patreon) because I had to totally re-code the mod from scratch. WildCraft has been a huge learning experience for me, but the result of my "learning on the fly" has been that a lot of my original code was super inefficient. Since I plan on expanding the mod so much, it's super important that my core code is as clean as possible-- and unfortunately, the best way to achieve that was to start recoding stuff from scratch. However, I now have most of the core code back in place and running smoothly, which means that I'll finally have visible results to share with you guys again! :D

    Now, there are a couple of things I know you guys are wondering. Firstly, the 1.1.0.0 release does not have a release date-- yet. I'm currently still in the pre-alpha stage, where I'm adding a lot of new features and re-adding older ones. However, I'm nearing the alpha testing stage, and that brings me to my next point--

    Alpha testing.

    In the past, I've done pretty much all my WildCraft testing on my own, which worked-- to a degree. I've been able to test most of the major mod features-- however, there has still been quite a bit that I've missed. I've begun to realize that I need some help with testing, and so I've decided to take on some testers to help with the alpha and beta stages of the mod. This means a couple of things. Firstly, the public releases will be significantly more polished and less buggy-- yay! Secondly, they will take a little longer to come out, since the testing phase will add some extra time to development. However, I'm confident that will be a beneficial sacrifice in the long run.

    So how do I become a tester? Well, I'm glad you asked.

    Right now, alpha and beta testing are part of my Patreon rewards. Normally, beta testing will be a part of the $5 tier, while alpha testing will be part of the $10 tier, HOWEVER I've also added a $1 testing tier to my rewards for a limited time. There are only 10 slots available, so if you'd like to get in on the testing without paying full price, now's your chance ;D You can find more info on my Patreon page, along with other cool rewards like weekly dev logs, sneak peeks, and more!

    I'll be posting more updates here on the forums, but if you'd like to follow the mod on other social media, you can join us on Twitter, Facebook, Tumblr, and YouTube. Facebook, Tumblr, and YouTube will be receiving major updates, while Twitter receives everything major as well as smaller, more random posts. We also have a Discord server for those who would like to come hang out!

    Lastly, I want to talk about the mod's future as Minecraft continues to update. WildCraft 1.1.0.0 will contain the full wolf update, and will be the last 1.11 release (except possible bugfixes). After that, the mod will officially move to 1.12, with a loosely supported 1.13 version. This is not an easy call to make, as I'm happy with my work in 1.11 and I'm not too sure what delays such an update may cause, but I would rather not fall too far behind in Minecraft updates, and I know many of you prefer the later versions anyway. With this in mind, however, I will likely not release a 1.12 version right away. I'm going to focus on completing the wolf update before I move to the 1.12 version, and trying to produce an in-progress version will just slow me down. So this 1.12 version will not be a simultaneous release. Again, not an easy call to make, but I hope you understand.

    I'm so happy to finally have more updates for you guys, and to be able to share my work on the mod again. I'll be revamping the first post soon, with more info about 1.1.0.0, but for now let me leave you with a little -ahem- food for thought ;)

    Food for thought :)
    Posted in: Minecraft Mods
  • 0

    posted a message on WildCraft: Detailed wildlife with advanced AI, genetics, and more! [WC1.1 NEWS!]
    Quote from WolfyDragon226»

    Looking forward to the next update :) Speaking of which, will you be adding an additional animal in the next one, or mostly working on the wolves?


    Next update will still be wolves, but probably the last wolf only update. After that we'll get some additional canine species drops in the meantime while I work on cats :)

    Posted in: Minecraft Mods
  • 0

    posted a message on WildCraft: Detailed wildlife with advanced AI, genetics, and more! [WC1.1 NEWS!]

    Hey all! I've got some exciting news!

    If you have a character you'd like to see in WildCraft, you can now request a custom skin! Skins cost $3 each, and you can get one by filling out the form here!

    Payment will be sent in the form of a PayPal invoice to the email provided through the form.

    As more animals are added, custom skins will become available for them as well!

    Posted in: Minecraft Mods
  • 0

    posted a message on WildCraft: Detailed wildlife with advanced AI, genetics, and more! [WC1.1 NEWS!]
    Quote from WolfyDragon226»

    Stupid question but, how can you tell which are male and which are female?


    Edit: Nevermind, I figured it out xD


    Ahhhh glad to hear you got it sorted XD

    For future reference to anyone else with the same question, as of 1.0.1.0 there's no way to tell a wolf's gender without taming it and opening its gui :P
    Posted in: Minecraft Mods
  • 0

    posted a message on Mod Server Compatibility
    Quote from Z_Doctor»

    Sorry, it's not in the log. Perhaps try searching through your source for any reference manually.


    Eek, that's gonna take a bit. Will do...
    Is it safe to use EntityPlayer, or do I have to refer explicitly to the multiplayer entity?
    Posted in: Modification Development
  • 0

    posted a message on Mod Server Compatibility
    Quote from Z_Doctor»

    SP is not server player, but SinglePlayer. This is a class a client-side only class; MP is MultiPlayer. To fix the issue, you need to remove the reference to that SP class or add some sort of check so that the server side of the mod doesn't try to reference it. That's about as much as I can gather. From just the log file.


    Right, I know that much-- but is there anything in that log file that points to where the SP reference is? I have a lot of classes and normally I rely quite heavily on the log telling me which class it came from to troubleshoot, but this isn't giving me any good indication as far as I see...
    Also, does EntityPlayer count as a singleplayer class? My understanding is that it's a common class, but I also have zero experience with servers so I could be wrong...
    Thanks
    Posted in: Modification Development
  • 0

    posted a message on Mod Server Compatibility

    Hello,

    I'm having some issues trying to make my mod server compatible. I got this error log from a mod user, but I'm not sure which class it's pointing back to. I'm guessing it's something with the Proxy, but I'm having trouble narrowing it down. Unfortunately, I have virtually no experience troubleshooting on a server.

    Can anyone give me a rough idea of what's causing that error/how to fix it? I know it's related to the player entity, but I'm not sure how to handle a server player... Ideally, I'd like to have one download that works on both SP and MP, but I understand if that's not possible. Is there a good guide to making mods server compatible?

    I can post code as needed, but there's a lot of it so I'd like to start where the error is originating...

    Thanks!

    Posted in: Modification Development
  • 0

    posted a message on PSA: Stop Mod Reposts!

    I only learned about this after making the video-- glad to know I'm not the only one concerned...
    Posted in: Mods Discussion
  • 0

    posted a message on PSA: Stop Mod Reposts!

    I'm sick and tired of all the mod reposting going on, especially since my own mod has now been reposted too. It's time we as creators and fans banded together to stop this! Mod redistribution takes away revenue from creators, and redistributed mods can even be repackaged with viruses!


    I've put up a video on this topic-- feel free to share it to help spread the word! The more people we can alert to what's going on, the more chance we can effectively combat this by raising awareness.


    Posted in: Mods Discussion
  • 0

    posted a message on Saving Persistent Data
    Quote from jabelar»

    I'm not aware of a limit. If you think about it a chunk has 65k blocks in it, so most worlds have to save millions of block informations, plus it already stores information on all the entities in the world, and so on.

    Note that while I don't think you need to worry too much about perf and memory, you should worry a bit. For example, you should reload and process the whole data every tick for example. And you should try to be somewhat compact in how you store stuff -- like UUID might be sufficient, but if you need to store additional info about the entity just do it in a compact way.

    Lastly, in all performance optimization it is best to start by simply coding the way you want it to work logically and then profile the execution to understand if/when there is actual performance issues. I see a lot of people work hard and introduce complex, bug-inducing schemes that are unnecessary -- only work on optimization when you see an actual perf problem.

    Alright, I'll keep that in mind. Hopefully the way I'm doing it will already be pretty streamlined, but I won't go out of my way to make it moreso unless it actually causes problems.
    Thanks for all your help!
    Posted in: Modification Development
  • 0

    posted a message on Saving Persistent Data

    Alright, thank you so much jabelar! Is there a limit to how much data can be stored in WorldSaveData, or is it a big enough limit to not warrant concern?

    Posted in: Modification Development
  • 0

    posted a message on Saving Persistent Data

    I haven't wanted to use a capability because I need to be able to save an absolutely massive amount of data that will only be accessed under certain circumstances. I'm literally trying to add a database of registered entities for every type of mob I add to the game-- which eventually will become an extensive list. Every registered entity needs to have a tag list filed under its UUID with several associated strings of data. That can add up very fast, and I just haven't seen anyone use a capability for storing so much data. Would there be any concerns with using a capability for that sort of thing?


    I'm mostly not sure of how much capabilities are kept actively loaded-- if the data is kept stored in active memory all the time, then that's going to be out of the question. That's why I was hoping to go with a world data approach-- Minecraft can store tremendous amounts of data in a world save, enough to encompass an entire map's worth, but most of it isn't kept actively loaded. But if capabilities aren't always kept actively loaded, it might be possible. I'm definitely concerned about trying to copy databases on player death, though, again given the potential for a huge amount of data being stored...


    The data I'm trying to save is as follows:


    Entity UUID- this will be used to "look up" the saved data and get the associated information.

    Entity's mother's UUID

    Entity's father's UUID

    Entity's generation- 0 = wild spawn/egg spawn, 1+ = bred

    Entity's genetics- The genetic code for a WCWolf entity is 24 characters long

    Entity's pedigree- The pedigree for a WCWolf entity will end up being about 7 characters long

    Depending on storage efficiency, POSSIBLY data about the entity's health/speed/damage


    We'd then be looking at saving dozens, potentially even hundreds of these entities (if you had a truly dedicated player maybe even thousands) into data, per player.


    I suppose the alternative to this could be to simply look up the entity's UUID and see if an entity by that UUID exists currently in the world-- but would that be limited by which entities are loaded/unloaded? If it isn't, I could potentially just save a list of UUIDs and then dynamically grab info straight off the entities associated with those UUIDs...

    Posted in: Modification Development
  • To post a comment, please .