Difference between revisions of "Fishing Component"
DeamonHunter (Talk | contribs) (Initial commit.) |
(No difference)
|
Revision as of 20:57, 18 July 2017
Category:Component Modding are all optional properties that can be added to any file. Components are useful in extending the original files with even more information, such as the cost of the item or whether the block can be broken by a weapon.
On this page, we go over the Fishing component, signified by the following;
"fishing": { =Content= }
Fishing components are mostly used in conjunction with Fishing Rod Items. They are used to specify a number of customisable things about fishing, including models and effects.
Contents
When and How to use
Fishing components should be used whenever you want to make a Fishing Rod Items. This is it's only use, and all Fishing Rod Items are forced to include this component.
This component has no necessary parts so the following is completely valid;
"fishing": {},
This would leave all values at their default. You will still need this part, as it will not specify default values for this component.
To get actual use out of this component, you can use the following;
"fishing": { "castEffect": "staxel.particle.fishing.RodPull", "castSoundGroup": "staxel.sounds.place.Water", "reelEffect": "staxel.particle.fishing.RodCatching", "reelSoundGroup": "staxel.sounds.place.Water", "catchEffect": "staxel.particle.fishing.RodPull", "catchSoundGroup": "staxel.sounds.place.Water", "indicator": "staxel/item/gatherables/RodBobber.qb", "castDistance": 10.0, "minWaitSeconds": 1, "maxWaitSeconds": 10, "successTranslations": [ "fishing.success1", "fishing.success2", "fishing.success3" ] },
This specifies a lot more options than the original property. First of all "castEffect", "reelEffect" and "catchEffect" all point Particle codes which will play the particle at a certain time (i.e. When casting the rod, Reeling the rod to catch fish and Catching fish respectively.). Secondly "castSoundGroup", "reelSoundGroup" and "catchSoundGroup" all point to Sound codes which play at the same time as the particles. The "indicator" property specifies what model the bobber will be. "castDistance" will specify how far you can aim into water. "minWaitSeconds" and "maxWaitSeconds" specify how much time can be spent waiting for a fish. And finally "successTranslations" is a list of Translation Codes which will be used to select the text for the notification.
With that, you have a fully customised fishing rod.
Config Options
All config options must be inside the body of;
"fishing": { =Config Here= }
"castDistance"
Valid options (Double): A positive decimal value.
Default Value: 7.0 tiles.
This is the distance at which you can use the fishing rod.
"castEffect"
Valid options (String): A string that points to the code of a Particle
Default Value: "". No cast effect if not specified.
This is the particles it will play while casting the rod.
"castSoundGroup"
Valid options (String): A string that points to the code of a Sound
Default Value: "". No cast sound if not specified.
This is the sound it will play while casting the rod.
"catchEffect"
Valid options (String): A string that points to the code of a Particle
Default Value: "". No catch effect if not specified.
This is the particles it will play while catching a fish.
"catchSoundGroup"
Valid options (String): A string that points to the code of a Sound
Default Value: "". No catch sound if not specified.
This is the sound it will play while catching a fish.
"indicator"
Valid options (String): A string that contains the path to the indicator.
Default Value: "". No model for the bobber, if not specified.
This is the model it will use to float in the water (i.e. The bobber).
"minWaitSeconds"
Valid options (Int): A positive integer number.
Default Value: 1 second.
This is the minimum amount of time, in seconds, that the player needs to get to be able to get a fish.
"maxWaitSeconds"
Valid options (Int): A positive integer number.
Default Value: 15 second.
This is the maximum amount of time, in seconds, that the player needs to get to be able to get a fish.
"reelEffect"
Valid options (String): A string that points to the code of a Particle
Default Value: "". No reel effect if not specified.
This is the particles it will play while reeling.
"reelSoundGroup"
Valid options (String): A string that points to the code of a Sound
Default Value: "". No reel sound if not specified.
This is the sound it will play while reeling.
"successTranslations"
Valid options (List of Strings): A list of strings to be used for Translations
Default Value: Can be omitted.
This is a list of strings that can be used to add text to the catch notification.