-
Notifications
You must be signed in to change notification settings - Fork 3
Customization
Go to the darksouls.toml file in the config folder of your minecraft instance. There you should find an auto-generated example entry of a weapon:
[weapon_config.entry_name]
registry_name = "modid:weapon_name"
#Allowed Values: S, A, B, C, D, E, NONE
faith_scaling = "NONE"
collider = "darksouls:shortsword"
#Allowed Values: S, A, B, C, D, E, NONE
strength_scaling = "NONE"
required_strength = 0
required_faith = 0
required_dexterity = 0
#Allowed Values: S, A, B, C, D, E, NONE
dexterity_scaling = "NONE"
moveset = "darksouls:straight_sword"
In order to make the mod recognize an item as a weapon you have to add another entry like the example directly under it and change the specific value to your liking. Just make sure that you declare the correct weapon name at the top: [weapon_config.modname:weapon_name]
For colliders you still have to use the presets which are:
darksouls:fist
darksouls:shortsword
darksouls:longsword
darksouls:broken_sword
darksouls:tool
darksouls:great_hammer
darksouls:dagger
darksouls:spear
darksouls:winged_spear
darksouls:ultra_greatsword
For movesets you can make your own in a datapack or use the presets which are:
darksouls:fist
darksouls:straight_sword
darksouls:axe
darksouls:ultra_greatsword
darksouls:shield
darksouls:spear
darksouls:hammer
darksouls:dagger
darksouls:great_hammer
When adding shields you have to copy the example shield entry and change the values:
[shield_config.sample_shield]
#Allowed Values: NONE, SMALL, NORMAL, GREAT, UNIQUE, CRACKED_ROUND_SHIELD, IRON_ROUND_SHIELD
shield_type = "NORMAL"
collider = "darksouls:fist"
#Allowed Values: S, A, B, C, D, E, NONE
strength_scaling = "NONE"
required_faith = 0
registry_name = "sample_shield"
moveset = "darksouls:shield"
#Allowed Values: S, A, B, C, D, E, NONE
faith_scaling = "NONE"
#Range: 0.0 ~ 1.0
physical_defense = 0.0
#Range: 0.0 ~ 1.0
lightning_defense = 0.0
required_strength = 0
#Range: 0.0 ~ 1.0
fire_defense = 0.0
required_dexterity = 0
#Allowed Values: S, A, B, C, D, E, NONE
dexterity_scaling = "NONE"
#Allowed Values: WOOD, METAL, GOLD
shield_material = "WOOD"
From update 0.4.2 on, MC:DarkSouls will begin to add more customization options with the help of datapacks.
Custom weapon movesets must be saved in your datapack folder under data/darksouls/weapon_movesets/moveset_name.json
Here is an example of a custom weapon moveset:
{
"moveset": {
"light": {
"repeating": true,
"animations": [
"darksouls:axe_light_attack_1",
"darksouls:axe_light_attack_2"
]
},
"backstab": {
"repeating": true,
"animations": [
"darksouls:backstab_strike_check"
]
},
"dash": {
"repeating": true,
"animations": [
"darksouls:axe_dash_attack"
]
},
"heavy": {
"repeating": true,
"animations": [
"darksouls:axe_heavy_attack"
]
}
}
}As you may see that entries light, heavy, dash etc. are the different attack types a player can do while having a weapon with the specific moveset equipped. "repeating" determines whether the last animation of the attack chain should repeat instead of starting a new attack cycle. And the "animations" value is simply an array of the attack animations that play when starting the specific attack. You can use the names of animations that already exist here or just make your own.
Save your additional animations in your datapack folder under data/darksouls/additional_animations/animation_name.json There you can initialize your animation like this:
{
"animation_type": "attack",
"location": "darksouls:axe_dash_attack2",
"convertTime": 0.2,
"isRepeat": false,
"model": "darksouls:biped",
"phases": [
{
"start": 0,
"pre_delay": 0.01,
"contact": 0.05,
"end": 2,
"weapon_bone_name": "Tool_R"
}
]
}The animation type can either be "static", "attack", or "critical". A static animation is simply an animation without any weapon collision checks If your animation is static you can also ignore the "phases"-entry because it is only needed for attack and critical. The attack animation is used for normal attacks and uses the phases array where "start" stands for the time of the start of the attack phase, "pre_delay" is the start of the weapon swing, "contact" the end of the swing and "end" the end of the phase. The "weapon_bone_name" refers to the name of the bone from the armature of the player. It specifies where to which bone to collider of the weapon should be applied. Because you can only attack with the weapon in your right hand you can leave it at "Tool_R" most of the time. The "location" is the path of the .dae file of your custom animation, which you sadly have to make yourself in a 3d programm using the .dae player model that can be found here in github repository of MC:DarkSouls. The location starts at data/darksouls/animations/. "convertTime" is the time it takes to transition from the last animation to this one. "isRepeat" tells the mod if the animation should repeat itself. "model" is the model plus its armature that will be used for this animation. You can leave it at "darksouls:biped" for now because you only need animations for weapon_movesets that change player animations and not for other mobs.