mirror of
https://github.com/jmarshall23/CnC_Remastered_Collection.git
synced 2026-08-12 08:00:55 +02:00
678d784004
Added ability to create objects out of thin air, and force factories to produce units. Added ability to issue movement commands to units. Updated object cache system to use an incremental UID for retrieval / passing ID back to the script, as ID collisions were occuring.
393 lines
13 KiB
Plaintext
393 lines
13 KiB
Plaintext
-- *=======================================================*
|
|
-- * *
|
|
-- * Mapscript Global Helper Header *
|
|
-- * *
|
|
-- *=======================================================*
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Houses (players) *
|
|
-- * *
|
|
-- *********************************************************
|
|
Houses={
|
|
SPAIN=0, -- YELLOW/GOLD
|
|
GREECE=1, -- BLUE-GREY
|
|
USSR=2, -- RED
|
|
ENGLAND=3, -- GREEN
|
|
UKRAINE=4, -- ORANGE
|
|
GERMANY=5, -- KHAKI/LIGHT BROWN
|
|
FRANCE=6, -- AQUA
|
|
TURKEY=7, -- RED-OCHRE
|
|
GOODGUY=8, -- BLUE-GREY
|
|
BADGUY=9, -- RED
|
|
NEUTRAL=10, -- YELLOW/GOLD
|
|
SPECIAL=11, -- YELLOW/GOLD
|
|
MULTI1=12, -- YELLOW/GOLD
|
|
MULTI2=13, -- BLUE-GREY
|
|
MULTI3=14, -- RED
|
|
MULTI4=15, -- GREEN
|
|
MULTI5=16, -- ORANGE
|
|
MULTI6=17, -- KHAKI/LIGHT BROWN
|
|
MULTI7=18, -- AQUA
|
|
MULTI8=19 -- RED-OCHRE
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Buildings *
|
|
-- * *
|
|
-- *********************************************************
|
|
|
|
BuildingTypes={
|
|
ATEK=0, -- Allied Technology Centre
|
|
IRON=1, -- Iron Curtain
|
|
WEAP=2, -- Weapons Factory
|
|
PDOX=3, -- Chronosphere
|
|
PBOX=4, -- Pillbox
|
|
HBOX=5, -- Camouflaged Pillbox
|
|
DOME=6, -- Radar Dome
|
|
GAP =7, -- Gap Generator
|
|
GUN =8, -- Gun Turret
|
|
AGUN=9, -- Anti-Aircraft Gun
|
|
FTUR=10, -- Flame Turret
|
|
FACT=11, -- Construction Yard
|
|
PROC=12, -- Ore Refinery
|
|
SILO=13, -- Ore Silo
|
|
HPAD=14, -- Helicopter Pad
|
|
SAM =15, -- SAM Site
|
|
AFLD=16, -- Airfield
|
|
POWR=17, -- Power Plant
|
|
APWR=18, -- Advanced Power Plant
|
|
STEK=19, -- Soviet Technology Centre
|
|
HOSP=20, -- Hospital
|
|
BARR=21, -- Barracks (Allied)
|
|
TENT=22, -- Barracks (Soviet)
|
|
KENN=23, -- Dog Kennel
|
|
FIX =24, -- Service Depot
|
|
BIO =25, -- Bio-Research Laboratory
|
|
MISS=26, -- Technology Centre/Prison
|
|
SYRD=27, -- Ship Yard
|
|
SPEN=28, -- Sub Pen
|
|
MSLO=29, -- Missile Silo
|
|
FCOM=30, -- Forward Command Post
|
|
TSLA=31, -- Tesla Coil
|
|
WEAF=32, -- Fake Weapons Factory
|
|
FACF=33, -- Fake Construction Yard
|
|
SYRF=34, -- Fake Ship Yard
|
|
SPEF=35, -- Fake Sub Pen
|
|
DOMF=36, -- Fake Radar Dome
|
|
MINV=43, -- Anti-vehicle mine
|
|
MINP=44, -- Anti-personnel mine
|
|
|
|
-- Counterstrike
|
|
|
|
QUEE=84, -- Queen ant structure
|
|
LAR1=85, -- Ant - single ant larva
|
|
LAR2=86 -- Ant - two ant larvae
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Infantry *
|
|
-- * *
|
|
-- *********************************************************
|
|
|
|
InfantryTypes={
|
|
E1=0, -- Rifle Infantry
|
|
E2=1, -- Grenadier
|
|
E3=2, -- Rocket Soldier
|
|
E4=3, -- Flamethrower
|
|
E6=4, -- Engineer
|
|
E7=5, -- Tanya
|
|
SPY=6, -- Spy
|
|
THF=7, -- Thief
|
|
MEDI=8, -- Field Medic
|
|
GNRL=9, -- General
|
|
DOG=10, -- Attack Dog
|
|
C1=11, -- Joe
|
|
C2=12, -- Barry
|
|
C3=13, -- Shelly
|
|
C4=14, -- Maria
|
|
C5=15, -- Karen
|
|
C6=16, -- Steve
|
|
C7=17, -- Phil
|
|
C8=18, -- Dwight
|
|
C9=19, -- Erik
|
|
C10=20, -- Scientist
|
|
EINSTEIN=21, -- Prof. Einstein
|
|
DELPHI=22, -- Special 1
|
|
CHAN=23 -- Special 2
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Vehicle *
|
|
-- * *
|
|
-- *********************************************************
|
|
|
|
VehicleTypes={
|
|
_4TNK=0, -- Mammoth Tank
|
|
_3TNK=1, -- Heavy Tank
|
|
_2TNK=2, -- Medium Tank
|
|
_1TNK=3, -- Light Tank
|
|
APC=4, -- Armoured Personnel Carrier
|
|
MNLY=5, -- Mine Layer
|
|
JEEP=6, -- Ranger
|
|
HARV=7, -- Ore Truck
|
|
ARTY=8, -- Artillery
|
|
MRJ=9, -- Mobile Radar Jammer
|
|
MGG=10, -- Mobile Gap Generator
|
|
MCV=11, -- Mobile Construction Vehicle
|
|
_2VRL=12, -- V2 Rocket Launcher
|
|
TRUK=13, -- Convoy Truck
|
|
|
|
-- Counterstrike only:
|
|
ANT1=14, -- First ant type
|
|
ANT2=15, -- Second ant type
|
|
ANT3=16 -- Third ant type
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Aircraft *
|
|
-- * *
|
|
-- *********************************************************
|
|
|
|
AircraftTypes={
|
|
TRAN=0, -- Chinook Helicopter
|
|
BADR=1, -- Badger Bomber
|
|
U2=2, -- Spy Plane
|
|
MIG=3, -- MIG Attack Plane
|
|
YAK=4, -- Yak Attack Plane
|
|
HELI=5, -- Longbow Helicopter
|
|
HIND=6 -- Hind Helicopter
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Vessels *
|
|
-- * *
|
|
-- *********************************************************
|
|
|
|
VesselTypes={
|
|
SS=0, -- Submarine
|
|
DD=1, -- Destroyer
|
|
CA=2, -- Cruiser
|
|
LST=3, -- Land Sea Tank (transport)
|
|
PT=4 -- Gun Boat
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Armor Types *
|
|
-- * *
|
|
-- *********************************************************
|
|
ArmorTypes={
|
|
NONE=0,
|
|
WOOD=1,
|
|
ALUMINUM=2,
|
|
STEEL=3,
|
|
CONCRETE=4
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Weapon Types *
|
|
-- * *
|
|
-- *********************************************************
|
|
WeaponTypes={
|
|
NONE=-1,
|
|
COLT45=0,
|
|
ACK_ACK=1,
|
|
VULCAN=2,
|
|
MAVERICK=3,
|
|
CAMERA=4,
|
|
FIREBALL=5,
|
|
RIFLE=6,
|
|
CHAIN_GUN=7,
|
|
PISTOL=8,
|
|
M16=9,
|
|
DRAGON=10,
|
|
HELLFIRE=11,
|
|
GRENADE=12,
|
|
_75MM=13,
|
|
_90MM=14,
|
|
_105MM=15,
|
|
_120MM=16,
|
|
TURRET_GUN=17,
|
|
MAMMOTH_TUSK=18,
|
|
_155MM=19,
|
|
M60MG=20,
|
|
NAPALM=21,
|
|
TESLA_ZAP=22,
|
|
NIKE=23,
|
|
_8INCH=24,
|
|
STINGER=25,
|
|
TORPEDO=26,
|
|
_2INCH=27,
|
|
DEPTH_CHARGE=28,
|
|
PARA_BOMB=29,
|
|
DOGJAW=30,
|
|
HEAL=31,
|
|
SCUD=32,
|
|
FLAMER=33,
|
|
REDEYE=34
|
|
}
|
|
|
|
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Special weapons *
|
|
-- * *
|
|
-- *********************************************************
|
|
SpecialWeapons={
|
|
Sonar=0,
|
|
Nuke=1,
|
|
Chrono=2,
|
|
Parabomb=3,
|
|
Paratroops=4,
|
|
SpyPlane=5,
|
|
IronCurtain=6,
|
|
GPS=7
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Target types (for use with DesignatePreferredTarget) *
|
|
-- * *
|
|
-- *********************************************************
|
|
TargetTypes={
|
|
Anything=1,
|
|
Buildings=2,
|
|
Harvesters=3,
|
|
Infantry=4,
|
|
Vehicles=5,
|
|
Ships=6,
|
|
Factories=7,
|
|
BaseDefences=8,
|
|
BaseThreats=9,
|
|
Power=10,
|
|
FakeBuildings=11
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Trigger persistance *
|
|
-- * *
|
|
-- *********************************************************
|
|
PersistenceTypes={
|
|
Volatile=0,
|
|
SemiPersistent=1,
|
|
Persistent=2
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Obejct Attributes *
|
|
-- * *
|
|
-- *********************************************************
|
|
ObjectAttributes = {
|
|
Type=0,
|
|
Strength=1, -- Object attribute
|
|
MaxStrength=2, -- Definition attribute
|
|
Cost=3, -- Definition attribute
|
|
SightRange=4, -- Definition attribute
|
|
TechLevel=5, -- Definition attribute
|
|
Armor=6,
|
|
PrimaryWeapon=7,
|
|
SecondaryWeapon=8,
|
|
Speed=9,
|
|
MaxSpeed=10,
|
|
MaxAmmo=11,
|
|
RotationSpeed=12,
|
|
IsCrushable=13,
|
|
IsStealthy=14,
|
|
IsSelectable=15,
|
|
IsLegalTarget=16,
|
|
IsRepairable=17,
|
|
IsSelfHealing=18,
|
|
Explodes=19,
|
|
HasCrew=20,
|
|
MaxPassengers=21,
|
|
IsRepairing=22,
|
|
|
|
-- Building Specific
|
|
Capacity=23,
|
|
Power=24,
|
|
Sellable=25,
|
|
|
|
-- Unit Specific
|
|
IsCrateGoodie=26,
|
|
IsCrusher=27,
|
|
IsHarvest=28,
|
|
IsRadarEquipped=29,
|
|
IsJammer=30,
|
|
IsGapper=31,
|
|
|
|
-- Infantry Specific
|
|
IsFemale=32,
|
|
Capture=33,
|
|
IsFraidyCat=34,
|
|
IsCivilian=35,
|
|
IsBomber=36,
|
|
IsDog=37
|
|
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * House Attributes *
|
|
-- * *
|
|
-- *********************************************************
|
|
HouseAttributes = {
|
|
IQ = 0,
|
|
TechLevel =1,
|
|
IsHuman=2,
|
|
FirepowerBias=3,
|
|
GroundspeedBias=4,
|
|
ArmorBias=5,
|
|
ROFBias=6,
|
|
CostBias=7,
|
|
RepairDelay=8,
|
|
BuildDelay=9,
|
|
Started=10,
|
|
Alerted=11,
|
|
BaseBuilding=12,
|
|
Discovered=13,
|
|
Capacity=14,
|
|
Tiberium=15,
|
|
Credits=16,
|
|
AlertTimer=17,
|
|
RepairTimer=18,
|
|
Points=19,
|
|
DestroyedBuildings=20,
|
|
DestroyedVehicles=21,
|
|
DestroyedInfantry=22,
|
|
DestroyedAircraft=23,
|
|
DestroyedVessels=24,
|
|
CapturedBuildings=25,
|
|
Crates=26,
|
|
BuildingFactories=27,
|
|
VehicleFactories=28,
|
|
InfantryFactories=29,
|
|
AircraftFactories=30,
|
|
VesselFactories=31,
|
|
|
|
Power=32,
|
|
Drain=33,
|
|
LastAttacker=34
|
|
}
|
|
|
|
-- *********************************************************
|
|
-- * *
|
|
-- * Fear Type Attribute Values *
|
|
-- * *
|
|
-- *********************************************************
|
|
FearTypes={
|
|
None=0, -- No fear at all (default state).
|
|
Anxious=10, -- Something makes them scared.
|
|
Scared=100, -- Scared enough to take cover.
|
|
Panic=200, -- Run away! Run away!
|
|
Maximum=255 -- Scared to death.
|
|
} |