Toni Carrera Posted August 17, 2021 Posted August 17, 2021 Hi Fellow Pilots, For reasons relating to my CDO, which is the same as OCD, but the letters are in the right order, is it possible to prevent promotion. I want to remain a 'Captain'. I adjusted the lines in the LogBook.lua to put me back when I got promoted, but wondered if the was a perhaps different way to do it, rather than having to edit the file over and over Thank you for your time Toni Carrera (Ice Rhino) ThrustMaster HOTAS Warthog Throttle & A10C Stick, ThrustMaster F/A-18C Stick, ThrustMaster TFRP Pedals, ThrustMaster Cougars x 2, fitted to CubeSim USB Screens, TrackIR 4 Active LED & Cap Reflector, Stream Deck XL Intel® Core™ i7-5820K 12 Core Processor, 32GB RAM, 1 x 500GB SSD, 2 x 256GB SSD, 1 x 1TB SSD 4 x 4TB Western Digital Mechanical. 2 x ASUS GTX 1080's SLI, ASUS 29" Ultrawide flanked by 2 x 22" IPS Monitors
ED Team BIGNEWY Posted August 17, 2021 ED Team Posted August 17, 2021 Hi, as far as I am aware this is not possible, with that said I am not a coder, there are some talented users out there that may have a solution for you. thanks Forum rules - DCS Crashing? Try this first - Cleanup and Repair - Discord BIGNEWY#8703 - Youtube - Patch Status Windows 11, NVIDIA MSI RTX 3090, Intel® i9-10900K 3.70GHz, 5.30GHz Turbo, Corsair Hydro Series H150i Pro, 64GB DDR @3200, ASUS ROG Strix Z490-F Gaming, PIMAX Crystal
Northstar98 Posted August 17, 2021 Posted August 17, 2021 4 hours ago, Ice Rhino said: Hi Fellow Pilots, For reasons relating to my CDO, which is the same as OCD, but the letters are in the right order, is it possible to prevent promotion. I want to remain a 'Captain'. I adjusted the lines in the LogBook.lua to put me back when I got promoted, but wondered if the was a perhaps different way to do it, rather than having to edit the file over and over Thank you for your time One workaround is to go into your Saved Games -> DCS -> MissionEditor -> logbook.lua file, open it in Notepad++, find your pilot and manually change the entries under ["rank"] and ["rankName"] to "Captain". Best to make a backup of the file first before modifying it, just in case. Modules I own: F-14A/B, F-4E, Mi-24P, AJS 37, AV-8B N/A, F-5E-3, MiG-21bis, F-16CM, F/A-18C, Supercarrier, Mi-8MTV2, UH-1H, Mirage 2000C, FC3, MiG-15bis, Ka-50, A-10C (+ A-10C II), P-47D, P-51D, C-101, Yak-52, WWII Assets, CA, NS430, Hawk. Terrains I own: South Atlantic, Syria, The Channel, SoH/PG, Marianas. System: GIGABYTE B650 AORUS ELITE AX, AMD Ryzen 5 7600, Corsair Vengeance DDR5-5200 32 GB, NVIDIA GeForce RTX 4070S FE, Western Digital Black SN850X 1 TB (DCS dedicated) & 2 TB NVMe SSDs, Corsair RM850X 850 W, NZXT H7 Flow, MSI G274CV. Peripherals: VKB Gunfighter Mk.II w. MCG Pro, MFG Crosswind V3 Graphite, Logitech Extreme 3D Pro.
BuzzLine Posted August 19, 2021 Posted August 19, 2021 Maybe I can be of help. I have not tested it but, from reading the code, it seems like a small change may solve your issues. The code triggering the promotion seems to be this block below (in file MissionEditor/modules/me_logbook.lua , around line 1266) : if (ProductType.getType() ~= "LOFAC") and (r.name ~= currentPlayer.player.rankName) then currentPlayer.player.rank = r.nativeName currentPlayer.player.rankName = r.name displayPromotionGreeting(r.nativeName) end You want this to never execute. There are several ways. 1. You can simply remove those 5 lines ! (Do make a copy of the file, should you want/need to revert. Or just use the standard "repair" function from the standalone client or Steam, whichever is the way you manage your install) 2. You can replace just the first one by this one here below (I've added "false and", which is easy to revert and prevents the updating code from executing): if false and (ProductType.getType() ~= "LOFAC") and (r.name ~= currentPlayer.player.rankName) then 3. Or comment all the whole block by adding "-- " (that's dash, dash, space) in front of each line. The code is still here should you want to read it but the computer will skip all the lines starting with -- : -- if false and (ProductType.getType() ~= "LOFAC") and (r.name ~= currentPlayer.player.rankName) then -- currentPlayer.player.rank = r.nativeName -- currentPlayer.player.rankName = r.name -- displayPromotionGreeting(r.nativeName) -- end There are other ways but these three are the simplest. I would go for the first option. Brutal but effective. We can call it Code Disappearance Option (CDO). Note : It will work until a future patch updates this file, reverting it to ED's provided version, and then you'll have to put back those modifications... Hope this helps, Buzz. Note : there is another way: changing the threshold at which the rank of captain ends, set it to a value beyond the heat death of the universe. The value lives somewhere in dbCountries but I don't know where that db lives or if it's encrypted or not. Maybe someone knows ? Although I suspect this db might change even more often than that lua file...
Toni Carrera Posted August 21, 2021 Author Posted August 21, 2021 (edited) Hi BuzzLine, Thank you so much for taking the time to write this all up for me. I will put it to the test after I have repaired my DCS, because something has gone horribly wrong with my installation I also appreciate your consideration of my CDO with the options of the module/coding description Again, sincerest thanks Edited August 21, 2021 by Ice Rhino Toni Carrera (Ice Rhino) ThrustMaster HOTAS Warthog Throttle & A10C Stick, ThrustMaster F/A-18C Stick, ThrustMaster TFRP Pedals, ThrustMaster Cougars x 2, fitted to CubeSim USB Screens, TrackIR 4 Active LED & Cap Reflector, Stream Deck XL Intel® Core™ i7-5820K 12 Core Processor, 32GB RAM, 1 x 500GB SSD, 2 x 256GB SSD, 1 x 1TB SSD 4 x 4TB Western Digital Mechanical. 2 x ASUS GTX 1080's SLI, ASUS 29" Ultrawide flanked by 2 x 22" IPS Monitors
BuzzLine Posted August 21, 2021 Posted August 21, 2021 Happy to help. Tell me if it solves your issue, whenever you get to test it. Cheers ! Buzz
Recommended Posts