-
Posts
1283 -
Joined
-
Last visited
-
Days Won
2
Everything posted by jeffryfisher
-
Returns? That could lead to the same sort of reference to a missing class. I recommend a proxy method that uses the Minecraft class to do what needs doing client-side (if indeed that's even the best way to design this mod). Looking at that design, it doesn't fit with "proper" client-server purposes. The server is the authority, and the client is the UI. Therefore, if the "stun" effect is to prevent player movement, it should do its work on the server (the authority). It should not hack the keys (or even trust a player to be limited by them). In theory, a devious player could have a second set of movement controls (e.g. a joystick mod) to continue moving, and your server-side would not be enforcing the stun. I hate to say it, but it looks like you should go back to the drawing board and find a hook server side to do what you want.
-
You said it yourself up above: You had both server and client running on the same machine, so the client was there to load the Minecraft class. As long as the class is loaded in the JVM, the server can load with a reference to a class that it would not load for itself (because class Minecraft is client side-only). It's probably the most common source of "My mod worked in Eclipse and SP but blew a gasket as soon as I tried it in true MP" threads that run like a rash throughout this help forum. I myself tripped over class Minecraft's client-only restriction in my first mod and found help in threads going back to 1.6.2 and earlier. Someday this forum will have a dynamic FAQ AI that detects that predictable error text in the crash report and sends a stock reply plus an admonition to Google the error message to see the thousands (ok, hundreds) of identical past threads. Until then, each newbie has the privilege of repeating the lore to the next who comes along -- so you're now the officer of the watch, please field the next instance (which will probably come within the next week or two).
-
Need help with increasing max stack size.
jeffryfisher replied to 1BowTiesAreCool1's topic in Modder Support
If that's the case, then even before trying a simple mod, you should sign up for a class that teaches any object-oriented language (e.g. C++, Java etc). You may find that even doing that may require a prerequisite of a simpler intro-to-programming class or simpler language. Either that, or completing the O-O programming aspects of the O-O language requires two terms. I say this because modding means working around some unusual constraints, and that means often doing or understanding some uncommon / advanced techniques (similar to hacking). This is not how you want to be introduced to programming. Not only is it akin to being thrown into the deep end of the pool, but it will teach you bad habits -- either because good practice would require a Mojang design change or because you'd be learning from a mixed bag that includes amateurs peddling wretched coding practices. So go to school and get some basic training supported by a professional teacher who can answer all your beginner questions. Come back here in about six months ready to add Forge and Minecraft knowledge on top of a solid programming foundation. -
"Debugger" depends on what IDE you're using. If Eclipse, then search the web for Eclipse tutorials. Teaching Eclipse (and Java and other tools) is outside the scope of this forum. Come back here when you've narrowed your problem to a specific question about Forge and its decompiled, deobfuscated Minecraft code.
-
[1.11.2] missing texture of a vanilla item.
jeffryfisher replied to salvestrom's topic in Modder Support
In that case, you'll need to set a breakpoint in the vanilla renderer and step through until you spot the interference. BTW, What does that even mean? You still haven't given us a pic, so we don't know what you are seeing. "Textureless" has no meaning. Are you seeing the purple and black checker pattern (the "missing" texture)? Or are you seeing something else (e.g. plain unwritten book, or untextured model polygons)? Get yourself into the debugger to find out what's happening. -
Is it private? Look for a getRegistry method.
-
Why are item textures not displaying?
jeffryfisher replied to an_awsome_person's topic in Modder Support
Scholarship and Research: Search for definitions of unknown words and phrases. Run experiments. Reverse-engineering and Debugging: Each means using your IDE to explore code, especially the vanilla code. Walking through idle code shows how it is connected, but even better is stepping through code as it runs so you can see data move through the system. Entering the debugger is like advancing from radio to color TV. Without the debugger, you are flying blind. -
Very New to mc modding, want to create a very basic mod.
jeffryfisher replied to Bluethefox's topic in Modder Support
Many modders here have posted pointers to mod source code at github. Google is your friend -- some simple searches (minecraft + forge + mod + github) should reveal many examples of mods. The Grey Ghost's Minecraft By Example might also be a good place to start. -
[1.11.2] missing texture of a vanilla item.
jeffryfisher replied to salvestrom's topic in Modder Support
If a texture is missing, then there should be a warning on load, but it may only show in the log file, not console output. Post the client log file (not console output) and JSON files. Also: Clearly describe what you expected to see and what you actually saw (a pic might be helpful). -
Why are item textures not displaying?
jeffryfisher replied to an_awsome_person's topic in Modder Support
Uh-oh, that's "lock my thread" bait. I'm surprised we're still talking here. Would-be modders are responsible for acquiring Java ability (and programming skill in general) on their own. Community members will volunteer Forge knowledge, but it's up to you to then research what all of the programming jargon means... ... Such as preinit. Start searching. To make better use of this forum, you need to raise your level of scholarship. -
Looks like your recipe is too big
-
[1.11.2] Update block when something changes on the server side?
jeffryfisher replied to Kander16's topic in Modder Support
After your TE updates the block state at pos on the server, doesn't the server communicate the new block state to the client automatically? As for the TE itself, I think you just need to mark it dirty. The server should then take care of it (presuming that your NBT write and read are coherent). At least my TE's all worked up to version 1.10.2 without need for manual packet sending. -
Safer method then world.getEntitiesWithinAABB?
jeffryfisher replied to Pingubro's topic in Modder Support
Set a breakpoint and step through your code in the debugger. Then you'll see what's happening (and probably why). -
Completely new to modding, but have an idea of what i want.
jeffryfisher replied to Bluethefox's topic in Modder Support
I probably should have added that you should develop your idea for this complex mod as a background task while doing a basic "beginner mod" to learn Forge first. Maybe create a new kind of block, successfully put a texture on it, and put its ItemBlock into the creative-mode menu. It could even become your seed block later. You just need to get a grip on the basics before adding complications. -
By this point, you should know how to interpret this error already. Add your missing file, rinse, repeat.
-
If the sound system hasn't changed too much, then I think that a moving sound remembers its entity and then ticks periodically to correct its position to wherever the entity has moved. I remember triggering a sound on the server (which handled the sending of packets to all players within earshot), but then my mod on the client-side needed to use a Forge event to replace the default sound renderer (also called a "sound", adding to the confusion) with my my own custom renderer because the server's packets could only spawn the default. One of the confusing things about sound (at least up to MC v 1,10.2) was the confusability between server-side and client-side processing (and multiple methods having the same name but subtly different purposes).
-
Completely new to modding, but have an idea of what i want.
jeffryfisher replied to Bluethefox's topic in Modder Support
I didn't understand this at first... You want the word "radius". Radios are wireless communication devices. Don't worry about matching the radius when setting it in the GUI. All you need is for the radius of a swap to be determined by the seed that was triggered (so if a matched pair of seeds have unequal radius settings, the radius in the triggered block is the radius used at both ends). In fact, you don't even need to set the radius in a GUI. If you want, you could just use the redstone signal strength that triggers the swap. Your tile entity is going to be tricky. If you choose an ID for a seed, then it must somehow detect whether there are already two seeds with that ID, even if they might be in chunks (and dimensions) that are not currently loaded. Therefore, you will probably need an obduction ID list in dimension or game level data. You need to decide whether to make the IDs unique to each game-world or only unique within each dimension. I recommend treating dimensions separately. When an ID search is complete, if exactly one seed is matched, then each seed's TE should store info (e.g. location) about the other so the search need not be repeated. Pointers can't be trusted because chunks might not remain loaded. Decide what to do if a piston tries to move a seed. Likewise breaking. Don't allow the swap to move/replace bedrock. There may be other perils, so you will probably want to loop all positions around your swapping seeds, testing the block at each end of each potential swap before swapping them. Ironically, you won't want or need to swap the seeds themselves (think about it). Write as much of this mod as you can using pseudo-code. Then replace as much pseudo-code with Java as you can do yourself. Then search for prior threads on each unknown Forge concept in turn, teaching yourself how to do new things. Also use the full power of your IDE. You should be able to teleport into vanilla classes to see what they require. You should also be able to hunt down vanilla examples of how to accomplish many of the actions you want to do. Finally, come back to this forum when you are stuck on all fronts (can't find a thread that has asked and answered your question before). Start a fresh thread for each Forge concept, and use an informative subject line (including MC version number) so future modders can find it when they have the same question. -
Blocks created by setBlockState not saved
jeffryfisher replied to HConfigs's topic in Modder Support
Actually, that chat message looks like a clever workaround. The server will decide whether the player has the power to use the command, so you don't need to reinvent that wheel. Between setblock and fill, you ought to be able to encode quite a bit of power into your keystroke(s). -
If you need help with a crash, find the log file (not console) and post it. If there's a client issue, post its log too. Since the debugger seems to be giving you difficulty, you may need to insert some statements to produce more informative text output.
-
You'll need to dive into the AI functions to see if any of them make assumptions that make them blind to non-vanilla classes. If you don't see anything obvious, then set breakpoints and step through your alpha spider's thinking in the debugger.
-
getEntitiesWithinAABBForEntity Does the error always have the same stack trace? If so, how big is the AABB that that is checked for bounding box collisions during the move? I agree that stepping through this process, even when not in error, could alert you to a potential pitfall. You might also try adding a temporary exception handler so you can break within it and poke at more variables surrounding the error.
-
My lang file assignments omit my mod name from the middle . Try deleting "modtest:" from your test case to see if it works. Example: tile.ruby_block.name=Block of Ruby Also, my last lang filename (for mc 1.10.2) capitalized the US (imitating vanilla). Is that changing in 1.11+? I suppose I'll find out in a hurry when I do my next upgrade cycle.
-
If you have a type mismatch, then it looks as if you have a Java problem. You must seek Java help elsewhere.