 |
|
Mad-Kat
|
|
Camarillo, CA, USA
Apr 1999 time: 05:14
|
|
Good idea! I miss that spy tactic also.
|
|
|  |
 |
|
Mr Ogre
|
|
Azeroth
Jan 1970 time: 05:14
|
|
I believe the only way you can remove a building from a city via SLIC is with the SellBuilding event. I can't think of any way to destroy a building from a script otherwise, unfortunately. The SellBuilding event has two problems:
1) it'll give the player who owns the city gold for the building (which can then be removed with AddGold(-sellprice))
2) You can only sell a building once per turn per city, so if you use this, you'd only be able to sabotage one building per turn per city.
I realize the documentation on SLIC2 isn't available yet, so taking this out of context probably doesn't help much, but the syntax for adding a sell building event in a script is:
Event:SellBuilding(city, buildingDBIndex);
I'm also not sure how you'd go about asking them what building they want to destroy, SLIC isn't so hot for presenting a whole bunch of options. But maybe someone can think up something clever.
|
|
|  |
 |
|
TheLimey
|
|
I'm sorry to hear, MrOgre... sounds like a good candidate for an additional SLIC command in a patch. I might be wrong but it doesn't sound too complex to implement. I can think of a million uses for a create and destroy improvement/wonder statement, in scenario design.
I think thats a pretty serious ommission.
|
|
|  |
 |
|
Mr Ogre
|
|
Azeroth
Jan 1970 time: 05:14
|
|
Creating them can be done, that's no problem.
And, in fact, destroying all buildings in a city is possible. You'd have to modify the percentage on the nano-infect order to be 100% (so you'd probably want to remove nano-infect as an order) and generate a NanoInfection event for the city.
Then, recreate all the buildings you didn't want to destroy.
So, I guess I was wrong, maybe you can do it, it's just a bit convoluted.
I don't have a trick for removing a wonder, but I do have an alternative - since wonders are unique in the world, and can have advances which obsolete them - just add an advance that can't be gotten any other way, then give that advance to the player that owns the wonder you want to "remove". It won't remove the wonder, but it will turn off its effects. Just as good .
[This message has been edited by Mr Ogre (edited November 20, 2000).]
|
|
|  |
 |
|
TheLimey
|
|
MrOgre> Would it really be such a big deal to include something in the patch so this stuff isn't so kludgy?
I know that there is other stuff to do, but this does seem such a small thing.
BTW... if you do a kill unit command, please make sure it doesn't affect your score.
|
|
|  |
 |
|
SMIFFGIG
|
 |
Great Britain
Jul 2002 time: 05:14
|
|
Along with bribing, this would be a great idea to add to the spy, i would love it. Especially if the AI used it agianst you too.
The thing about being able to use precision bombing would be amazing too. These would be cool for your HotW mod Locutus.
I thought of that idea myself but didnt mention it as i thought it was already in ctp2. But i think im getting mixed up with civ3 (which doesnt implement it as good as being able to pick specifics) I THINK
Anyway 2 very good ideas. Could they not now (2yrs later) be implemented with SLIC ?
Last edited by SMIFFGIG on 01-10-2002 at 03:36
|
|
|  |
 |
|
SMIFFGIG
|
 |
Great Britain
Jul 2002 time: 05:14
|
|
Another cool spy option would be "STEAL MAP" it would be very low chance of getting it with it increasing with the newer units eg cyberninja etc. Or even steal partial map either as the initial task or as a lesser outcome for when trying to steal whole map.
Im pretty sure this can be done cause in the const.txt it has the following:
quote: GOSSIP_MAP_RADIUS 10 # When a map is revealed through gossip, a circle of # this radius appears
|
A leftover from gossip (which by the way can it be added back into the game??).
Could something like this be used to make the steal partial map work?
Last edited by SMIFFGIG on 01-10-2002 at 03:32
|
|
|  |
 |
|  |
 |
|  |
 |
|
Pedrunn
|
 |
of Natal, Brazil
Jul 2001 time: 02:14
|
|
Since my mod is taking longer than i expected.
Here is the bribe code if anyone wants it:
code:
// Bribe Order
//////////////////////////
int_t BribedType[];
unit_t BribedUnit[];
location_t BribeLocation;
int_t BribeCount;
int_t BRIBE_COST;
HandleEvent(AirliftOrder) 'BribeOrderByPedrunn' pre {
int_t num;
int_t i;
int_t j;
int_t tmpPlayer;
unit_t tmpUnit;
location_t tmpLoc;
location_t tmpLoc2;
city_t tmpCity;
tmpPlayer = g.player;
BRIBE_COST = 0;
BribeCount = 0;
tmpLoc = location[0];
num = GetUnitsAtLocation(tmpLoc);
GetCityByLocation(tmpLoc, tmpCity);
if(!CityIsValid(tmpCity)
&& num > 0) {
for(i = 0; i < num; i = i + 1){
GetUnitFromCell(tmpLoc, i, tmpUnit);
BribedUnit[BribeCount] = tmpUnit;
BribedType[BribeCount] = tmpUnit.type;
BribeCount = BribeCount + 1;
BRIBE_COST = BRIBE_COST + (Random(200)
// + (30*IsFlankingUnit(tmpUnit))
// + (100*IsEliteUnit(tmpUnit))
// + (40*IsNonGroupLandUnit(tmpUnit))
// + (20*SeaTransporterCapacity(tmpUnit))
// + (40*IsAirUnit(tmpUnit))
// + (100*IsLeviathonUnit(tmpUnit))
// + (50*(1 + AS_GetAge(tmpUnit)))
);
if(tmpUnit.owner == 0) {
BRIBE_COST = BRIBE_COST/2;
}
}
if(BribeCount > 0) {
if(PlayerGold(tmpPlayer) > BRIBE_COST) {
if(IsHumanPlayer(tmpPlayer)) {
BribeLocation = BribedUnit[0].location;
message(tmpPlayer, 'DoYouWantToBribe');
}
else{
for(i = 0; i < BribeCount; i = i + 1) {
Event: DisbandUnit(BribedUnit[i]);
}
for(j = 0; j < BribeCount; j = j + 1) {
CreateUnit(tmpPlayer, BribedType[j], BribeLocation, 0);
}
AddEffect(location[0], "SPECEFFECT_REVOLUTION", "SOUND_ID_REVOLUTION");
AddGold(tmpPlayer, BRIBE_COST);
}
}
else{
if(IsHumanPlayer(tmpPlayer)) {
message(tmpPlayer, 'NotEnoughMoneyForBribe');
}
}
}
}
else{
// AddEffect(BribeLocation, "SPECEFFECT_NONE", "SOUND_ID_NONE"); // Dont exist
}
return STOP;
}
alertbox 'DoYouWantToBribe' {
int_t i;
int_t j;
int_t tmpPlayer;
tmpPlayer = g.player;
show();
text(ID_DO_YOU_WANT_TO_BRIBE);
Button(ID_YES) {
if(Random(4) == 0) {
for(i = 0; i < BribeCount; i = i + 1) {
Event: DisbandUnit(BribedUnit[i]);
}
for(j = 0; j < BribeCount; j = j + 1) {
CreateUnit(tmpPlayer, BribedType[j], BribeLocation, 0);
}
AddEffect(location[0], "SPECEFFECT_REVOLUTION", "SOUND_ID_REVOLUTION");
AddGold(tmpPlayer, BRIBE_COST);
}
else{
message(tmpPlayer, 'TheyAreGoodSoldiers');
}
Kill();
}
Button(ID_NO) { // if the player does accept
Kill();
}
}
alertbox 'NotEnoughMoneyForBribe' {
show();
text(ID_BRIBE_COST_TOO_HIGH);
Button(ID_OK) {
Kill();
}
}
alertbox 'TheyAreGoodSoldiers' {
show();
text(ID_BRIBE_REFUSED);
Button(ID_OK) {
Kill();
}
}
and this should go to the orders.txt (note: all units that can sue will have the brice ability.
code:
ORDER_BRIBE {
Gold 0
Move 100
EventName "AirliftOrder"
LocalizedName str_ldl_order_airlift
StatusText str_ldl_order_airlift
TargetPretest:EnemySpecialUnit
UnitPretest_CanSue
Range 1
CPIcon "upsi21.tga"
ButtonLocation 10
DefaultIcon ICON_ORDER_INCITE_REVOLUTION
Cursor 40
InvalidCursor 41
}
And this should go in the info_str.txt
code:
DO_YOU_WANT_TO_BRIBE "Great Leader, we could surely use this army for our needs but they we calculate an overall cost of {BRIBE_COST} gold from our treasury. Are you Do you want to send them the offer?"
BRIBE_COST_TOO_HIGH "Unfortunetly, Our treasury cannot afford the {BRIBE_COST} gold expense for bribing these units. "
BRIBE_REFUSED "The men you tried to bribe are too patriotic soldiers so they did not accept the offer."
and finally this is to go in the scen_str.txt.
code:
ORDER_BRIBE "Bribe"
str_ldl_order_airlift "Bribe"
OK "Ok"
Sorry for messing up the thread lenght
Last edited by Pedrunn on 31-10-2002 at 03:47
|
|
|  |
 |
|  |
All times are GMT. The time now is 05:14. Apolyton Time is 00:14. |
top of page
|
| archivepost |
|
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
|
|
|
|
|
|