- Fix: dynamic opinion events on finishing battle did not occur due to faulty sector coordinates
- Fix: dynamic dialogue boxes were displayed with bad screen coordinates
- Change: dynamic dialogue is also written into tactical log
- Change: in events that require a leader, any merc can be considered leader, not just IMPs
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7807 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- I've changed the GROUP struct - instead of BOOLEAN fPlayer we now have UINT8 usGroupTeam.
- To further simplify the code, I've replaced
UINT8 NumEnemiesInSector( INT16 sSectorX, INT16 sSectorY );
with
UINT8 NumNonPlayerTeamMembersInSector( INT16 sSectorX, INT16 sSectorY, UINT8 ubTeam );
In the next days, more strategic functions will be simplified, merged and replaced.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7707 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- Externalized the difficulty setings to "TableData\DifficultySettings.xml" file
- Some INI Settings (ja2_options.ini, CTHConstants.ini and Creature_Settings.ini) moved from INI file to this xml file
- see #define DIFFICULTY_SETTING
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7447 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- new feature: ramming people - set with Tactical Gameplay Settings > ALLOW_CARS_DRIVING_OVER_PEOPLE and Tactical Gameplay Settings > ALLOW_TANKS_DRIVING_OVER_PEOPLE - when shift is pressed planned vehicle route will go through people. Those who will stay on its path will be hit, causing wounds and knock-outs.
- new feature: ramming structures - when shift is pressed planned vehicle route will go through obstacles. When vehicle hits the structure on its path it will be destroyed, causing small damage to vehicle too (with exception of tank). Tactical Gameplay Settings > CARS_RAMMING_MAX_STRUCTURE_ARMOUR and Tactical Gameplay Settings > TANKS_RAMMING_MAX_STRUCTURE_ARMOUR settings control how well armoured structure can be driven through and amount of potential damage for vehicle.
- see: http://www.ja-galaxy-forum.com/ubbthreads.php/topics/333829/Drivable_Vehicles#Post333829
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7284 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- feature: tanks can move around in tactical. Set with Tactical Gameplay Settings > ENEMY_TANKS_CAN_MOVE.
- feature: tanks can ignore chance to get through and destroy enemy cover even if it probably won't hit anyone behind it. Set with Tactical Gameplay Settings > ENEMY_TANKS_BLOW_OBSTACLES_UP.
- feature: tanks can use cannon even against single mercs and in perfect health. Set with Tactical Gameplay Settings > ENEMY_TANKS_DONT_SPARE_SHELLS.
- feature: tanks can noticed as soon as any part of it is visible. Set with Tactical Gameplay Settings > ENEMY_TANKS_ANY_PART_VISIBLE.
- feature: depending on game difficulty enemy patrols at game start can be randomly reinforced with tank. Set with Strategic Gameplay Settings > ARMY_USES_TANKS_IN_PATROLS.
- feature: depending on game difficulty enemy groups created during offensives can include tanks. Set with trategic Gameplay Settings > ARMY_USES_TANKS_IN_ATTACKS.
- feature: mercs in vehicles automatically rest their guns,
- fix: guns can be rested on vehicles,
- rewritten code to allow putting enemies inside vehicles,
- added missing descriptions for all vehicle options to INIEditorJA2Options.xml.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7277 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- Requires GameDir r2050.
- new background property: <dislikebackground> allows mercs to dislike specific backgrounds
- Fix: snitches did not correctly prevent misbehaviour
- Fix: morale event was not handled
- Fix: DropDowns did not refresh when using the arrow buttons
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7240 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- externalised vehicle seats (TableData\Vehicles.xml) influence position of passenger, field of view, ability to shoot and being hidden,
- seat can chosen by using ctrl+RMB on vehicle (ctrl + LMB just takes the first visible seat)
- seats can be changed or swapped while inside vehicle,
- remade JSD files for cars,
- vehicles aren't transparent anymore,
- vehicles are louder than people, depending how fast they move.
see: http://www.bears-pit.com/board/ubbthreads.php/topics/332790/5.html
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7212 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- Streamlined vehicle controls - no more selecting driver and vehicle separately, switching displayed APs and other esoteric activities. To move vehicle just select its driver and you're good to go. If you click on vehicle in tactical, also its driver will be selected automatically. Besides driving car, driver can perform other actions normally.
- Vehicle's APs, health and fuel are displayed on the steering wheel - thanks to Buggler for idea. Vehicle APs are treated as a resource (so if car changes driver mid-turn, it won't go any further than it would).
- Added option Tactical Interface Settings > ADD_PASSENGER_TO_ANY_SQUAD. If you order passenger to exit vehicle by clicking on the seat belt, he'll be added to new squad, so if you ordered six passengers to exit one by one, you'd end up with six new squads. With ADD_PASSENGER_TO_ANY_SQUAD = TRUE, passenger will be added to any existing squad with empty slot if possible.
- Added option Tactical Interface Settings > PASSENGER_LEAVING_SWITCH_TO_NEW_SQUAD. If you order passenger to exit vehicle by clicking on the seat belt, by default you get switched to his new squad. With PASSENGER_LEAVING_SWITCH_TO_NEW_SQUAD = FALSE you'll switch only if exiting passenger is the selected one.
- Cosmetic fix: changed display above vehicle from "*Merc's name* (VEHICLE)" to "*Merc's name* (*Vehicle's name*)" and colour from yellow to white (since mercs in vehicle are controllable and yellow is reserved for mercs on assignments).
- Fixed passengers rotation. Again.
- Fixed vehicles getting "tired" - lowered APs due to fuel below max. They can move the same as long as they have any fuel.
- Fixed unrelated bug: clicking on any empty slot in team panel would select merc with id 0.
- Fixed unrelated bug: switching to squad with less mercs would cause team panel to still show skill tooltips for mercs from previous squad on empty slots.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7204 3b4a5df2-a311-0410-b5c6-a8a6f20db521
Fixes (by Buggler)
- Allow hotkey squad switching to include squads in vehicles as well
- Fixed wrong sign used for bSpeedModifierTrainingMilitia and bSpeedModifierTeachingOthers
- Fixed usMobileMilitiaTraining value not read causing mobile militia training speed to be doubled
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7198 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- To control vehicle, click on it or on the steering wheel in team panel under driver's portrait.
- Vehicles have two gears - slow drive and fast drive, switchable just like walking and running ('S', 'R', double-click).
- Vehicles working: Ice Cream Van, Hummer, Jeep, El Dorado and, potentially, tanks.
- Passengers can be selected and ordered to open fire from the inside
- You can also open inventory screen for passengers, pass or throw items, etc.
Normally vehicle is treated as any other merc and has its own APs. It has obvious disadvantages - it's possible to drive in the middle of the enemy group using vehicle's 100AP,
and then use all your mercs inside vehicle with their still full APs to kill everything that moves at point blank range - with even the driver participating!
- To prevent that you can set Tactical Gameplay Settings > AP_SHARED_AMONG_PASSENGERS_AND_VEHICLE_MODE with following calculation methods
more infos: http://www.bears-pit.com/board/ubbthreads.php/topics/332208/1.html
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7193 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- Covert Ops: Bleeding is deemed suspicious only if COVERT_DETECTEDIFBLEEDING is set to TRUE.
- renamed special prisoners to officers.
- lowered the priority of enemy troops becoming medics
- prisoners in player-controlled prisons now use the prioner-colour scheme used by Shank and Dynamo
Requires GameDir >= r2028.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7179 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- Flagmasks are unsigned, and should be called and treated as such
- Fix: experience gain from interrogation was too high
- Fix: chance of a prisoner becoming militia was calculated wrong
- default weight maximum for MOVE ITEM assignment increased from 30 to 40 kg
- Fix: snitches report the same event multiple times
- Fix: snitches treat vehicles as persons
- Fix: selection of launchables is inefficient, an does not take into account wether items are depending on day/night cycle
- new key combination: in strategic, pressing [CTRL] + [E] wile both a merc's inventory and the sector inventory are open will fill the merc's inventory with sector items
- trivial code cleanup
- if prisoners are taken in a sector that houses a prison, that prison can also be selected to house them
- Fix: distributing newly taken prisoners in a prison sector no longer redistributes all prisoners, only the new ones
- GetClosestFlaggedSoldierID can also be called without evaluation of sight
- Fix: Covert Ops: throwing/lobbing items or shooting rockets is deemed suspicious behaviour
- Fix: boxing was broken by loading a savegame
- Fix: campaign history rarely recorded kills in autoresolve
- There is no reason why the IDs that boxers are reset to before they are reinitialised would ever need to be altered by a modder. Required script change in stable GameDir r2024.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7178 3b4a5df2-a311-0410-b5c6-a8a6f20db521
Externalized keys and locks to xml (by anv)
- Locks (TableData/Items/Locks.xml): Originally 64 locks were kept in BinaryData/LOCKS.BIN. Now up to 255 locks can be specified in TableData/Locks.xml. If it isn't found, LOCKS.BIN will be loaded normally.
- Keys (TableData/Items/Keys.xml): Originally 10 keys were hardcoded in KeyTable[]. Now up to 255 keys can be specified in TableData/Keys.xml. If it isn't found, hardcoded array will be used normally.
see: http://www.bears-pit.com/board/ubbthreads.php/topics/331900.html
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7164 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- ja2_options.ini: MAX_BACKPACK_WEIGHT_TO_CLIMB, USE_GLOBAL_BACKPACK_SETTINGS
- First setting is sBackpackWeightToClimb which is the maximum weight a backpack can weigh and still allow you to climb with. The sBackpackWeightModifier in items.xml can modify that number by either making it harder (positive number modifier) or easier (negative number modifier). If the sBackpackWeightToClimb is -1 (default) then the option is unused.
Second setting is fUseGlobalBackpackSettings which if true (default) uses the same rules for all backpacks, while if false it checks for the fAllowClimbing tag in items.xml, and if that is true you can climb with said backpack.
Both options can be used at the same time, so you may climb with (for example) a malice backpack that weighs less than 5kg (or 50 hg) but not climb with a radio set.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7146 3b4a5df2-a311-0410-b5c6-a8a6f20db521
Bugfixes (by anv)
- autofeeding bug,
- drop items on dismiss optimization,
- effectiveness of suppression was increased/decreased with every influenced soldier if set to other than default 100,
- item status changed to INT16 on item create - item status is also used to specify amount of money (*50), if NPC had a lot of money in his starting gear, its amount would be incorrect.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7139 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- lowered ENEMYROLES_TURNSTOUNCOVER
- increased ENEMY_MEDICS_SEARCHRADIUS
- new option: ENEMY_MEDICS_WOUND_MINAMOUNT controls how serious a wound must be before a medic considers it worthy of attention
- new option: ENEMY_MEDICS_HEAL_SELF: medics can heal themselves
- new option: ENEMY_OFFICERS_SURRENDERSTRENGTHBONUS adds a team surrender strength bonus for officers
- tanks cannot become medics, and can't be treated by them either
- Menubutton for Role symbol toggle is red if off and green if on
- wounded soldiers seek medics, max range is ENEMY_MEDICS_SEARCHRADIUS / 2
- direct sight line between medic and target is no longer required
- if hostile civilians allied to the army are in sector, their surrender strength is added to the enemy team
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7080 3b4a5df2-a311-0410-b5c6-a8a6f20db521
More visual enemy gear info (by Sevenfm)
- Show additional info in NCTH cursor (press ALT) (ADDITIONAL_NCTH_CURSOR_INFO = 2)
-> You can only use this feature at certain distance
- Updated 'show enemy weapon' feature (SHOW_ENEMY_WEAPON = TRUE, SHOW_ENEMY_EXTENDED_INFO = TRUE)
- Now it can show armour and face items, too. Useful for OCTH users (SHOW_ENEMY_AWARENESS = TRUE)
- Show total value of damage, absorbed by armour in last attack (SHOW_HIT_INFO = TRUE)
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7078 3b4a5df2-a311-0410-b5c6-a8a6f20db521
Requires GameDir >= r1987.
- If an enemy is spawned with a radio set, he is more likely to become a radio operator.
- It is now possible to mount a gun on prone allies if you are facing them on the right angle.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7072 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- Minor code improvements and cleanup
- Fix from r6775 is no longer necessary.
- Code improvement: Instead of calling inv.size() repeatedly, just call it once and remember that value
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6829 3b4a5df2-a311-0410-b5c6-a8a6f20db521
1) PLAYER_HIT_COUNT = 0
This works as ENEMY_HIT_COUNT option, but for player mercs.
Possible values: 0 - 4
2) SOLDIER_TOOLTIP_DISPLAY_SUPPRESSION_INFO = TRUE
Show additional info in tactical tooltip:
- APs lost due to suppression
- Suppression Tolerance
- Effective Shock Level ( Shock level modified by traits and backgrounds. This value is compared with current suppression tolerance to determine "cowering" effect )
- AI morale level
3) SHOW_ENEMY_WEAPON = TRUE
Show enemy weapon name above soldier - after health, name and rank.
You can see exact weapon name only on short distances, range calculation is similar to dynamic tooltips and based on soldiers actual viewing range and experience.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6691 3b4a5df2-a311-0410-b5c6-a8a6f20db521
see: http://www.bears-pit.com/board/ubbthreads.php/topics/172712/16/Code_Snippets.html
1) ENEMY_HIT_COUNT in ja2_options.ini accepts 2 new parameters:
3 - show damage as white asterisks
4 - show damage as red asterisks
Number of asterisks is scaled (maximum 5): >0, >10, >30, >60, >100
2) Suppression tactical tooltip now shows suppression points from last attacks.
Previously it was always = 0 because ubSuppressionPoints value is cleared after each attack.
3) It is now possible to show suppression values above soldier, just as hit count.
There are new options in ja2_options.ini
Possible values:
0 - do not show
1 - show on moving hit counter
2 - show above soldier
The values are color coded:
Suppression is light gray
Shock is yellow
AP loss is blue
Morale hit is green
SHOW_SUPPRESSION_COUNT = 0
SHOW_SHOCK_COUNT = 0
SHOW_AP_COUNT = 0
SHOW_MORALE_COUNT = 0
This option defines if values are shown as numbers or asterisks (1..5, using scale)
SHOW_SUPPRESSION_USE_ASTERISK = FALSE
This option defines if only 1 asterisk is shown or several (1..5) to represent value
SHOW_SUPPRESSION_SCALE_ASTERISK = TRUE
Show suppression above soldier during enemy attack. All other values are shown after attack, when HandleSuppressionFire function is calculated.
SHOW_SUPPRESSION_COUNT_ALT = TRUE
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6689 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- mercs with the 'airdrop' background property do no get the interrupt penalty upon landing only if they have a positive bonus
- Fix: supression resistence wasn't applied as a percentage
- adjusted background min/max values
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6665 3b4a5df2-a311-0410-b5c6-a8a6f20db521
- Currently MercProfiles.xml contains 5 records for buddies and 5 for foes + 1 per "learn to", but in code only 2 first + "learn to" are handled. I changed it so all possible buddies and foes can be used, and it's possible to add their specific like/dislike quotes to quote .edts.
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6538 3b4a5df2-a311-0410-b5c6-a8a6f20db521