Spread
Spread lets you control the randomness in the direction after shooting. In general, you don't want bullets to fly perfectly straight, you want some random angle. Video Games all handle this differently, but in general, you should make your first shot fairly accurate, and increase spread over time.
Spread Accuracy. Spread is the opposite of accuracy. Lower spreads mean higher accuracy.
Spread_Image
Spread images are .png
files in the your server -> plugins -> WeaponMechanics -> spread_patterns folder. You can use this feature along with other spread features to accurately replicate spread from video games.
Name
The name of the image file (For example,
"circle.png"
).
Field_Of_View_Width
The "maximum angle" of the image.
If you set this to
45.0
, then the pixels on the edge of the image will be at a 45 degree angle.Defaults to
45.0
.
Field_Of_View_Height
Same as
Field_Of_View_Width
, but for the vertical angle instead.
If you create your image files, make sure to only use grayscale colors! It is recommended to keep image files smaller than 128x128, but there is no CPU impact on differently-sized images.
Base_Spread
The randomness applied to all shots. Applied both vertically, and horizontally.
Modify_Spread_When
Modifies the amount of spread based on what the player is doing. For example, when the player is scoping, you probably want to reduce spread.
Zooming
-> when scoping with the weaponSneaking
-> When the player is holding shiftStanding
-> When the shooter is not movingWalking
-> When the shooter is movingRiding
-> When the shooter is riding an entitySprinting
-> When the player is sprintingDual_Wielding
-> When the shooter has weapons in both handsSwimming
-> When the shooter is in waterIn_Midair
-> When the shooter is in the airGliding
-> When the shooter is gliding using an elytra
For example:
Changing_Spread
Changes the spread after every consecutive shot. This can be used to make guns inaccurate if you spam.
Starting_Amount
The base change amount.
If you want the first shot to be accurate, use
0
.
Reset_Time
The time, in ticks, it takes to reset spread back to
Starting_Amount
.The timer resets after every shot.
Increase_Change_When
This works just like Modify_Spread_When
Always
-> Every shot+ all options from Modify_Spread_When
Bounds
Defines the minimum and maximum spreads.
Reset_After_Reach_Bounds
Use
true
to reset back toStarting_Amount
Use
false
so the spread stays high for people spamming the gun.
Minimum
The lowest spread value allowed.
Maximum
The highest spread value allowed.
Last updated