国家的崛起之爱国战争三项属性修改器

scenario general_powers ()

{

int player = 1;

int cur_time = time_sec();

static int counter = 0;

run_once {

set_timer("pop", 5);

for (i = 0; i < num_players(); i++) {

//if (find_nation(i+1) == "Chinese") {

if (get_leader_name(i+1) == "king") {

// if (find_nation(i+1) == "Americans") {

int buildin;

int Rx;

int Ry;

buildin = find_unit(i+1, "");

Rx = object_position_x(i+1, buildin);

Ry = object_position_y(i+1, buildin);

create_unit_upgrade(i+1, Rx, Ry, "napoleon", 1);

create_unit_upgrade(i+1, Rx, Ry, "alexander", 1);

// create_unit_upgrade(i+1, Rx, Ry, "antipater", 1);

// create_unit_upgrade(i+1, Rx, Ry, "ptolemy", 1);

// create_unit_upgrade(i+1, Rx, Ry, "darius", 1);

// create_unit_upgrade(i+1, Rx, Ry, "memnon", 1);

// create_unit_upgrade(i+1, Rx, Ry, "spitamenes", 1);

create_unit_upgrade(i+1, Rx, Ry, "porus", 1);

// create_unit_upgrade(i+1, Rx, Ry, "schwarzenberg", 1);

// create_unit_upgrade(i+1, Rx, Ry, "chandragupta maurya", 1);

// create_unit_upgrade(i+1, Rx, Ry, "Humvee", 5);

give_good(i+1, "Food", 5000);

give_good(i+1, "Timber", 5000);

give_good(i+1, "Metal", 5000);

give_good(i+1, "Wealth", 5000);

give_good(i+1, "Oil", 5000);

give_good(i+1, "Knowledge", 5000);

set_unit_scale(i+1, find_unit(i+1, "napoleon"), 1.1);

set_unit_scale(i+1, find_unit(i+1, "alexander"), 1.1);

// set_preq("Assault Marines", "Classical Age", "Global Prosperity");

// set_preq("Assault Infantry", "Classical Age", "Global Prosperity");

// set_preq("Commando", "Classical Age", "Global Prosperity");

// set_preq("Anti-Tank Missile", "Classical Age", "Global Prosperity");

// set_preq("Advanced Machine Gun", "Classical Age", "Global Prosperity");

// set_preq("Rocket Artillery", "Classical Age", "Global Prosperity");

// set_preq("Main Battle Tank", "Classical Age", "Global Prosperity");

// set_preq("Armored Cavalry", "Classical Age", "Global Prosperity");

// set_preq("Anti-Aircraft Missile", "Classical Age", "Global Prosperity");

// set_preq("Attack Helicopter", "Classical Age", "Global Prosperity");

// set_preq("Advanced Fighter", "Classical Age", "Global Prosperity");

// set_preq("Jet Fighter Bomber", "Classical Age","Global Prosperity");

// set_preq("Aircraft Carrier", "Classical Age","Global Prosperity");

// set_preq("Missile Cruiser", "Classical Age", "Global Prosperity");

// set_preq("Advanced Battleship", "Classical Age", "Global Prosperity");

// set_preq("Attack Submarine", "Classical Age", "Global Prosperity");

set_preq("Cruise Missile", "Classical Age", "Global Prosperity");

// set_preq("Stealth Bomber", "Classical Age", "Global Prosperity");

// set_preq("Elite Special Forces", "Classical Age", "Global Prosperity");

set_preq("Sas", "Classical Age", "Global Prosperity");

set_preq("Nuclear Missile Sub", "Classical Age", "Global Prosperity");

set_preq("Missile Silo", "Classical Age", "Global Prosperity");

set_preq("Humvee", "Classical Age","Global Prosperity");

// show_all_map_enable(i+1);

// gain_tech(i+1, "Classical Age");

// gain_tech(i+1, "Medieval Age");

// gain_tech(i+1, "Gunpowder Age");

// gain_tech(i+1, "Enlightenment Age");

// gain_tech(i+1, "Industrial Age");

// gain_tech(i+1, "Modern Age");

// gain_tech(i+1, "Information Age");

gain_tech(i+1, "Missile Shield");

gain_tech(i+1, "World Government");

gain_tech(i+1, "Global Prosperity");

gain_tech(i+1, "Artificial Intelligence");

gain_upgrade(i+1, "Commando");

// gain_upgrade(i+1, "Assault Infantry");

// gain_upgrade(i+1, "Assault Marines");

// gain_upgrade(i+1, "Anti-Tank Missile");

// gain_upgrade(i+1, "Advanced Machine Gun");

gain_upgrade(i+1, "Elite Special Forces");

// gain_upgrade(i+1, "Rocket Artillery");

gain_upgrade(i+1, "Scout");

gain_upgrade(i+1, "Explorer");

disable_type_by_tribe("Elite Special Forces",find_nation(i+1));

disable_type_by_tribe("Commando",find_nation(i+1));

disable_type_by_tribe("Scout",find_nation(i+1));

disable_type_by_tribe("Explorer",find_nation(i+1));

// gain_upgrade(i+1, "Main Battle Tank");

// gain_upgrade(i+1, "Armored Cavalry");

// gain_upgrade(i+1, "Anti-Aircraft Missile");

// gain_upgrade(i+1, "Advanced Fighter");

// gain_upgrade(i+1, "Attack Helicopter");

// gain_upgrade(i+1, "Stealth Bomber");

gain_upgrade(i+1, "Cruise Missile");

// gain_upgrade(i+1, "Missile Cruiser");

gain_upgrade(i+1, "Attack Submarine");

// gain_upgrade(i+1, "Advanced Battleship");

// gain_upgrade(i+1, "Jet Fighter Bomber");

// gain_upgrade(i+1, "Aircraft Carrier");

disable_type_by_tribe("Attack Submarine",find_nation(i+1));

enable_type_by_tribe("Nuclear Missile Sub",find_nation(i+1), "Dock", 0, 3);

gain_upgrade(i+1, "Nuclear Missile Sub");

enable_type_by_tribe("Humvee",find_nation(i+1), "Stable", 0, 4);

enable_type_by_tribe("Sas",find_nation(i+1), "Barracks", 0, 4);

gain_upgrade(i+1, "Humvee");

gain_upgrade(i+1, "Sas");

// set_object_type_armor("Attack Helicopter", 30);

// set_object_type_max_health("Attack Helicopter", 500);

// set_type_line_of_sight("Attack Helicopter", 30);

// set_object_type_attack("Attack Helicopter", 3500);

// set_object_type_max_range("Attack Helicopter", 21);

set_object_type_armor("Nuclear Missile Sub", 80);

set_object_type_max_health("Nuclear Missile Sub", 500);

set_type_line_of_sight("Nuclear Missile Sub", 30);

set_object_type_attack("Nuclear Missile Sub", 3500);

set_object_type_max_range("Nuclear Missile Sub", 26);

set_preq("Airbase", "Classical Age","Global Prosperity");

set_preq("Biplane", "Classical Age","Global Prosperity");

set_preq("Fighter", "Classical Age","Global Prosperity");

set_preq("Jet Fighter", "Classical Age","Global Prosperity");

//set_preq("Advanced Fighter", "Classical Age","Global Prosperity");

set_preq("Eagle Fighter", "Classical Age","Global Prosperity");

gain_upgrade(i+1, "Airbase");

gain_upgrade(i+1, "Biplane");

gain_upgrade(i+1, "Fighter");

gain_upgrade(i+1, "Jet Fighter");

gain_upgrade(i+1, "Advanced Fighter");

//gain_upgrade(i+1, "Eagle Fighter");

//disable_type_by_tribe("Biplane",find_nation(i+1));

//disable_type_by_tribe("Fighter",find_nation(i+1));

disable_type_by_tribe("Jet Fighter",find_nation(i+1));

//disable_type_by_tribe("Advanced Fighter",find_nation(i+1));

enable_type_by_tribe("Eagle Fighter",find_nation(i+1), "Airbase", 0, 0);

set_object_type_attack("Eagle Fighter", 2500);

//set_preq("Jet Fighter Bomber", "Classical Age","Global Prosperity");

//gain_upgrade(i+1, "Fighter Bomber");

//gain_upgrade(i+1, "Jet Fighter Bomber");

//enable_type_by_tribe("Jet Fighter Bomber",find_nation(i+1), "Airbase", 0, 3);

//set_object_type_attack("Jet Fighter Bomber", 2500);

}

else{

disable_type_by_tribe("Cruise Missile",find_nation(i+1));

disable_type_by_tribe("Humvee",find_nation(i+1));

disable_type_by_tribe("Nuclear Missile Sub",find_nation(i+1));

disable_tech(i+1, "Missile Shield");

}

}

print_game_msg("Hallo Friend,Play Happy.----王炀");

}

// set_object_type_armor("Spy", 30)

static int alexander = 0;

static int napoleon = 0;

static int parmenio = 0;

static int antipater = 0;

static int ptolemy = 0;

static int darius = 0;

static int memnon = 0;

static int spitamenes = 0;

static int maurya = 0;

static int porus = 0;

static int fouche = 0;

static int schwarzenberg = 0;

static int paoli = 0;

int o = -1;

if (timer_expired("pop")) {

set_timer("pop", 2);

string bubble;

//if (num_objects_selected(player) == 1) {

if ((alexander > 0 && alexander < 4) || (alexander == 0 && object_type_selected(player, "Alexander"))) {

switch (alexander % 4) {

case 0 :

bubble = $S("+50 attack!");

break;

case 1 :

bubble = $S("+50 Heavy Infantry attack!");

break;

case 2 :

bubble = $S("Double craft!");

break;

case 3 :

bubble = $S("50% faster Forced March!");

break;

}

o = find_unit(1, "Alexander");

alexander++;

} else if ((napoleon > 0 && napoleon < 4) || (napoleon == 0 && object_type_selected(player, "napoleon"))) {

switch (napoleon % 4) {

case 0 :

bubble = $S("+3 attack to siege!");

break;

case 1 :

bubble = $S("+1 range to siege!");

break;

case 2 :

bubble = $S("Double craft!");

break;

case 3 :

bubble = $S("50% faster Forced March!");

break;

}

o = find_unit(1, "Napoleon");

napoleon++;

} else if ((parmenio > 0 && parmenio < 4) || (parmenio == 0 && object_type_selected(player, "parmenio"))) {

switch (parmenio % 4) {

case 0 :

bubble = $S("+1 Heavy Cavalry attack!");

break;

case 1 :

bubble = $S("Bigger radius!");

break;

case 2 :

bubble = $S("3x longer ambush!");

break;

case 3 :

bubble = $S("Starts with 5 Companions!");

break;

}

o = find_unit(1, "parmenio");

parmenio++;

} else if ((antipater > 0 && antipater < 5) || (antipater == 0 && object_type_selected(player, "antipater"))) {

switch (antipater % 5) {

case 0 :

bubble = $S("Heals nearby units!");

break;

case 1 :

bubble = $S("Entrenched units take 80% damage!");

break;

case 2 :

bubble = $S("Can Entrench outside home territory!");

break;

case 3 :

bubble = $S("2x entrenchment speed");

break;

case 4 :

bubble = $S("+3 attack to buildings when garrisoned!");

break;

}

o = find_unit(1, "antipater");

antipater++;

} else if ((ptolemy > 0 && ptolemy < 4) || (ptolemy == 0 && object_type_selected(player, "ptolemy"))) {

switch (ptolemy % 4) {

case 0 :

bubble = $S("+1 range!");

break;

case 1 :

bubble = $S("+1 Line-of-Sight for ranged units!");

break;

case 2 :

bubble = $S("+1 siege attack!");

break;

case 3 :

bubble = $S("+1 armor!");

break;

}

o = find_unit(1, "ptolemy");

ptolemy++;

} else if ((darius > 0 && darius < 3) || (darius == 0 && object_type_selected(player, "darius"))) {

switch (darius % 3) {

case 0 :

bubble = $S("+1 defense!");

break;

case 1 :

bubble = $S("Prevents attrition!");

break;

case 2 :

bubble = $S("Enables the War Chariot!");

break;

}

o = find_unit(1, "darius");

darius++;

} else if ((memnon > 0 && memnon < 4) || (memnon == 0 && object_type_selected(player, "memnon"))) {

switch (memnon % 4) {

case 0 :

bubble = $S("Always cloaked!");

break;

case 1 :

bubble = $S("2x craft regeneration!");

break;

case 2 :

bubble = $S("Increases Greek Mercenaries' attack!");

break;

case 3 :

bubble = $S("Increases Greek Mercenaries' armor!");

break;

}

o = find_unit(1, "memnon");

memnon++;

} else if ((spitamenes > 0 && spitamenes < 4) || (spitamenes == 0 && object_type_selected(player, "spitamenes"))) {

switch (spitamenes % 4) {

case 0 :

bubble = $S("+1 Horse Archer attack!");

break;

case 1 :

bubble = $S("20% faster Cavalry!");

break;

case 2 :

bubble = $S("Increases building plunder!");

break;

case 3 :

bubble = $S("Gains plunder from enemy units!");

break;

}

o = find_unit(1, "spitamenes");

spitamenes++;

} else if ((maurya > 0 && maurya < 2) || (maurya == 0 && object_type_selected(player, "Chandragupta Maurya"))) {

switch (maurya % 2) {

case 0 :

bubble = $S("2x craft!");

break;

case 1 :

bubble = $S("Prevents attrition!");

break;

}

o = find_unit(1, "chandragupta maurya");

maurya++;

} else if ((porus > 0 && porus < 4) || (porus == 0 && object_type_selected(player, "porus"))) {

switch (porus % 3) {

case 0 :

bubble = $S("Detects cloaked units!");

break;

case 1 :

bubble = $S("Double hit points");

break;

case 2 :

bubble = $S("Creates 2x decoys");

break;

case 3 :

bubble = $S("20% faster Elephants!");

break;

}

o = find_unit(1, "porus");

porus++;

} else if ((fouche > 0 && fouche < 2) || (fouche == 0 && object_type_selected(player, "fouche"))) {

switch (fouche % 2) {

case 0 :

bubble = $S("Reveals all enemies!");

break;

case 1 :

bubble = $S("Triple craft!");

break;

}

o = find_unit(1, "fouche");

fouche++;

} else if ((paoli > 0 && paoli < 3) || (paoli == 0 && object_type_selected(player, "paoli"))) {

switch (paoli % 3) {

case 0 :

bubble = $S("Instant snipe!");

break;

case 1 :

bubble = $S("Instant sabotage!");

break;

case 2 :

bubble = $S("Double craft!");

break;

}

o = find_unit(1, "paoli");

paoli++;

} else if ((schwarzenberg > 0 && schwarzenberg < 3) || (schwarzenberg == 0 && object_type_selected(player, "schwarzenberg"))) {

switch (schwarzenberg % 3) {

case 0 :

bubble = $S("Double hit points!");

break;

case 1 :

bubble = $S("Double craft!");

break;

case 2 :

bubble = $S("Starts with 4 Commandos!");

break;

}

o = find_unit(1, "schwarzenberg");

schwarzenberg++;

}

for (i = 0; i < num_players(); i++) {

// if (find_nation(i+1) == "RUSSIANS") {

if (get_leader_name(i+1) == "king") {

// if (find_nation(i+1) == "Americans") {

// enable_type_by_tribe("Humvee",find_nation(i+1), "Stable", 0, 3);

// enable_type_by_tribe("Nuclear Missile Sub",find_nation(i+1), "Dock", 0, 3);

// gain_tech(i+1, "Classical Age");

// gain_tech(i+1, "Medieval Age");

// gain_tech(i+1, "Gunpowder Age");

// gain_tech(i+1, "Enlightenment Age");

// gain_tech(i+1, "Industrial Age");

// gain_tech(i+1, "Modern Age");

// gain_tech(i+1, "Information Age");

// gain_tech(i+1, "Missile Shield");

// gain_tech(i+1, "World Government");

// gain_tech(i+1, "Global Prosperity");

// gain_tech(i+1, "Artificial Intelligence");

// give_good(i+1, "Food", 3000);

// give_good(i+1, "Timber", 3000);

// give_good(i+1, "Metal", 3000);

// give_good(i+1, "Wealth", 3000);

// give_good(i+1, "Oil", 3000);

// give_good(i+1, "Knowledge", 3000);

// set_object_type_armor("Attack Helicopter", 30);

// set_object_type_max_health("Attack Helicopter", 500);

// set_type_line_of_sight("Attack Helicopter", 30);

// set_object_type_attack("Attack Helicopter", 3500);

// set_object_type_max_range("Attack Helicopter", 21);

for (n = 0;n <num_military_buildings(i+1); n++)

{

building = find_build(i+1,"");

set_object_health(i+1,building, 100);

}

for (a = 0; a < num_units(i+1); a++) {

unit_heal = find_unit(i+1, "");

unit_max_craft(i+1, unit_heal);

set_unit_craft(i+1, unit_heal,100);

if (object_health(i+1,unit_heal) < 100) {

heal_object(i+1,unit_heal,100);

}

}

}

}

if (length(bubble) > 0) {

bubble_text_obj(bubble, player, o);

}

}

}

-------------------------------------------------------------

用我的代码替换

\Rise of Nations\Thrones and Patriots\scenario\scriptlibrary\general_powers.bhs

用king作用户名,你就能爽了