1. selecting a hostile during combat lets you "parlay" with them. combat with them stops for a moment, and you can interact with them (talk, bribe, etc).

2. if you talk with them and relations improve enough, they stop attacking.

however there's already the following rule in the game (which is behavior programmed into the game engine):

1. if you're attacked while performing an action (like in The SIMs, microwaving dinner, or in this case talking to a NPC), you stop that action so you can fight.

if there's more than one hostile, the combo of these two sets of rules (parlay rules, and "combat stops actions") is that you start to talk to the first hostile, the second hostile continues to attack, the talk action get cancelled (you stop stalking to hostile #1), and hostile #1 starts attacking again.

should the player be able to parlay with the entire group at once?

or should talking during parlay take unrealistic zero time, and the disposition of all hostiles await its outcome?

or should one simply be unsuccessful at attempting to build a rapport over common interests in say travel and nature with a hostile during parlay, as long as his buddies are still trying to whack you with a big old nasty stick?

i guess group parlay that takes non-zero time is the right way to do it.

would it be unrealistic to let the player parlay with any hostile, and have the result of that parlay affect all hostiles in the group?

hostiles are now persistent in the simulation, so you can run into the same hostile again and again, and it tracks your relations with them over time. the player COULD select a known hostile from the group with whom they have better relations, in an attempt to increase their chances of successful parlay. but then again, thats what one would do in real life, so maybe thats ok?

I would imagine that parlay would be easiest either before fighting breaks out, or after it ends. In the first case, bandits could approach, say "your money or your life" and the player can attempt to speak then. Otherwise, a fight breaks out and the player can use nonlethal attacks (sleep spells, stunning, paralysis, etc) and once an enemy recovers from that there is a window of time where dialog is possible. To end a fight with speech likely requires using something to temporarily get everyone into that state of letting you talk.
Basically, knock everyone out with disabling spells, let them wake up, then talk to them to get them to stand down. Oe perhaps firing off a powerful spell "just to get their attention" will shock them enough to gain you a moment to start dialog.

I'd recommend the group if that's feasible, only on the basis given our aversion to danger and even harming each other, you'd expect hostile behavior to flow around a leader. So it makes sense that if you can dissuade the leader, you can convert the group.

I would imagine that parlay would be easiest either before fighting breaks out, or after it ends. In the first case, bandits could approach, say "your money or your life" and the player can attempt to speak then. Otherwise, a fight breaks out and the player can use nonlethal attacks (sleep spells, stunning, paralysis, etc) and once an enemy recovers from that there is a window of time where dialog is possible. To end a fight with speech likely requires using something to temporarily get everyone into that state of letting you talk. Basically, knock everyone out with disabling spells, let them wake up, then talk to them to get them to stand down. Oe perhaps firing off a powerful spell "just to get their attention" will shock them enough to gain you a moment to start dialog.

the bandits part is planned. at the moment , i'm dealing with bushwhackers, badguys who whack you for your stuff.

forgot to mention, no magic or techno. caveman rpg. so no lightning bolt spells or firing off a couple rounds from your grenade launcher to get their attention.

but you can attack to subdue, then capture, which, of course, would give ample time to talk, once they're safely tied up.

so you think (and the votes on your response says other agree) that one should not be able to yield in combat as in Oblivion?

i could see that in the case of bushwhackers, they're out to kill you right off the bat. but what about thieves, when you've had enough, and will turn over your goods? or fights that start with accidental friendly fire?

I'd recommend the group if that's feasible, only on the basis given our aversion to danger and even harming each other, you'd expect hostile behavior to flow around a leader. So it makes sense that if you can dissuade the leader, you can convert the group.

yes i was sort of thinking this too. that parlays are conducted between sides, not individual combatants.

"oh, by the way Joe, don't shoot the guy in the red shirt, we got a deal with him!"

implementation is a bit tricky. i have to switch all hostile targets to non hostile temporarily, then do a SIMs type conversation action between the player's character, and the hostile they select to talk to. then when that's done, do a fuzzy check on the relations, and then possibly switch all the hostiles back to attacking.

but when the player goes to parlay, how would they know the leader? give him a big hat or something? <g>

There is usually a protocol when doing a "PARLEY" that is to be understood by both sides.

Some distinctive sign (like the white flag), local cessation of aggressive activities (including movements that might indicate its false and just a delay for advantage.)

Usually once the other side likewise stops firing and usually does some action indicating that they accept -- like calling out to hear a verbal confirmation it then procedes on with a formal conference in the middle of the area between the opposing side . (with the rules being if no agreement is met that both side hold back from resuming fighting UNTIL the represenatives are back to their respective lines)

So for gaming purposes it is a bit more involved than a single action (and including the other side possibly NOT accepting even to take part (like when they have the upper hand in the battle/fight going on and the parley will gain them little they wont eventually just take)

--------------------------------------------Ratings are Opinion, not Fact

I think the best way to enter parley mode during battle is the way Oblivion does it, by keeping defensive stance without attacking for a little while, maybe 10 seconds on defensive stance may be enough to trigger parley mode. If I remember correctly this can only be done in Oblivion when the NPC attacking you is one (or many) imperial guard/s.

There is usually a protocol when doing a "PARLEY" that is to be understood by both sides.

good point.

parlay is probably something more formal between armies.

here, i'm talking about a melee with knives spears javelins and bows between 2 to 20 combatants total, up close, personal, fast, and furious.

in the fury of a melee like that, "parlay" sort of doesn't seem possible. it would be more like "surrender" would be the only option other than fight or flight. if you threw down your weapons, fell on the ground, and covered your head with your hands in an obvious sign of submission, they might spare you and take you captive.

but you should still probably be able to yield, as well as surrender. or perhaps yield gives you the opportunity to parlay or surrender, depending on how hostile they are.

so you could surrender at any time to any one to avoid death. whether they accept is another question.

and you could yield to anyone at anytime, in an attempt to stop combat. again, they may or may not accept. killers would never accept, unless you might be worth ransom as a prisoner. thieves would probably accept, its an easier way to get your stuff, without the risk of combat. friendlies would probably always accept - as the combat started by accident. yielding would essentially be crying uncle, saying "ok, enough!! stop!".

for all but killers, you'd stop all combat while "negotiations" ensued. killers wouldn't negotiate.

guess i need to add kidnappers too, who try to capture you for ransom.

I think the best way to enter parley mode during battle is the way Oblivion does it, by keeping defensive stance without attacking for a little while, maybe 10 seconds on defensive stance may be enough to trigger parley mode. If I remember correctly this can only be done in Oblivion when the NPC attacking you is one (or many) imperial guard/s.

block (left mouse button) + select (spacebar). any opponent, any combat, any time. they can accept or reject your yield. badguys (bandits, marauders, necromancers, etc ) always reject your yield. others, it depends on your relations. if they accept, time stops, and you go into talk mode with that npc. for guards, you go into talk mode and get the "resist arrest, pay fine , goto jail" menu.

my problem is that Caveman is like The SIMs, time doesn't stop during conversations. and neither do fights. so you're trying to "chat up" the guy who just accepted your yield, and the rest of them keep whacking you. when you do, the talk action gets canceled. the only way to avoid that is to stop time or stop combat. Zero time actions have pretty much gone away in this version of Caveman as unrealistic. even climbing in and out of your tent takes time. only 5 seconds or so, but it seems like forever when there's a sabertooth approaching! <g>.

so how about:

1. you can yield

2. you can surrender

3. killers never accept yield or surrender

4. thieves, kidnappers, and slavers always accept surrender and yield

5. surrendering or yielding to slavers or kidnappers makes you a captive

6. surrendering to yielding to thieves puts you into parlay - your stuff for your life. you can give them your stuff, or resume combat.

7. friendlies and neutrals may or may not accept your yield or surrender (fuzzy relations check).

8. if a friendly or neutral accepts your surrender or yield, it puts you into parlay, and you must improve relations to end combat.

9. if you successfully yield or surrender, it stops combat.

10. combat resumes after an unsuccessful parlay.

actually, in the above list, surrender and yield have the same effects in all cases. might as well just call it surrendering.

At the risk of over-complicating things, maybe you could tighten up the various scenarios just by having a "relations floor" where relations must be at least X to even attempt a parlay. There's a big difference between fighting a guy with blood in his eyes bent on revenge because you killed his brother, and fighting a stranger in the wilderness who may not be intent on fighting but believes he must defend himself from an aggressor.

You could then indicate to the player in some way where relations stand and thereby reduce the possible scenarios somewhat.

I'm working on a game! It's called "Spellbook Tactics". I'd love it if you checked it out, offered some feedback, etc. I am very excited about my progress thus far and confident about future progress as well!

You could add something like a parlay state into combat so a hostile NPC will not attack the player is in parlay but will not become friendly. Then as soon as parley ends the hostile can begin attacking. Basically a continuous loop of the attacker going "can I kill you yet" until you are done talking.

Also a possibility is letting NPCs command each other so when you enter parlay with an NPC, it commands all others to stop being hostile. When parlay ends that NPC can command the others to become hostile again.

You could add something like a parlay state into combat so a hostile NPC will not attack the player is in parlay but will not become friendly. Then as soon as parley ends the hostile can begin attacking. Basically a continuous loop of the attacker going "can I kill you yet" until you are done talking.

Also a possibility is letting NPCs command each other so when you enter parlay with an NPC, it commands all others to stop being hostile. When parlay ends that NPC can command the others to become hostile again.

it looks like the way to implement it will be to add a is_parlaying boolean field to an animalrec (a target record in the database of active targets in the simulation).

if a yield is accepted, and it doesn't automatically result in capture, the player is presented with the talk to caveman menu, or a menu for thieves (give all stuff, or resume combat).

the talk to caveman menu allows a variety of actions: gifting, trading, teaching, learning, healing, etc. during parlay most of these will be of little use except for gifting, trading, and talking. gifting and trading are "zero-time" actions, and happen immediately when the player makes the menu pick. but talking takes time, like when you talk to another sim in The SIMs.

if the player selects talk and triggers a talk action, the is_parlaying flags get set to 1 for all active hostiles near the PC in question, and then the simulation resumes, allowing the talk action to occur.

an extra line or two of code will be added to get_hostile_tgt to not target the player's party if is_parlaying is set, but continue to target and attack wild animals for example.

get_friendly_tgt will need to be modified so friendlies/neutrals don't target hostiles who are in parlay. same for band members, traveling companions, hired warriors, and tamed animals - so basically all the good guy AI targeting routines.

each PC has an array of 10 generic variables ( int actiondata[10] ) to hold action specific data, such as the ID number of an object you're fixing, how tired you were when you went to sleep, whether you're in parlay, who you're parlaying with, etc.

an variable will be set in the player's actiondata array, indicating that the talk action is part of a parlay.
a second variable in the player's actiondata array will indicate the npc #.

the talk action handler code will be modified as follows:
when the talk action completes, if the is part of a parlay flag is set, do a fuzzy relations check between the PC and the NPC. if the check succeeds, set all is_parlaying hostiles near the PC in question to neutral, and set their relations with the PC from -100 to -99, where -100 is always attack. then clear all the is_parlaying flags of hostiles near the PC in question, and you're done, continue with the simulation (RET from your INT handler, so to speak - TSR programming talk there). if they're still hostile after the end of all that, they'll resume combat, if not, they won't (but it will be REALLY easy to provoke them, so best to just leave the area).

the only other option than stopping combat is to stop time for a special zero-time parlay-talk action. which might be easier to implement, but is less realistic, and unlike the way the rest of the game works.

now the question is, what happens when you get it all going on at once?

you're at a friendly/neutral cave trading, wild animals appear, then right way, hostiles appear. combat ensues, with the player's party and the local friendly/neutrals on one side, the hostiles on a scond side, and the animals on a third side. the player yields and parlays. player's party etc stop fighting with the hostiles. everyone starts attacking just the animals. player is free to conduct talk action with npc, unless attacked by animal.

if player is attacked by animal, talk action stops, but hostiles etc are still "in_parlay" mode. so they don't attack. player must complete talk action to reset "in_parlay" flags. but what if the player doesn't resume or start another talk action? in_parlay flags don't get cleared, and those combatants will ignore their foes from then on. could make the code only ignore nearby hostiles in parlay vs all hostiles when you're in parlay, but NPCs whose "in_parlay" flag doesn't get reset will never resume combat.

so the rules aren't airtight yet, and i still can't implement.

perhaps a counter for how long they've been in parlay.

make "in_parlay" a counter, instead of a boolean. 0 = not in parlay.

initialize it to zero.

when they go into parlay, set it to 1.

add a "model_parlay_expiration" routine to "do_global_frame" or "do_global_second".

"model_parlay_expiration" would increment "in_parlay" counters, and check for time expired (counter past some limit). time expired would have to be long enough for combat with animals, followed by a resumption of negotiations (another talk action).

if time expired, reset the "in_parlay" counter to zero, so the unit follows the normal tageting AI.

that way yielding and talking only buys you a temporary reprieve, and the player can't take undue advantage of a half-assed implementation.

I don't think I ever really used the 'yield' feature in Oblivion and in Skyrim I know I had problems un-equiping my weapons. What if there was an equipable item like a white flag you could use that basically said "I yield" to everyone around you? It takes up both hands so it's like unequiping your weapons. Different flags could also communicate things like "I surrender", "I want to talk", "I want to negotiate terms to cross your lands", or "If you attack me, the guy who sent me will bring his army to murder your whole family".

I don't think I ever really used the 'yield' feature in Oblivion and in Skyrim I know I had problems un-equiping my weapons. What if there was an equipable item like a white flag you could use that basically said "I yield" to everyone around you? It takes up both hands so it's like unequiping your weapons. Different flags could also communicate things like "I surrender", "I want to talk", "I want to negotiate terms to cross your lands", or "If you attack me, the guy who sent me will bring his army to murder your whole family".

caveman rpg. no techo. no magic.

no equipping stuff. you're assumed to always us the best gear on you. current weapon and ammo type are the only things the player must select manually.

Might I suggest that parlaying is only an option when your opponents (as a group) make it an option. For example, if you're proving too dangerous to kill, there's not enough profit in it for them, there's a bigger third-party threat (such as a saber-tooth tiger), or they are generally too tired/scared/demoralised. In that scenario there would be some visible/audible signal that they were willing to negotiate and you need to initiate at that moment (or at least generally not screw it up by attacking them).