Topic category: Plugins and third-party tools
Gun Maker Procedures Plugin (from 1.2.2 on-wards)
This plugin adds to MCreator a set of procedures dedicated to firearm creation and handling of entities capable of shooting like a player.
-Shoot projectile
“Shoot <Snowball> projectile-type from <entity> with speed <10> and set inaccuracy accumulation to <3> recoil to <5> recovery time (in ticks) to <20>”
The main shooting procedure.
- Spawns the projectile with speed, inaccuracy, recoil and recovery time.
- Includes internal cooldown logic.
- Inaccuracy accumulates each shoot.
Use only in tick-based events/procedures (like “On item in inventory tick”), not in one-shot events, otherwise cooldowns and recovery logic will not work correctly.
-Set invulnerable time
“Set <entity> invulnerable time to <0>”
Sets entity invulnerability in ticks (minimum damage interval). If you want the projectiles you fire to deal damage quickly, you will need to set it to 0.
-Get invulnerable time
“Get invulnerable time of <entity>”
Returns current invulnerability time.
-Set ammunition
“Set ammunition of <item> to <30>”
Sets the ammo count of a weapon.
-Get ammunition
“Get ammunition of <item>”
Returns the current ammo count.
-Set recovery time
“Set recovery time of <item> (in ticks) to <20>”
Sets weapon recovery time between shots.
-Get recovery time
“Get recovery time of <item>”
Returns current recovery time.
-Get inaccuracy accumulation
"Get inaccuracy accumulation of <item>"
Returns the weapon’s current inaccuracy accumulation.
-Is mouse key pressed
”Is mouse key <Right> pressed”
Returns true/false if left/right mouse button is pressed.
-Check for mouse key pressed (to shoot)
“Check for mouse key <Left> pressed for <entity> (to shoot)”
Ready-to-use block to bind mouse input to shooting.
-Can shoot
“Can <item> shoot”
Checks if weapon can currently fire.
-Is shooting
“Is <item> shooting”
True/false if weapon is currently firing.
-Is reloading
“Is <item> reloading”
True/false if weapon is reloading.
-Geckolib animation
“With geo-item <item> play animations shoot <shoot_animation> if <true> reload <reload_animation> if <true>”
Handles Geckolib shooting and reload animations. Requires Needy's Geckolib plugin.
“With geo-item <item> set query <string> to <int> for controller <controller>”
This procedure block allows you to set a variable to a value created in the geoItem animation (on BlockBench) and make dynamic animations.
-Allow item to shoot
“If <entity> allow <item> to shoot (for all entities)”
Enables or blocks an entity from using a weapon.
-Get projectile owner
“Get owner of <projectile>”
Returns who fired the projectile.
-AI attack tag
“Make <mob> attack entities tagged as <target_tag> with priority <1>”
Lets mobs attack with firearms, simulating player-like behavior.
-Is keyboard key pressed
“Is keyboard key <R> pressed”
True/false if chosen keyboard key (A–Z) is pressed. Perfect for reload, fire mode change, etc.
-Dynamic reload
"Reload <item> of <entity> that has <number> max-ammo with <magazine> and set recovery-time (in ticks) to <int> durability to <logic> and reload multiplier to <multiplier>"
It reloads an item accurately and damages the selected magazine. The multiplier multiplies the damage dealt to the magazine. If "durability" is set to true, when the procedure is called the durability of the magazine will be taken and added to that of the weapon. It is therefore necessary that the weapon has a durability greater than 1 than its maximum ammunition capacity, so that when it has 0 ammunition it is not destroyed.
-Good example of "Item In Inventory Tick" procedure
