[WB] Bows used with shields [Discussion]

Users who are viewing this thread

Nah, I don't think so. While it makes sense for the player to check it every second so (s)he doesn't exploit it (giving that it won't be a clickable option like Tocan suggested above but alas, many item variants), the NPCs are only switching between their weapons at specific occassions (like the range towards enemies). Having them for two seconds the big shield in the same hand as the bow wouldn't break the immersion a lot, given that you normally would also first pick the bow from your back before putting the shield there.
 
If you must, you can create a trigger that fires every second, every tenth of a second, or every frame, and run the agent loop 10m around the player position, that would make it lighter.

You can run the player only trigger at every frame, too, with little performance loss.

I highly doubt though NPCs unwielding their shields would be very noticeable.
 
Nice thread! I was to tired to think about check for shield size instead. That would cut the monster in the half...

Yeah, that'd require an identical entry for a bow with a two_handed flag. A bit pointless, really. Oof, that simple thing has more meat to it that I figured. I love it.
What do you think about a small penalty for using it with a shield?
 
What do you think about a small penalty for using it with a shield?
Which could bring up the potentail of getting a malus when shooting with shields since then the players would have to decide for either going with better shooting abilities or for more cover, so the idea here expands already :lol:
Would make sense for me. The penalty could also depend on the shield size, weight and/or the shield skill
 
Yes, a penalty is a pretty good idea. I haven't done anything to change item values directly before (not counting skill modifiers based on items, of course). Is there any script that changes that, apart from the modifier one? Something for, say accuracy or speed? From what I searched, I didn't find anything.

Also, and since that's a mostly theoretical thread, while I searched in the item operations, I found that: cur_item_set_material
It basically changes the material of item in question at will. And I know that the team of Deeds of Arms and Chivalry re-UVmapped their swords to use just UV map and re-textured it 2 times, one for 'common' items and one for 'noble' swords, more rich and trimmed and elaborate. But since they use basically the same UV map, you could flawlessly make the use either one of those two textures. Which opens tons of possibilities, to make a custom smith, who would make a 'noble' variant of your weapon and what not. Just a side thought.
 
For penalties, use agent_set_accuracy_modifier or agent_set_ranged_damage_modifier.

For a smithing or item upgrading system, use item modifiers. Much more convenient. I think VC has a system like this?
cur_item_set_material affects all instances of an item.
 
Yeah, I already have a smithing thing, mostly based on VC. Basically, it stores item modifier and if the player pays the smith, it upgrades the weapon or armor to the next modifier. Dialog based, using the weaponsmith and/or armorsmith dialoge, but it can be easily converted to a menu based thing, too. It would be cool to have a visual upgrade, as well, though. Still, that's a random thought on a lucky find, while browsing the operations file.
 
Erm, you can apply different meshes based on item modifiers :wink: IIRC, native does this, too.

Regarding bow+shield, I remembered that there's also a ti_on_item_wielded trigger. I've never seen it in action, but I guess it fires whenever an agent selects or switches a weapon. Might be lighter than performing an agent loop.
 
Erm, you can apply different meshes based on item modifiers :wink: IIRC, native does this, too.
:shock:
That's news to me. :facepalm:
Ah, yes, there's a trigger like that. I've used it for magic spells (well, basically, pseudo-magic, where a sword increases strength if wielded). Sounds a good idea to try.
 
Just to add some follow up note to the thread here for others who might be interested in the topic.

InVain has implemented bow & shield mechanic in TLD, you can find the commit with the respective code here:
https://github.com/tldmod/tldmod/commit/4d1412a8a2a0a431235fc27fe1ab0df7f49bc4c1

Antonis has created some variant for it:
Code:
common_onehanded_bows =(0.2, 0, 0, #
[

],
    [(try_for_agents, ":agent"),
      (agent_get_troop_id, ":troop", ":agent"),
      (troop_is_hero, ":troop"),
      (agent_get_wielded_item, ":weapon", ":agent", 0),
      (gt, ":weapon", 0),
      (item_get_type, ":type", ":weapon"),
      (eq, ":type", itp_type_bow),
      (is_between, ":weapon", light_bows_begin, light_bows_end),    
      (agent_get_wielded_item, ":shield", ":agent", 1),
      (gt, ":shield", 0),
      (item_get_weapon_length, ":size",":shield"),
      (gt, ":size", 40),
      #(is_between, ":shield", escudos_pesados_begin, escudos_pesados_end),
      (agent_set_wielded_item, ":agent", -1), #this will unequip all items
      (agent_set_wielded_item, ":agent", ":weapon"), #reequip bow
    (try_end),
])
Antonis: As you can seen, I have defined bows into a range. It un-equips the items and later re-equips the bow. The re-equipping part needs work, but it should serve as a working base. The trick is to define the items correctly. You want all one-handed bows one after the other, in a range. Also, it's better if you define all "big" shields in the same way, because I plan to also make that constant based, instead of weapon-length, if I figure out how the shield skill affects weapon length. Also, about bow/Power-Draw skill: a good check in the trigger condition would be to check for Power Draw level (e.g. if the agent has more than 2 PD, then he can use bow + shield together). But imo, that's it. Even if you have 4 or 5 PD, that doesn't mean you can use a bow with a large shield, realistically.
However, he wanted to test it a bit more, so the code might have evolved a bit more by now ^^

Perhaps interesting in connection with the bow & shield mechanic, a trigger which affects the bow accuracy depeding on the power draw skill https://forums.taleworlds.com/index...stions-and-answers.6575/page-532#post-5459192
Instead of the PD skill one could use the shield skill. Or simply a combination of both, adding up their values and depending on the sum it affects them differently. Just some addition food for thoughts ^^
 
Well, the problem is still how the shield skill affects the perceived (by the game engine) size of the shield. I have read somewhere that each Shield level point increased the area covered by the shield by an x%, which means trouble if you check for size.
 
Hm, does that really matter? Basically it just means that with a higher shield skill the player can move his shield faster. The little increase in size could be interpretated as such. However, checking for the item and then the items size should not take the skill into account, the operation is always giving the same value as result, isn't it?
 
Well, of course it matters! :razz:
If I check for shield_size 40, for example, and the Shield Skill gives 10% bonus, that means I cannot even use a small round shield of 35 size, with a skill of more than 5.
Silly example, but you get the idea. But yes, checking for both items AND size might do the trick. Or even just the item. That's why I said to define ranges of items.
 
The lazy way would be to introduce a new itp flag and simply mark with it all shields which should be able to get used as bow shields. Then you would only need to check if the wielded item in the left hand has that flag or not. Then you don't need to do all these calculations but can do as you feel for :lol:
 
Back
Top Bottom