From d840408a5f822c14d266a37a2648336b6fae97a2 Mon Sep 17 00:00:00 2001 From: Rampastring Date: Mon, 29 Apr 2024 20:24:31 +0300 Subject: [PATCH] Implement speech selection window --- src/TSMapEditor/Config/Speeches.ini | 582 ++++++++++++++++++ .../Config/UI/Windows/SelectSpeechWindow.ini | 33 + src/TSMapEditor/Constants.cs | 2 +- src/TSMapEditor/Models/EditorConfig.cs | 26 + src/TSMapEditor/TSMapEditor.csproj | 6 + .../UI/Windows/SelectSpeechWindow.cs | 46 ++ src/TSMapEditor/UI/Windows/TriggersWindow.cs | 25 + 7 files changed, 719 insertions(+), 1 deletion(-) create mode 100644 src/TSMapEditor/Config/Speeches.ini create mode 100644 src/TSMapEditor/Config/UI/Windows/SelectSpeechWindow.ini create mode 100644 src/TSMapEditor/UI/Windows/SelectSpeechWindow.cs diff --git a/src/TSMapEditor/Config/Speeches.ini b/src/TSMapEditor/Config/Speeches.ini new file mode 100644 index 00000000..d962d13e --- /dev/null +++ b/src/TSMapEditor/Config/Speeches.ini @@ -0,0 +1,582 @@ +; C&C World-Altering Editor (WAE) +; https://github.com/Rampastring/WorldAlteringEditor + +; Provides speech descriptions for the "Play speech" trigger action. + +; = +[Speeches] +0=00-I026 EVA/CABAL Mission accomplished +1=00-I028 EVA/CABAL Your mission has failed +2=00-I064 EVA/CABAL Unable to comply, building in progress +3=00-I018 EVA/CABAL Construction complete +4=00-I076 EVA/CABAL Unit ready +5=00-I032 EVA/CABAL New construction options +6=00-I016 EVA/CABAL Cannot deploy here +7=00-I008 EVA/CABAL Structure destroyed GDI structure destroyed +8=00-I022 EVA/CABAL Insufficient funds +9=00-I012 EVA/CABAL Battle control offline +10=00-I038 EVA/CABAL Reinforcements have arrived +11=00-I220 EVA/CABAL Canceled +12=00-I216 EVA/CABAL Building +13=00-I024 EVA/CABAL Low power +14=00-I082 EVA/CABAL Base under attack +15=00-I034 EVA/CABAL Primary building set +16=00-I074 EVA/CABAL Unit lost +17=00-I042 EVA/CABAL Select target +18=00-I044 EVA/CABAL Silos needed +19=00-I218 EVA/CABAL On hold +20=00-I040 EVA/CABAL Repairing +21=00-I062 EVA/CABAL Training +22=00-I068 EVA/CABAL Unit armor upgraded +23=00-I070 EVA/CABAL Unit firepower upgraded +24=00-I080 EVA/CABAL Unit speed upgraded +25=00-I078 EVA/CABAL Unit repaired +26=00-I228 EVA/CABAL Structure sold +27=00-I090 EVA/CABAL Harvester under attack +28=00-I172 EVA/CABAL Cloaked unit detected +29=00-I174 EVA/CABAL Subterranean unit detected +30=00-I122 EVA/CABAL 20 minutes remaining +31=00-I124 EVA/CABAL 10 minutes remaining +32=00-I126 EVA/CABAL 5 minutes remaining +33=00-I128 EVA/CABAL 4 minutes remaining +34=00-I130 EVA/CABAL 3 minutes remaining +35=00-I132 EVA/CABAL 2 minutes remaining +36=00-I134 EVA/CABAL 1 minute remaining +37=00-I226 EVA/CABAL Unit sold +38=00-I056 EVA/CABAL Building captured +39=00-I200 EVA/CABAL Establishing battlefield control, standby +40=00-I176 EVA/CABAL Ion storm approaching +41=00-I178 EVA/CABAL Meteor storm approaching +42=00-I198 EVA/CABAL New terrain discovered +43=00-I150 EVA/CABAL Missile launch detected +44=00-I152 EVA/CABAL Chemical missile ready +45=00-I154 EVA/CABAL Cluster missile ready +46=00-I156 EVA/CABAL Ion cannon ready +47=00-I158 EVA/CABAL EMPulse cannon ready +48=00-I162 EVA/CABAL Firestorm defense ready +49=00-I170 EVA/CABAL Firestorm defense offline +50=00-I100 EVA/CABAL Primary objective achieved +51=00-I102 EVA/CABAL Secondary objective achieved +52=00-I104 EVA/CABAL Tertiary objective achieved +53=00-I106 EVA/CABAL Quaternary objective achieved +54=00-I194 EVA/CABAL Critical unit lost +55=00-I196 EVA/CABAL Critical structure lost +56=00-I208 EVA/CABAL Mutant supplies found +57=00-I210 EVA/CABAL Commandos en route +58=00-I014 EVA/CABAL Building infiltrated +59=00-I058 EVA/CABAL Timer started +60=00-I060 EVA/CABAL Timer stopped +61=00-I118 EVA/CABAL Bridge repaired +62=00-I180 EVA/CABAL Base defenses offline +63=00-I230 EVA/CABAL Building offline +64=00-I232 EVA/CABAL Building online +65=00-I252 EVA/CABAL Player has resigned +66=00-I268 EVA/CABAL Player was defeated +67=00-I284 EVA/CABAL You are victorious +68=00-I286 EVA/CABAL You have lost +69=00-I288 EVA/CABAL You have resigned +70=00-I290 EVA/CABAL Mutant commandos available +71=00-I304 EVA/CABAL Alliance formed +72=00-I306 EVA/CABAL Alliance broken +73=00-I308 EVA/CABAL Our ally is under attack +74=00-I310 EVA/CABAL Build more powerplants to restore full power +75=00-I312 EVA/CABAL Build barracks to train additional troops +76=00-I314 EVA/CABAL Build hand of Nod to train additional troops +77=00-I316 EVA/CABAL Build a tiberium refinery to harvest tiberium +78=00-I318 EVA/CABAL Build tiberium silos to store excess tiberium +79=00-I344 EVA Inferior tactics detected +80=00-I346 EVA Retreat is your only logical option +81=00-I348 EVA Surrender is your only logical option +82=00-I352 EVA Your defeat is at hand +83=00-I356 EVA You have been marked for termination +84=00-I360 EVA Time to erase human factor from this equation +85=00-I370 EVA Your probability of success is insignificant and dropping +86=00-I372 EVA Surrender is acceptable and preferable against the odds you are facing +87=00-I374 EVA Data received indicates that you are a threat, prepare for sterilization +88=00-I376 EVA Defeat of enemy predicted in T minus 3 2 1 +89=01-I342 CABAL Inferior tactics detected +90=01-I350 CABAL Observe superior tactics while you still have human eyes +91=01-I352 CABAL Your defeat is at hand +92=01-I356 CABAL You have been marked for termination +93=01-I360 CABAL Time to erase human factor from this equation +94=01-I362 CABAL Prepare for decimation, for you are not worthy of assimilation +95=01-I364 CABAL You make this easy fleshbag +96=01-I366 CABAL We tire of your insignificant defiance +97=01-I368 CABAL The sacrifice of the many is what the pleasure for the few +98=01-I378 CABAL Terminator protocol initiated, proceed it with final sweep +99=33-N000 GDI Where the hell are those reinforcements +100=33-N002 GDI Its Nod sir, they came out of nowhere, we have to get back to the base and rebuild the barracks and refinery before they hit us again +101=33-N004 GDI Sir, looks like they tore this place apart already, Nod must be ready to ship the artifact out, we don't have much time +102=33-N008 GDI Here they come +103=33-N010 GDI Is there any tech left at the Nod base +104=33-N012 GDI These critters don't look too friendly +105=33-N014 GDI The cavalry has arrived +106=33-N020 GDI I believe there is an old GDI base near, could be worth looking into +107=33-N022 GDI Here comes Kane's welcoming committee +108=33-N024 GDI What's the ETA on that MCV, this UFO gives me heebie jeebies +109=35-N000 GDI This is lieutenant Stark, we have touched down on our waiting Tratos for immediate evac, get him over here, ASAP +110=35-N002 GDI Nod forces are converging on our position sir, with all due respect, move your ass +111=35-N004 GDI Coordinates transmitted and confirmed, ETA for airstrike is 5 minutes +112=35-N008 GDI Pickup service +113=35-N010 GDI Negative, I can make it +114=35-N012 GDI I said, I can make it +115=35-N014 GDI I can uaaaah +116=40-N000 BOTH We have been touched by the spirit hand of Kane, and are ready to serve the technology of peace, peace through power +117=00-N000 EVA To begin harvesting tiberium, build a tiberium refinery +118=00-N002 EVA Harvester will automatically begin harvesting any nearby tiberium +119=00-N004 EVA In order to build more troops, build a barracks +120=00-N006 EVA Destroy all Nod forces in the area +121=00-N018 EVA Civilian killed +122=00-N020 EVA Nod sam sites destroyed +123=00-N022 EVA GDI transports en route +124=00-N024 EVA Civilians evacuated, objective complete +125=00-N032 EVA Site secure, objective complete +126=00-N034 EVA Technology center captured, objective complete +127=00-N040 EVA Base destroyed, objective complete +128=00-N042 EVA It would be advantageous to destroy any bridges leading from this region +129=00-N044 EVA Bridges destroyed, objective complete +130=00-N052 EVA UFO under attack +131=00-N054 EVA UFO destroyed, mission failed +132=00-N055 EVA Array destroyed, objective complete +133=00-N056 EVA Incoming transmission +134=00-N058 EVA Tratos evacuated, primary objective complete +135=00-N059 EVA Transport destroyed, mission failed +136=01-N320 CABAL Intruders detected +137=01-N322 CABAL Probable objective is rescue of mutant prisoners +138=01-N324 CABAL Kill all prisoners +139=01-N326 CABAL All forces converge +140=00-N068 EVA Ion storm approaching, ETA 5 minutes +141=00-N070 EVA Ion storm abating +142=00-N072 EVA Air power will be ineffective during ion storms +143=00-N074 EVA Dam destroyed, mission complete +144=00-N075 EVA Dam sighted, target confirmed +145=01-N900 CABAL Warning, regulators offline +146=01-N901 CABAL Dam integrity failing +147=00-N084 EVA Enemy sam sites detected +148=00-N086 EVA All sam sites must be destroyed before dropships could be deployed +149=00-N088 EVA Sam sites destroyed, dropships inbound +150=00-N090 +151=00-N092 +152=00-N094 +153=00-N096 EVA Command center destroyed, mission complete +154=00-N098 EVA Warning. inbound tactical nuclear missile detected +155=01-N328 CABAL Main power offline, activating emergency generators +156=01-N330 CABAL Main power restored +157=00-N112 EVA Perimeter deactivated +158=00-N114 EVA Reinforcements inbound +159=00-N128 EVA Bridge repaired +160=00-N130 EVA Train returning to Nod base +161=00-N132 EVA Reinforcement en route +162=00-N134 EVA Capture Nod tech center to recover the crystals +163=00-N136 EVA Train disabled, carryall inbound +164=00-N138 EVA Crystals destroyed, mission failed +165=00-N140 EVA Warning, rogue ion storm forming directly over this sector, pilot, return to base +166=00-N142 EVA Return to base, pilot +167=00-N156 EVA Force detected, enemy units en route +168=00-N158 EVA Mutant lost, mission failed +169=00-N160 EVA Airstrike ready +170=00-N162 EVA Transports inbound +171=00-N166 EVA Supply base destroyed, mission complete +172=00-N168 EVA Mutants en route to power grid +173=00-N180 EVA C4 planted, mission complete +174=00-N182 EVA Ghost stalker terminated, mission failed +175=00-N188 EVA Missile complex destroyed, mission complete +176=00-N190 EVA Tiberium missile inbound +177=00-N192 EVA Ion storm will disable fighters +178=00-N206 EVA Mutants detected, enemy forces en route +179=00-N208 EVA Fighter production facility located and position recorded, dropship en route +180=00-N210 EVA Fighter production facility destroyed, mission complete +181=00-N224 +182=00-N226 +183=00-N228 +184=00-N236 EVA Kodiak under attack +185=00-N238 EVA Storm abating, commence attack on Nod forces +186=00-N240 EVA Kodiak destroyed, mission failed +187=00-N239 EVA Kodiak in critical condition +188=00-N241 EVA Eye of the storm has been entered, equipment usage now at its maximum efficiency +189=00-N243 EVA Tiberium lifeform detected +190=00-N245 EVA Re-entering ion storm, caution is advised +191=00-N247 EVA Clear the zone for MCV dropship deployment +192=00-N248 EVA Philadelphia in range, ICBM launch detected, mission failed +193=00-N249 EVA Tiberium lifeform detected +194=00-N250 EVA Tiberium missile launched, mission failed +195=00-N251 EVA ICBMs destroyed, Philadelphia is out of danger, proceed with tiberium missile destruction +196=00-N252 EVA Nod has deployed several ICBMs which they will use to destroy the Philadelphia once it is in orbit over this sector +197=00-N254 EVA To stop them, you must destroy the other 3 launchers before the Philadelphia is in range +198=00-N255 EVA Civilian city is under attack +199=38-N000 Nod Move it, move it, get back to the base +200=38-N002 Nod Ahh sir, tiberium is lethal to unprotected infantry +201=38-N006 Nod Laser turret, run for it +202=40-N000 BOTH We have been touched by the spirit hand of Kane, and are ready to serve the technology of peace, peace through power +203=41-N000 Nod Stand and identify yourself in the name of Kane +204=41-N002 Nod Sound the alarm, Slav's forces are here +205=41-N004 Nod Base command, this is post TK421, we have got +206=41-N006 Nod We just got word from general Hassan, he is moving up the Cairo base, he wants it, what, hey what you doing +207=43-N000 Nod Beep, I have the codes +208=01-N000 CABAL Harvest the tiberium to the north +209=01-N002 CABAL Destroy all Hassan's elite guard +210=01-N004 CABAL To get production online, build a tiberium refinery +211=01-N006 CABAL Establishing battle controls, please standby +212=01-N008 CABAL Battle controls established +213=01-N010 CABAL Power levels are low, construct more power plants +214=01-N005 CABAL Base perimeter has been breached +215=01-N007 CABAL To build or train, left click on the icons located in the sidebar +216=01-N009 CABAL Tiberium is hazardous to unprotected infantry, caution is advised +217=01-N011 CABAL To repair a structure, left click on the wrench icon in the sidebar and then left click on the structure +218=01-N020 CABAL Capture the TV station to the east +219=01-N022 CABAL To repair a bridge, send an engineer into the bridge repair hut located at the base of the bridge +220=01-N024 CABAL Destroy the remainder of Hassan's guard +221=01-N026 CABAL To capture a building, select an engineer, place the cursor over the intended target and left click +222=01-N027 CABAL To deploy a vehicle, select it, place the cursor over vehicle and left click it +223=01-N032 CABAL Move to an open area and build your base +224=01-N034 CABAL After you locate Hassan's pyramid, use your tick tanks to destroy it +225=01-N036 CABAL When Hassan flees like a dog, capture him +226=01-N038 CABAL Capturing the local radar towers, will allow me to extend our propaganda and expand our divination efforts +227=01-N040 CABAL MCV has arrived to the south east +228=01-N054 CABAL It seems that certain structures in this region attract lightning, creating a kind of safety zone +229=01-N055 CABAL Use them to your advantage +230=01-N064 CABAL GDI base operational +231=01-N066 CABAL Tacitus has been acquired +232=01-N068 CABAL Tiberium lifeform detected +233=01-N070 CABAL Mutants vermin detected +234=01-N072 CABAL GDI dropship detected +235=01-N074 CABAL Bullet train departing +236=01-N076 CABAL Prevent that train from leaving and retrieve the tacitus +237=01-N086 CABAL Protect your engineers, they are your only hope of capturing the GDI base +238=01-N088 CABAL Congratulation on your success +239=01-N090 CABAL I will send an APC now to rendezvous with you at the GDI base +240=01-N100 CABAL Your forces have been detected +241=01-N102 CABAL Prevent GDI's evacuation at all cost +242=01-N114 CABAL Incoming transport detected +243=01-N116 CABAL Mutant lifeform detected onboard +244=01-N128 CABAL Mutants located +245=01-N130 CABAL Tunnel secured, NCV en route +246=01-N132 CABAL Research facility located +247=01-N134 CABAL Research facility destroyed, objective complete +248=01-N136 CABAL Biotoxin convoy approaching +249=01-N144 CABAL Biotoxin tankers located +250=01-N156 CABAL GDI bullet train arriving at outpost +251=01-N158 CABAL GDI bullet train arriving at GDI main prison facility +252=01-N160 CABAL Transport has arrived +253=01-N162 CABAL Transport lost +254=01-N164 CABAL Transport has been detected +255=01-N174 CABAL The creature is the tiberium substance we seek, use it +256=01-N176 CABAL Tiberium missile ready +257=01-N178 CABAL Do not allow the construction yard to be destroyed +258=01-N180 CABAL You must build a tiberium waste facility to store the substance +259=01-N192 CABAL Convoy truck lost +260=01-N194 CABAL Tiberium missile ready +261=01-N196 CABAL Convoy inbound +262=01-N208 CABAL Stealth is key +263=01-N210 CABAL Spy lost, mission failed +264=01-N212 CABAL COM center infiltrated, location detected +265=01-N228 CABAL Convoy sighted +266=01-N230 CABAL McNeil killed, mission failed +267=01-N232 CABAL McNeil captured, mission complete +268=01-N233 CABAL Production facility destroyed +269=01-N227 CABAL If he detects the trap, capture him before he can flee the sector +270=01-N229 CABAL Transport ETA 30 minutes, do not let McNeil escape +271=01-N231 CABAL All toxin soldiers killed, mission failed +272=01-N234 CABAL McNeil escaped, mission failed +273=01-N256 CABAL Orbit 1 complete +274=01-N258 CABAL Orbit 2 complete +275=01-N260 CABAL Orbit 3 complete, mission failed +276=01-N262 CABAL Perimeter deactivated, commence attack +277=01-N264 CABAL ICBM launcher lost, mission failed +278=01-N266 CABAL ICBM launcher under attack +279=01-N268 CABAL Ion cannon firing, resending control codes +280=01-N270 CABAL The ion cannon is ours +281=01-N284 CABAL Spy killed, mission failed +282=01-N286 CABAL Proceed to evac location, transport en route +283=10-N032 GDI A medical facility is located to the east +284=10-N034 GDI A medical facility is located to the west +285=10-N036 GDI We must get Tratos out of that facility, but try to be subtle, if we are detected he is as good as dead +286=10-N038 GDI So much for subtlety +287=10-N040 GDI Tratos, no +288=10-N042 GDI We must get Tratos to the transport +289=10-N044 GDI Our work here is done, we are out of here +290=10-N046 GDI They have seen us, fallback +291=44-N000 GDI Sir, we are here and waiting for your arrival +292=36-N000 GDI That train goes to the power grid we told you of, get us onboard +293=36-N002 GDI What an opportunity, thanks, will enjoy this +294=36-N004 GDI Somethings wrong, we should have been there by now +295=36-N008 GDI We have been betrayed, GDI bots have kidnapped Tratos +296=37-N000 GDI Thanks for your help +297=37-N002 GDI They may be on to us +298=38-N004 Nod We need more men, train them from the hand of Nod +299=38-N008 Nod The traitors are coming, blow the bridge +300=38-N010 Nod Sir, Hassan is escaping, we are moving to intercept him now +301=38-N012 Nod Hassan has been captured, we are heading in now sir +302=38-N014 Nod We got an old stockpile here sir, all very salvageable +303=38-N016 Nod They are pulling back, reinforcements, the mutants have turned on us +304=38-N018 Nod They are everywhere +305=38-N020 Nod Lets get him to the convoy point +306=38-N022 Nod Take point soldier +307=38-N024 Nod Glad to see you free, sir +308=38-N026 Nod The lieutenant is being held at an outpost to the east +309=38-N028 Nod Woaho sir, careful, the ice won't support the weight of multiple vehicles crossing at once +310=39-N000 Nod I am free, now it is time for some payback, for the GDI loving traitor Hassan, I have hidden MCV and some more forces, that I will pledge to your fight +311=47-N000 Nod Don't shoot, don't shoot, I can download GDI's evac locations if you let me live, please let me live, praise Kane +312=00-I020 EVA/CABAL Incoming transmission +313=00-I500 EVA/CABAL Objective complete +314=00-I502 EVA/CABAL Final objective complete +315=00-I504 EVA/CABAL Unable to comply, mobile warfactory deployed Fist of Nod deployed +316=00-N400 EVA Kodiak located +317=00-N402 EVA Tacitus acquired, proceed to beacon for extraction +318=00-N404 EVA Tacitus lost +319=00-N406 EVA Tacitus found +320=00-N408 EVA No one has captured the tacitus, recover it at all cost +321=00-N410 EVA Find and evacuate any civilians in the area +322=00-N412 EVA Maintain all factories until reinforcements arrive +323=00-N414 EVA Escort the civilians to the orca transport for immediate airlift +324=00-N416 EVA Human leader neutralized +325=00-N418 EVA Mutant leader neutralized +326=00-N420 EVA Food center under attack +327=00-N422 EVA Food center destroyed +328=00-N424 EVA Water purifier is under attack +329=00-N426 EVA Water purifier is destroyed +330=00-N428 EVA The riots were incited by 2 members of each side's opposing factions +331=00-N430 EVA Neutralize these leaders to end hostilities +332=00-N432 EVA Riot leader neutralized +333=00-N434 EVA First riot leader neutralized +334=00-N436 EVA Second riot leader neutralized +335=00-N438 EVA Third riot leader neutralized +336=00-N440 EVA Fourth riot leader neutralized +337=00-N442 EVA All riot leaders have been neutralized +338=00-N444 EVA Enemy reinforcements have arrived +339=00-N446 EVA Destroy the 2 bridges in the area +340=00-N448 EVA Penetrate the base and disable CABAL's defenses +341=00-N450 EVA Use an engineer to capture CABAL's core +342=00-N452 EVA Outpost located +343=00-N454 EVA Destroy all CABAL forces +344=00-N456 EVA Return to outpost and evacuate Dr. Boudreau +345=00-N458 EVA GDI base is located due east of your position +346=00-N460 EVA Proceed with caution +347=00-N462 EVA There are several civilian villages in the area, inform them of CABAL's intent +348=00-N464 EVA Village successfully warned +349=00-N466 EVA All villages successfully warned +350=00-N468 EVA CABAL has begun operations, we have lost contact with the GDI base in this sector +351=00-N470 EVA We have lost contact with the GDI base in this region, it is theorized CABAL is to blame +352=00-N472 EVA GDI base in this sector is currently under siege +353=00-N474 EVA 3 small civilian enclaves in this area must be warned +354=00-N478 EVA 2 more small civilian outposts must be warned +355=00-N479 EVA 1 final village must be warned +356=00-N480 EVA The city of Trondheim must be warned +357=00-N482 EVA Destroy CABAL's base and forces +358=00-N484 EVA Infected cyborg introduced into factory +359=00-N486 EVA Deliver the infected cyborg into the communication network +360=00-N488 EVA Destroy the cyborg production plant +361=00-N490 EVA Deliver the infected cyborg into CABAL's base undetected and get it to the communications network +362=00-N492 EVA There is another communications array in CABAL's main base +363=00-N494 EVA Deliver a second modified cyborg to the new array +364=00-N496 EVA Multiple missile launches detected +365=00-N498 EVA Destroy all of CABAL's harvesters, refineries and silos +366=00-N500 EVA Control station captured +367=00-N502 EVA There are 3 control stations in this sector regulating CABAL's defenses +368=00-N504 EVA Capture these stations and retrieve the codes to disable his defenses +369=00-N506 EVA Enemy bridges may allow for unit reinforcement, there destruction would be beneficial in completing this mission +370=00-N508 EVA Locating the technicians may help in disabling the laser fencing +371=00-N510 EVA Probable location within civilian outpost to the north +372=01-N400 CABAL CABAL online +373=01-N402 CABAL Perhaps you should attempt to kill their leader +374=01-N404 CABAL Ghost stalker killed, probability of success now at 10 percent +375=01-N406 CABAL Juggernaut destroyed, probability of success drastically reduced +376=01-N408 CABAL Find the temple and recover the tacitus +377=01-N410 CABAL Cyborg replication error, reset system +378=01-N412 CABAL System reset, normal parameter restored +379=01-N414 CABAL GDI patrol, near +380=01-N416 CABAL Tiberium lifeform detected +381=01-N418 CABAL GDI has detected you +382=01-N420 CABAL Remain hidden from the GDI forces +383=01-N422 CABAL Destroy all civilian structures without being detected +384=01-N424 CABAL Eliminate all GDI and civilian life without being detected +385=01-N426 CABAL Use the toxin soldiers to capture civilians +386=01-N428 CABAL Bait the tiberium lifeforms by luring them with the drugged civilians +387=01-N430 CABAL Leave the tiberium lifeforms to the GDI and civilian occupied area +388=01-N432 CABAL Once the lifeform has devoured the civilians, it will proceed to the settlements +389=01-N434 CABAL Use this location as a staging point for your operation +390=01-N436 CABAL GDI cannot reach you here +391=01-N438 CABAL Outpost located +392=01-N440 CABAL Tacitus found +393=01-N442 CABAL The tacitus is safely in our hands +394=01-N444 CABAL Exterminate the mutant vermin +395=01-N446 CABAL Locate the mutant outpost +396=01-N448 CABAL Find the truck containing the tacitus and return it to the beacon +397=01-N450 CABAL Eliminate all mutant forces +398=01-N452 CABAL Ha, run humans +399=99-N454 CABAL You dare to attack me, how pathetic +400=99-N456 CABAL Cybernetic intelligence will always be superior +401=99-N458 CABAL By the way, missile launch detected +402=99-N460 CABAL Ha ha ha ha ha ha ha ha ha ha ha ha +403=01-N462 CABAL Activating defense protocol firestorm now +404=99-N464 CABAL Activating defense protocol defender now +405=99-N466 CABAL Miscalculation in enemy capability, compensation initiated +406=01-N468 CABAL You amuse me +407=01-N470 CABAL SAM sites destroyed, airpower incoming +408=01-N472 CABAL You have been detected, Tratos is escaping by air transport +409=01-N474 CABAL You have failed, Tratos has escaped +410=01-N476 CABAL The arrays have been destroyed, sensors are now down +411=01-N478 CABAL Capturing 6 powerplants will shut down the firestorm generator +412=19-N100 GDI Sir, I have done the best I can, but the damage is too extensive, looks like the kodiak is a loss +413=19-N102 Nod I have got the evac unit, lets get out of here +414=38-N100 GDI Something crashed near here, lets put on the report +415=38-N102 GDI Sir, we found something, I think it is the tacitus +416=38-N104 GDI We'll fall back to the old airfield and wait out the storm +417=38-N106 Nod We've recovered a piece of the CABAL's core +418=38-N108 Nod I think we have been spotted +419=38-N110 Nod GDI forces are nearby +420=38-N112 Nod We have recovered piece of the core +421=38-N114 Nod Third piece recovered, lets get out of here +422=38-N116 Nod Sir, recon reports of heavy concentration of tiberium poisoning in the area +423=38-N118 Nod We have to find that airfield or we are finished +424=38-N120 Nod Message transmitted, montauk is en route +425=38-N122 Nod This is the montauk, we are standing by for your evac +426=38-N124 Nod We need to create a distraction to clear the GDI base of air support +427=38-N126 Nod I bet if we attacked the civilians, GDI will come to the rescue +428=38-N128 Nod GDI planes are away from the base, now is our chance to get our engineer into the radar, but we better hurry +429=38-N130 Nod Sir, enemy forces just routed, the core is undefended +430=38-N132 Nod Sir, the core isn't here, we have been tricked +431=38-N134 Nod Looks like this was just a remotely operated substation +432=38-N136 Nod Sir, reinforcements can be brought in, if we repair the bridge in this area +433=38-N138 GDI Sir, GDI has requested that we help the civilians first +434=38-N140 GDI Once they are safe, we can concentrate on CABAL's harvesters +435=38-N142 GDI Sir, GDI is sending us additional funding to aiding the civilians +436=38-N144 GDI Forget the civilians, they are dead, concentrate on those harvesters +437=38-N146 GDI This should be easy enough +438=38-N148 GDI Lets get those harvesters +439=38-N150 GDI GDI is uploading the final pieces of the code now, standby +440=38-N152 GDI Code received, firestorm wall coming down in 3 2 1 +441=38-N154 GDI Firestorm is offline +442=38-N156 GDI Code fragment retrieved +443=52-N000 GDI Welcome stranger, surely a higher power has guided your footsteps to this land +444=52-N002 GDI Can I offer you a cool beverage +445=52-N004 GDI What do you think you are doing +446=54-N000 GDI No tacitus piece in here +447=54-N002 GDI Nothing in this we need, you sure we are in the right place +448=54-N004 GDI Got it, lets get out of here +449=54-N006 GDI Nothing in there +450=54-N008 GDI The hieroglyphics on the temple read +451=54-N010 GDI Temple of time +452=54-N012 GDI Temple of thunder +453=54-N014 GDI Temple of tacitus +454=54-N016 GDI Command, this is Valdez, I have got the tacitus +455=54-N018 GDI The blue tiberium is highly explosive, may be +456=54-N020 GDI May be we can blast a path through there +457=55-N000 GDI Help +458=55-N002 GDI Save us +459=55-N004 GDI It is coming right at us +460=55-N006 GDI Get us out, please +461=55-N008 GDI Its after us +462=55-N010 GDI Look out +463=55-N012 GDI What is GDI doing, nothing +464=55-N014 GDI Why are we in this God forsaken place +465=55-N016 GDI Are we gonna let those shiners take our food and water? +466=55-N018 GDI Can't we all just get along +467=55-N020 GDI Riot troops, run +468=55-N022 GDI Thanks for the warning, here is a reward for your help +469=55-N024 GDI Here commander, please take these 2 disruptors to help in your battle +470=55-N026 GDI Yes, yes, I will see to it that everyone is evacuated, please take this MCV and may luck be with you +471=55-N028 Nod I will never turn, uh +472=55-N030 Nod Peace through power +473=55-N032 Nod For the technology of peace +474=55-N034 Nod We got one +475=55-N036 Nod Fish is on the hook +476=55-N038 Nod Here creature creature +477=55-N040 GDI Mayday, mayday, we are currently under siege, can anyone help us? +478=55-N042 GDI Thanks for the help +479=55-N044 Nod We can shut that fencing down for you, just get us into one of the fences power arrays +480=56-N000 GDI Lets show GDI that we are not going to take this +481=56-N002 GDI Kill are the sinners +482=56-N004 GDI Down with GDI +483=56-N006 GDI Women and children to the shelter, thanks for the warning, here take these units +484=56-N008 GDI Understood, we will evacuate the town, take this for your troubles +485=56-N010 GDI Help us +486=56-N012 GDI Save us +487=56-N014 GDI They are coming +488=56-N016 GDI Get us out +489=56-N018 GDI Don't leave us +490=56-N020 GDI Wait +491=57-N100 GDI You picked the wrong place to service, Nod scum +492=57-N102 GDI GDI promised us peace and now Tratos is dead +493=57-N104 GDI GDI lied to us +494=57-N106 GDI Destroy the plants +495=57-N108 GDI Show them this is our land +496=57-N110 GDI Make them remember us +497=57-N112 GDI They poisoned our food and water +498=57-N114 GDI They are trying to kill us +499=57-N116 GDI Understood Blunt, take this harvester for your troubles +500=57-N118 Nod Release the hounds +501=57-N120 Nod Halt and prepare for vehicle inspection +502=57-N122 Nod OK, looks good, head on in +503=57-N124 Nod Its bugged, destroy it now +504=58-N100 GDI Your orders were clear commander, no civilian or mutant causalities +505=58-N102 GDI The riot should end quickly but stay vigilant +506=58-N104 GDI Copy that Valdez, transport is dusting off now, extraction in T minus 2 minutes at your initial drop off point +507=58-N106 GDI We are providing you with the latest development from R&D, it is called juggernaut, it should greatly help your cause +508=58-N108 GDI Get your people to the evac point +509=58-N110 GDI Get your people to the transport +510=58-N112 GDI Valdez, we recommend that you try and take out their leader +511=58-N114 GDI Protect Dr. Boudreau with your life commander +512=58-N116 GDI Our base is under attack, CABAL is moving faster than expected +513=58-N118 GDI What in the world +514=58-N120 GDI I should go warn the civilians in this area +515=58-N122 GDI CABAL is one sick bastard +516=58-N124 GDI O oh, CABAL is taking prisoners, this can't be good +517=58-N126 GDI Arm yourselves, CABAL is conscripting humans into cyborg army +518=58-N128 GDI Be warned, CABAL intends to turn you all into cyborgs +519=58-N130 GDI Attention mutants, CABAL is currently harvesting biological components for his cyborgs, arm yourselves +520=58-N132 GDI You must evacuate the city immediately, CABAL is coming +521=58-N134 GDI Civilians to arms, defend your town +522=58-N136 GDI This must be the base +523=58-N138 GDI What the +524=58-N140 GDI Those poor bastards, CABAL has started harvesting people for cyborgs, I must get back to warn citizens of Trondheim +525=58-N142 GDI People of Trondheim, you must evacuate the city immediately, CABAL is actively capturing civilians to them into cyborgs +526=59-N100 GDI Commander, we can ill afford to lose more civilians to CABAL +527=59-N102 GDI Get in there and protect those civilians +528=59-N104 GDI Well done commander, reinforcements en route +529=61-N000 GDI Mutant abomination, dare you defile sacred ground +530=61-N002 GDI Kill the mutant +531=61-N004 GDI Stop, thief +532=61-N006 GDI Kill the heretics +533=61-N008 GDI Do not let them escape +534=61-N010 GDI What, they killed the leader +535=61-N012 GDI We join you in the here after +536=22-N100 GDI Terminate all biological lifeforms +537=22-N102 GDI The will of CABAL must be enforced +538=22-N104 BOTH Err error +539=22-N106 BOTH System failure +540=22-N108 BOTH Mal malfunction +541=22-N110 GDI Hit him +542=22-N112 GDI Intruder alert +543=22-N114 GDI You are not one of us +544=22-N116 GDI Fire in the hole +545=22-N118 GDI Proceeding to target +546=22-N120 GDI Sequence engaged +547=71-N000 GDI Open fire, open fire +548=71-N100 GDI What, the civilians are shooting at us +549=71-N102 GDI So are the shiners, retreat to the factory +550=71-N104 GDI Command station is been captured, defenses offline +551=71-N106 GDI CABAL has betrayed us, we need reinforcements now +552=71-N108 Nod What was that +553=71-N110 Nod Lets check that out +554=71-N112 Nod Did you hear something +555=71-N114 Nod Yeah, she ain't going anywhere +556=71-N116 Nod I'll get back to base and get help +557=71-N118 Nod Shoot it, naee +558=71-N120 Nod Lets get these civilians out of here now +559=71-N122 Nod We are under attack +560=71-N124 Nod What the hell are those things +561=71-N126 Nod Where are these things coming from +562=71-N128 GDI Nod is uploading the final pieces of the code now, standby +563=71-N130 GDI Code received, firestorm wall coming down in 3 2 1 +564=71-N132 GDI Firestorm is offline +565=71-N134 GDI Code fragment retrieved +566=71-N136 Nod Sir, these laser posts are stronger than normal +567=00-I506 EVA Droppods available +568=62-N000 GDI Welcome traveler, have you come to rejoice in the glory of our leader? +569=62-N002 GDI Join us +570=62-N004 GDI Join me +571=62-N006 GDI Existence is futile +572=62-N008 GDI I am coming to join you +573=62-N010 GDI I am a messenger +574=62-N012 GDI Come to me diff --git a/src/TSMapEditor/Config/UI/Windows/SelectSpeechWindow.ini b/src/TSMapEditor/Config/UI/Windows/SelectSpeechWindow.ini new file mode 100644 index 00000000..a8b1ee90 --- /dev/null +++ b/src/TSMapEditor/Config/UI/Windows/SelectSpeechWindow.ini @@ -0,0 +1,33 @@ +[SelectSpeechWindow] +$Width=600 +$Height=RESOLUTION_HEIGHT - 100 +$CC0=lblDescription:XNALabel +$CC1=tbSearch:EditorSuggestionTextBox +$CC2=btnSelect:EditorButton +$CC3=lbObjectList:EditorListBox + + +[lblDescription] +$X=EMPTY_SPACE_SIDES +$Y=EMPTY_SPACE_TOP +FontIndex=1 +Text=Select Speech: + +[tbSearch] +$X=EMPTY_SPACE_SIDES +$Y=getBottom(lblDescription) + EMPTY_SPACE_TOP +$Width=getWidth(SelectSpeechWindow) - (EMPTY_SPACE_SIDES * 2) +Suggestion=Search Speech... + +[btnSelect] +$Width=100 +$X=(getWidth(SelectSpeechWindow) - getWidth(btnSelect)) / 2 +$Y=getHeight(SelectSpeechWindow) - EMPTY_SPACE_BOTTOM - getHeight(btnSelect) +Text=Select + +[lbObjectList] +$X=EMPTY_SPACE_SIDES +$Y=getBottom(tbSearch) + VERTICAL_SPACING +$Width=getWidth(tbSearch) +$Height=getY(btnSelect) - getY(lbObjectList) - EMPTY_SPACE_TOP + diff --git a/src/TSMapEditor/Constants.cs b/src/TSMapEditor/Constants.cs index 3d59d9c6..0eb264a3 100644 --- a/src/TSMapEditor/Constants.cs +++ b/src/TSMapEditor/Constants.cs @@ -5,7 +5,7 @@ namespace TSMapEditor { public static class Constants { - public const string ReleaseVersion = "1.0.1"; + public const string ReleaseVersion = "1.0.2"; public static int CellSizeX = 48; public static int CellSizeY = 24; diff --git a/src/TSMapEditor/Models/EditorConfig.cs b/src/TSMapEditor/Models/EditorConfig.cs index 16537866..16e53a03 100644 --- a/src/TSMapEditor/Models/EditorConfig.cs +++ b/src/TSMapEditor/Models/EditorConfig.cs @@ -29,6 +29,7 @@ public EditorConfig() public List Bridges { get; } = new List(); public List ConnectedOverlays { get; } = new List(); public List TeamTypeFlags { get; } = new List(); + public Dictionary Speeches { get; } = new Dictionary(); private static readonly Dictionary TiberiumDefaults = new() { @@ -58,6 +59,7 @@ public void EarlyInit() ReadTriggerActionTypes(); ReadTheaters(); ReadTeamTypeFlags(); + ReadSpeeches(); } public void RulesDependentInit(Rules rules) @@ -370,5 +372,29 @@ private void ReadTeamTypeFlags() TeamTypeFlags.Add(teamTypeFlag); } } + + private void ReadSpeeches() + { + Speeches.Clear(); + + var iniFile = new IniFile(Environment.CurrentDirectory + "/Config/Speeches.ini"); + const string sectionName = "Speeches"; + + var keys = iniFile.GetSectionKeys(sectionName); + if (keys == null) + return; + + foreach (var key in keys) + { + int id = Conversions.IntFromString(key, -1); + if (id == -1) + { + Logger.Log("Invalid speech entry " + key); + continue; + } + + Speeches[id] = iniFile.GetStringValue(sectionName, key, string.Empty); + } + } } } diff --git a/src/TSMapEditor/TSMapEditor.csproj b/src/TSMapEditor/TSMapEditor.csproj index 141734b6..ba1878eb 100644 --- a/src/TSMapEditor/TSMapEditor.csproj +++ b/src/TSMapEditor/TSMapEditor.csproj @@ -95,6 +95,9 @@ PreserveNewest + + PreserveNewest + PreserveNewest @@ -215,6 +218,9 @@ PreserveNewest + + PreserveNewest + PreserveNewest diff --git a/src/TSMapEditor/UI/Windows/SelectSpeechWindow.cs b/src/TSMapEditor/UI/Windows/SelectSpeechWindow.cs new file mode 100644 index 00000000..64abdc02 --- /dev/null +++ b/src/TSMapEditor/UI/Windows/SelectSpeechWindow.cs @@ -0,0 +1,46 @@ +using Rampastring.XNAUI.XNAControls; +using Rampastring.XNAUI; +using System; +using TSMapEditor.Models; + +namespace TSMapEditor.UI.Windows +{ + public class SelectSpeechWindow : SelectObjectWindow + { + public SelectSpeechWindow(WindowManager windowManager, Map map) : base(windowManager) + { + this.map = map; + } + + private readonly Map map; + + public override void Initialize() + { + Name = nameof(SelectSpeechWindow); + base.Initialize(); + } + + protected override void LbObjectList_SelectedIndexChanged(object sender, EventArgs e) + { + if (lbObjectList.SelectedItem == null || lbObjectList.SelectedItem.Tag == null) + { + SelectedObject = -1; + return; + } + + SelectedObject = (int)lbObjectList.SelectedItem.Tag; + } + + protected override void ListObjects() + { + lbObjectList.Clear(); + + foreach (var kvp in map.EditorConfig.Speeches) + { + lbObjectList.AddItem(new XNAListBoxItem() { Text = $"{kvp.Key} {kvp.Value}", Tag = kvp.Key }); + if (kvp.Key == SelectedObject) + lbObjectList.SelectedIndex = lbObjectList.Items.Count - 1; + } + } + } +} diff --git a/src/TSMapEditor/UI/Windows/TriggersWindow.cs b/src/TSMapEditor/UI/Windows/TriggersWindow.cs index 19ddbb11..221e38b4 100644 --- a/src/TSMapEditor/UI/Windows/TriggersWindow.cs +++ b/src/TSMapEditor/UI/Windows/TriggersWindow.cs @@ -88,6 +88,7 @@ public TriggersWindow(WindowManager windowManager, Map map, EditorState editorSt private SelectTechnoTypeWindow selectTechnoTypeWindow; private SelectTagWindow selectTagWindow; private SelectStringWindow selectStringWindow; + private SelectSpeechWindow selectSpeechWindow; private XNAContextMenu actionContextMenu; private XNAContextMenu eventContextMenu; @@ -263,6 +264,10 @@ public override void Initialize() var stringDarkeningPanel = DarkeningPanel.InitializeAndAddToParentControlWithChild(WindowManager, Parent, selectStringWindow); stringDarkeningPanel.Hidden += StringDarkeningPanel_Hidden; + selectSpeechWindow = new SelectSpeechWindow(WindowManager, map); + var speechDarkeningPanel = DarkeningPanel.InitializeAndAddToParentControlWithChild(WindowManager, Parent, selectSpeechWindow); + speechDarkeningPanel.Hidden += SpeechDarkeningPanel_Hidden; + eventContextMenu = new XNAContextMenu(WindowManager); eventContextMenu.Name = nameof(eventContextMenu); eventContextMenu.Width = lbEvents.Width; @@ -933,6 +938,10 @@ private void BtnActionParameterValuePreset_LeftClick(object sender, EventArgs e) map.Rules.SuperWeaponTypes.ForEach(sw => ctxActionParameterPresetValues.AddItem(sw.GetDisplayString())); ctxActionParameterPresetValues.Open(GetCursorPoint()); break; + case TriggerParamType.Speech: + selectSpeechWindow.IsForEvent = false; + selectSpeechWindow.Open(Conversions.IntFromString(triggerAction.Parameters[paramIndex], -1)); + break; default: break; } @@ -1030,6 +1039,14 @@ private void StringDarkeningPanel_Hidden(object sender, EventArgs e) AssignParamValue(selectStringWindow.IsForEvent, selectStringWindow.SelectedObject.ID); } + private void SpeechDarkeningPanel_Hidden(object sender, EventArgs e) + { + if (selectSpeechWindow.SelectedObject < 0) + return; + + AssignParamValue(selectSpeechWindow.IsForEvent, selectSpeechWindow.SelectedObject); + } + private void AssignParamValue(bool isForEvent, int paramValue) { if (isForEvent) @@ -1919,6 +1936,14 @@ private string GetParamValueText(string paramValue, TriggerParamType paramType, return intValue + " - nonexistent super weapon"; return intValue + " " + map.Rules.SuperWeaponTypes[intValue].GetDisplayStringWithoutIndex(); + case TriggerParamType.Speech: + if (!intParseSuccess) + return paramValue; + + if (!map.EditorConfig.Speeches.ContainsKey(intValue)) + return intValue + " - unknown speech"; + + return intValue + " " + map.EditorConfig.Speeches[intValue]; case TriggerParamType.Float: if (!intParseSuccess) return paramValue;