Giter Club home page Giter Club logo

backpack's Introduction

Backpack with camouflage pattern Backpack

Poggit-CI Get wearable backpacks for your PocketMine-MP server! Supports custom models and textures!

Features

  • ✅ Supports custom geometry and skin files, for example made in BlockBench
  • ⚔ Does not interfere with PvP and additionally stops the use of KillAura [¹]
  • 💻 Easily modifiable and configurable
  • ⚖ Permission sets for every available design
  • 💾 Minimal disk space usage due to savefiles in NBT format [²]
  • 📏 Automatically updates scale in relation to the player's scale. You have baby sized players on your server? No problem!
  • 👻 Hidden when the player is invisible or dead
  • 💎 27 extra slots to fill up with your precious goods
  • 👨🏻‍💻 Simple to use commands - /backpack Puts down the backpack to make it's contents accessible
  • 💼 Can be opened by hitting the backpack entity
  • 🔐 Only accessible by the owner of the backpack
  • 🦸‍♂️ Immune to any impacts, as fire, explosions and player damage
  • 👪 Easy way to add roleplaying and survival fun

Screenshots

Front screenshot Back screenshot Inventory screenshot

Commands

Command Description Permission
/backpack Toggle between wearing and accessing the backpack backpack.command
/backpack create [design] Creates a backpack for the sender backpack.command
/backpack design <design> Switches to another design backpack.command
/backpack get Gives an item that when dropped puts on the backpack backpack.command

Special permissions

By setting up permissions in the style of backpack.type.FILENAME you can make cool and exclusive designs available to specific users and groups.

Example for permissions:

  • For the file default.json the permission would result in backpack.type.default
  • By giving the backpack.type permission all designs will be accessible

Creating new models and textures

For creating the entities i suggest using BlockBench, a free modeling program for Minecraft with included painting tools. It can also be ran in the browser and is mobile/touch friendly.

Some things must be given attention to when creating those models:

  • I suggest importing a player model to have a visual preview of where you actually are putting the cubes at. You can toggle the visibility of the bones at any time, making it easy to tweak the positioning of cubes.
  • Only the body bone/group may be used, since it is able to automatically align the backpack correctly, even when sneaking, swimming or elytra-flying. Cubes put into the body group to archive the best results.
  • The pivot of the body bone/group must be at [0, 24, 0] to make sure the cubes align properly when sneaking
  • Textures must be 64 * 32, 64 * 64 or 128 * 128 size. Other sizes won't render properly. Those are supported dimensions of a player skin (as of October 2019)
  • BlockBench supports generating texture templates, which is a great time and headache savior, since it can also try to "compress" the texture file by putting smaller cube textures in the unused areas of bigger cubes.
  • The geometry name must be geometry.backpack.FILENAME. The geometry file must be named FILENAME.json. The PNG texture file must be named FILENAME.png.

Planned features

  • Database support for cross server backpack saving
  • Optional UI for choosing the design of the backpack (alongside the /backpack design command)
  • Translations
  • Restrictions for allowing the use only in a set of worlds
  • Colored messages

Notes

  • To be able to run this plugin the gd extension must be installed and enabled. See this link 🖥 or this link 🐧 for information on how to enable it.

  • This plugin utilizes the InvMenu virion, which must be installed alongside DEVirion when running from source

  • Feel free to modify the plugin and contribute to the development (as long as you give credit 😉)! Pull requests are most welcome ☺

  • [¹] Simple KillAura hacks can be disturbed by this plugin if poorly coded. The hack client will have a hard time figuring out if it is actually targeting a Player or a Human entity (which are used in this plugin), and probably will attack the backpacks instead 👍🏻

  • [²] You can edit the NBT files via NBTExplorer, UniversalMinecraftEditor or similar programs with ease

Credits

A plugin by XenialDan, 2019

Many thanks to @Muqsit for helping with the data saving and to @CortexPE for his amazing Commando virion

backpack's People

Contributors

inxomnyaa avatar muqsit avatar poggit-bot 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

Watchers

 avatar  avatar  avatar  avatar

backpack's Issues

Question

How can I get Item in particular in a particular slot??

ex : number 5 slot Item's CustomName in backpack

translate Chinese

Hmm, excuse me?
I want to share it on "www.mcbbs.net", would you allow me?

A couple issues with backpacks attaching to player.

Description

  1. The backpack doesn't seem to be wearable with the intended method of using commands. When a player initially spawns a backpack, the backpack can be seen in one location and is mostly immobile except that it sneaks whenever the backpack owner sneaks. When the player does /backpack, the backpack disappears and can't be found anywhere. When the player does it again, the backpack reappears on the floor.
    • My current workaround for this that I have discovered is that I can do /tp or use some other teleport command to teleport to any place in the world to wear the backpack.
  2. The backpack when it does actually attach lags behind the players movements. I'm not sure if this is intended but it's not very nice.
    • I have found that warping to a different world while having the backpack on the floor fixes this issue and makes the backpack follow the player seamlessly.

My current solutions are rather impractical and complicate the usage of the plugin for my users. I'm hoping that there could be a fix for this on your end. I'm not sure if this is a a compatibility issue with other plugins like MultiWorld (seeing that warping between worlds fixes the second issue) or if this issue is just because of the limitations of Minecraft Bedrock Edition or PocketMine. At the least, I would like some explanation for what the issue could be that causes these problems and hopefully that a fix would come in future updates.

Versions

PocketMine Version: PocketMine-MP v3.12.2
Backpack Version: v0.2.1
Minecraft Version: Bedrock Edition v1.14.60 (protocol version 390)

error Loader

[Server thread/CRITICAL]: Error: "Class 'xenialdan\Backpack\Commands' not found" (EXCEPTION) in "plugins/Backpack-patch-1/src/xenialdan/Backpack/Loader" at line 100

pls fix

Cant make backpack

im trying to use /backpack create I put default but invalid argument is what I get

Special permissions don't actually work.

Description

I tried to restrict using some backpack designs using the special permissions feature stated in the README. I've found that while the other permissions which allow users to spawn backpacks or create backpacks work properly, all users with access to /backpack design can use all the designs regardless of if they have the special permission or not.

Versions

PocketMine Version: PocketMine-MP v3.12.2
Backpack Version: v0.2.1
Minecraft Version: Bedrock Edition v1.14.60 (protocol version 390)

Plugin doesn't work - "GD library is not enabled"

Hi, I have tested your project in my server but it doesn't work. In the console of my server it's written :

"2019-10-23 [16:43:59] [Server thread/CRITICAL]: pocketmine\plugin\PluginException: "GD library is not enabled! Please uncomment gd2 in php.ini!" (EXCEPTION) in "plugins/Backpack_dev-1 (1).phar/src/xenialdan/Backpack/Loader" at line 71"
(I think it's the same problem as Benda in his MyEntities plugin)

I know that the plugin is new but I send you that if it can help you ^^

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.