Keystrokes mod 1.8.9 move keystroke3/31/2024 SERVER: (send to CLIENT) Open the custom crafting gui for SERVER: Pressing R means to open the custom crafting gui Then the server figures out what to do, then tells the client what to do? So I need the client to check for input, then tell the server that the Player X pressed this key. Okay thanks, I think I start to understand how it works, however, I am not sure how I am to use this in my code. Let me explain you server-client stuff a bit NEVER PROCESS INPUT INFORMATION ON CLIENT AND SEND WHAT TO DO TO SERVER!!! USE ANNOTATED FIELDS ONLY ON CONVINIENT SIDE (USING CLIENT FIELDS WILL CRASH SERVER) Then server processes packets information and decides what to do. Server neither have keyboard, mouse or other input devices, so clients needs to send packets to server, containing information about user input (ex: player X has pressed button 'G') Server does not have graphic classes, so using them on server will crash it. This can be represented like server hosted on your computer, where you play on your computer (where you play on same machine). It can be represented like private server hosted on your computer with only 1 player.ģ) Lan server: your computer "splits" into 2 "instances": server and client, where all players, including computer client "instance", are connected to server to yours computer server "instance". Let's split 3 minecraft game cases in to sides:ġ) Multiplayer: server machine is a server and all connected players are clientsĢ) Singleplayer: your computer is both of these: server one and client one. Client is a graphicall part of the game: rendering and input goes here. Server is a logical part of the game, all logic, calculation, processing must happen here.Īll logic must happen on server side, because if it would happen on client, it would open straight road for hackers & cheaters. Let me explain you server-client stuff a bit: So again, if you could point me in the right direction here, it'd be nice, also if you know any nice tutorials for beginners, that would help as well! Like I said, I'm currently in a learning phase, so the simpler, the better. I have managed to do this with just right click, but I want it now to do it when I press 'R', and that's where I'm having problems.Īlso all this client/server side stuff is just making me confused, I checked out Diesieben07's tutorial on packets but it just made me even more confused. What I now want, is that when you hold that item in hand, and press 'R', the NBTag stored on the item is cleared/removed. I want it so that when you have the teleport item in hand if you shift+right click a block, it gets the coordinates of that block and in which dimension you are, and stores it in the item <- I already have that. And right now I have problems with the key binding. I might not have been clear enough, but what I want is right now, is just figuring out how I will make my mod, and to do so, I'm working on this small grenade/teleport mod, just to figure out how things work. So if you could point me in the right direction here, I'd be grateful! I have to say, it was easier to mod minecraft 1.3.1, but I guess you have more freedom now than back then. However, I'm not too good with modding or coding, so honestly, I'm a bit lost here with all the client/server side stuff going on. What I want is to make a mod, a mod I've been waiting for a long time but that has never been made, so I'm taking matters into my own hands. WARNINGĭue to multiple Quilt specific crashes and one item duplication Quilt support is now defined as fallows: This mod will work on Quilt using the offered Fabric compatibility.Īny problems that are not reproducible on Fabric will be addressed with very low priority.Current as in the player's currently held item? Since user input is Like the mod? Consider buying me a coffee.
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |