Scabbard problems

Users who are viewing this thread

How do i remove it? I went ot the itm kinds and removed the scabbard mesh next to the sword but then the game would close beacause of an error in the loading screen
 
Swords are coded to have scabbards. Each scabbard has three frames to show swords sheathed and an empty scabbard when unsheathed. I’ve no idea how you’d remove a scabbard in a text edit - I’d have to use the module system to remove (“scabbard_name”, ixmesh_carry) from the sword in module_items.py.

If you chose to simply replace the scabbard mesh - it’s a vertex animation where each frame has to have exactly the same number of vertices etc. That means the unsheathed frame also has to include the sword even though it’s scaled down too small to be visible,
 
So  now i edited the scabbard mesh and the scabbard hilt mesh and replaced the brf files, but when i draw the sword out ingame, the scabbard still "contains" the sword, making it look like i didnt pull the sword out
 
As mentioned earlier, scabbards have to have three frames. Take a native scabbard in OpenBRF & separate all frames to see what is required. They can be recombined as a vertex animation in OpenBRF. Each frame must have the same number of vertices.


Frames must be combined in the correct order. Check the order of frames in a native scabbard & make sure yours matches it.
 
Frames as in animation frames, not faces/polys.

PydEo.jpg

Frames 0 & 1 are identical with zero timing showing a sheathed sword. Frame 2 shows an unsheathed/empty scabbard with a 10 second timing.

dNKEV.jpg

To separate frames, right click the scabbard in OpenBRF and select 'separate all frames'

EnHtE.jpg

To recombine frames ensure they are listed in the order frame 0, frame 1, frame 2 top to bottom - select all, right click in OpenBRF and select 'merge as frames in a Vertex ani'. Check frame timings.

PS OpenBRF opens vertex animations back to front, so you always have to reorder frames before recombining them.
 
Frames are just meshes, which have to have the same number of vertices. I told you how to combine frames at the bottom of reply 7.

You need a scabbard mesh with the sword hilt showing. Make a copy of it & that gives you frame 0 and frame 1. For frame 2, split it into its components, select all elements of the sword (not the scabbard), right click & select roto translate rescale. In the bottom section rescale to 0.01% to make the sword too small to see (it won’t look any different in OpenBRF until you see it relative to unscaled meshes). Then recombine all elements of the scaled down sword and scabbard. This recombined mesh, in the same position with the same number of vertices (sword looks invisible) is your frame 2.

Make sure they are in the order 0, 1, 2 from top to bottom. Highlight all the meshes, right click and select merge as frames of a vertex ani.

That gives you a three frame scabbard. To get the correct timings, copy a native scabbard and from the edit menu paste timings onto your scabbard.
 
I may be confused as to what you guys are referring to but, I'm assuming you just wanted to rid the sword's scabbard altogether on a particular item?  Wouldn't it just be as easy to do this?

Original line:
["arabian_sword_a",        "Sarranid Sword", [("arabian_sword_a",0)],("scab_arabian_sword_a", ixmesh_carry)], itp_type_one_handed_wpn|itp_merchandise|itp_primary, itc_longsword|itcf_carry_sword_left_hip|itcf_show_holster_when_drawn,
108 , weight(1.5)|difficulty(0)|spd_rtng(99) | weapon_length(97)|swing_damage(26 , cut) | thrust_damage(19 ,  pierce),imodbits_sword_high ],

Take out the Scabbard mesh & holster flag altogether in the item line:
Code:
[code]["arabian_sword_a",         "Sarranid Sword", [("arabian_sword_a",0)], itp_type_one_handed_wpn|itp_merchandise|itp_primary, itc_longsword|itcf_carry_sword_left_hip, 
108 , weight(1.5)|difficulty(0)|spd_rtng(99) | weapon_length(97)|swing_damage(26 , cut) | thrust_damage(19 ,  pierce),imodbits_sword_high ],

Been a bit since I have been modding but I thought that is what I used to do to get rid of a scabbard if I wanted to.
 
NPC99
Now that I tryed to make the frames, I imported the 2 meshes (scabbard+sword and scabbard+micro sword) in the brf file the mesh with the sword and scabbard was too big? so it had to split it in two meshes (sword and scabbard separate). second thing i realized was that the was no time to set in the frames.

The Real Slate
In which file can i find these codes?
 
NordBlade said:
NPC99
Now that I tryed to make the frames, I imported the 2 meshes (scabbard+sword and scabbard+micro sword) in the brf file the mesh with the sword and scabbard was too big? so it had to split it in two meshes (sword and scabbard separate). second thing i realized was that the was no time to set in the frames.

The Real Slate
In which file can i find these codes?

Those codes are in module_items.py in the module system for the sword, which the scabbard relates to (I referred to it in my first post). You’ll need the module system for which ever mod you’re modifying - not all of them are publicly availabe. As you were adding a sword without using the module system, I assumed you were adding it to one of the popular mods (whose source code tends to be private) for your own use. If you’re just adding it to native Warband, it’s module system can be downloaded from https://www.taleworlds.com/en/Games/Warband/Download

You need to refer to the documentation and guides here https://forums.taleworlds.com/index.php/board,171.0.html

Clearly, I failed to communicate to you how to make an appropriate scabbard to substitute for the one that is code-linked to the sword which you replaced.
 
Back
Top Bottom