Apolyton Archive  |  Preserved copy of the Apolyton Civilization Site and its forums as they stood in September 2005. Read-only; nothing here can be posted to or replied to.  |  Forum index |  About this archive |  The 1998–2001 UBB forums
Today on Apolyton WARDELL INTERVIEW PROMO A.C.S. HISTORY CHAPTER 4 GET CIV4 /w FREE PLUS! A.C.S. PHOTO GALLERY GET A.O.M. V1.1
Apolyton Civilization Forums
main| civ2| civ3| civ4| smac| ctp2| ron| moo3| galciv| galciv2| alt| about|
ApolytonPLUS | register | search | faq | new posts | pm (-/-) | upload | members
hall of fame new! | civgroups | civgroups news | interviews | the column | radio | chat | directory | news | store | PLUS
Apolyton Civilization Forums : Powered by vBulletin version 2.0.3 Apolyton Civilization Forums > Miscellaneous > Archive > CtP2-Creation/AI/Mods/Scenarios-Archive > Hidden Nationality SLICable?
Show a Printable Version | Email This Page to Someone! | Receive updates to this thread | Report this to Apolyton news!

bottom of page
  
Author
Thread   
Pages (2): [ 1   2   ]
< Last Thread     Next Thread > Post New Thread     Post A Reply
E is offline E
King
July 24,2005 Ctp2 Tiles in sig!
May 1999
time: 21:21
  Old Post 22-08-2002 19:58 Visit E's homepage!
Edit/Delete Message Reply w/Quote
#1 Report this post to a moderator
Hidden Nationality SLICable? Remove this text

Anyone been playing Civ3 and see how privateers work? The hidden nationality lets you attack without declaring war or your enemy knowing who you are. it adds another challenge, mainly when you apply the ability to a ground unit and even bettera stealth bomber or submarine.

I know CTP2 has invisible units and great unconventional units, but is there something similar to this or even is this SLICable?

Immortal Wombat is offline Immortal Wombat
Prince
in perpetuity
Dec 2000
time: 05:21
  Old Post 22-08-2002 20:44 Visit Immortal Wombat's homepage!
Edit/Delete Message Reply w/Quote
#2 Report this post to a moderator
Put an end to popups!

I imagine the unit's shield could be a stumbling block.

SMIFFGIG is offline SMIFFGIG
Prince
Great Britain
Jul 2002
time: 05:21
  Old Post 26-08-2002 04:15 Visit SMIFFGIG's homepage!
Edit/Delete Message Reply w/Quote
#3 Report this post to a moderator
Increase the size of your Attachments

Even still the unit would be a good little addition to CtP2. A Naval special unit. Thats if it could be done

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 30-08-2002 17:43
Edit/Delete Message Reply w/Quote
#4 Report this post to a moderator
Support Apolyton

Is there just the pirate ship in civ3 or also other units with hidden nationalities?

I gave this some thought and here's what I came up with:
We create a new unit. I'll be civilian and hidden like spies so it can wander enemy territory without problems. Now, for the tricky part: Attack
We'd use the following event to trigger this: SleepUnit(unit_t)
When you select sleep for a hidden nationality unit a slic code wakes the unit again (so sleeping is actually disabled for those unit), looks for enemy unit in a square next to it and if found

1. kills it. ->Not desirable because no risks and no real battle. We could however adjust that and just give out hitpoints acording to strength - would make us write our own battle routine though.

2. possibility: it creates a barbarian unit that's supposed to attack. But can we tell a Barbarian unit to do one of those events during another players turn?
Battle(army_t, location_t), StartCombat(army_t, location_t)
other than that we could give it a move order:
MovePathOrder(army_t, location_t)
but would the barbarian ai perhaps change this? Or what if the the unit to be attacked moves before it's the barbarians turn (higly likely)

So who's got some insight into this?

Martin Gühmann is offline Martin Gühmann
Emperor
Berlin, Germany
Mar 2001
time: 06:21
Post  Old Post 30-08-2002 18:11 Visit Martin Gühmann's homepage!
Edit/Delete Message Reply w/Quote
#5 Report this post to a moderator
Enter the AD-FREE zone

MovePathOrder doesn't work it checks if it is possible to move to the target location, and if there is an enemy unit or city it doesn't work. BTW this slic event isn't used by the move order in the orders.txt.

Battle works, I didn't test StartCombat.

-Martin

child of Thor is offline child of Thor
Emperor
UK
Jan 2002
time: 05:21
  Old Post 01-09-2002 20:23
Edit/Delete Message Reply w/Quote
#6 Report this post to a moderator
Full PM-box? Change here!

Going on what IW said about the unit shield, i guess as mapfi say's it's logical to make it a stealth unit like the spy, so it can only be spotted by specific enemy units. When you pirate a trade route for example, or if someone pirates yours - then you sometimes get a text box informing you of the event(i guess there is a % chance of detection somewhere in the trigger for those actions).You could just leave this trigger out so neither the player or the AI would know who performed it without actually having units in the location to spot the stealth unit.
When you have a sub, you are pretty much invisible(and your shield),except to a few units - so no problem there. If it's possible to hide the units activities(like a spy spying or stealing tech), then it seems possible? Or maybe i'm not understanding how stealth units really work?
Attack is a tricky one - i'm pretty sure you always know who it is who attacks you and visa-versa..........can't think of any exceptions But maybe it's just something that can be turned off?

Last edited by child of Thor on 01-09-2002 at 20:28

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 01-09-2002 22:41
Edit/Delete Message Reply w/Quote
#7 Report this post to a moderator
Tired of ads?

quote:
Originally posted by child of Thor Attack is a tricky one - i'm pretty sure you always know who it is who attacks you and visa-versa..........can't think of any exceptions But maybe it's just something that can be turned off?


I'm sure there's no way you can't turn it off - that's why I had those two ideas mentioned in the post above. In the first you just see your unit die/get hurt and no enemy unit around - unless you accidently move on the same spot. In the second you'd just see a barbarian come out of nowwhere and attack you. In each case you'd know that an invisible/hidden nationality unit was the cause but you wouldn't know who - unless you had a stealth unit nearby to spot the enemy one.

child of Thor is offline child of Thor
Emperor
UK
Jan 2002
time: 05:21
  Old Post 02-09-2002 19:39
Edit/Delete Message Reply w/Quote
#8 Report this post to a moderator
Browse Apolyton AD-FREE

well in that case maybe the first option would be best, although the second is o.k. Hmmm? It wouldn't matter that a special unit could see your unit - that's what they are for after all.Might have to make the A.I. give greater priority to haveing a special unit in it's armies if it starts to come under this special attack more than a few times.
It would be a nice addition - although if it's a big job to do, i'm more than happy with the present selection of special units already. Just a thought, does anyone know if you use a sub to pirate trade routes is it just the same as if you used a non-stealth ship - does the A.I still get the same tip-off/player same message box?

Martin Gühmann is offline Martin Gühmann
Emperor
Berlin, Germany
Mar 2001
time: 06:21
Post  Old Post 02-09-2002 20:33 Visit Martin Gühmann's homepage!
Edit/Delete Message Reply w/Quote
#9 Report this post to a moderator
Support Apolyton, buy Civilization III: Complete

quote:
Originally posted by child of Thor
Just a thought, does anyone know if you use a sub to pirate trade routes is it just the same as if you used a non-stealth ship - does the A.I still get the same tip-off/player same message box?


I know that the AI uses the subs like conventional units to pillage my coasts, fro the tips and message boxes I would say the AI gets none of them. For the subs you could use the cheat editor place a city with some sea improvements and switch over to a different civ place then a sub of that on a sea improvement and pillage it if you recieve a message that you are now at war then it works like with the conventional units. Of course make shure first that both nations have contact. BTW if I use the slaver then I get a declaration of war.

-Martin

child of Thor is offline child of Thor
Emperor
UK
Jan 2002
time: 05:21
  Old Post 02-09-2002 21:41
Edit/Delete Message Reply w/Quote
#10 Report this post to a moderator
Full PM-box? Change here!

Thanks Martin, i also seem notice the AI pillaging my coasts with subs, just never really noticed if it happend outside of the 'view' of any sub-detecting ships. I'll try a MP game and see how it works on that( I like to test stuff this way so i can see how cool mp can be!)

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 05-09-2002 12:37
Edit/Delete Message Reply w/Quote
#11 Report this post to a moderator
Support Apolyton, buy Civilization III: Complete

Ok, so the thing I'm going to try whenever I find the time is the naval unit, a pirat ship with the following abilities:
Civilian unit, stealth unit, can attack a enemy ship without disclosing it's nationality (don't know yet which workaround i'll use), can pirate trade routes, can pillage

would be cool if anybody could extract the graphics of the privateer from civ3 for me

Locutus is offline Locutus
ACS CTP1/2 Manager & Civ4 Co-Manager
Hengelo, The Netherlands
Nov 1999
time: 06:21
  Old Post 05-09-2002 13:53 Visit Locutus<br><img src=/forums/images/staff-icon.gif>'s homepage!
Edit/Delete Message Reply w/Quote
#12 Report this post to a moderator
Get a bigger avatar today!

One could give the unit 0 Attack, a high Ranged value and Bombard capabilities. That way at least the human player wouldn't know who's attacking (bombarding) him. I don't know about the AI though...

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 05-09-2002 14:25
Edit/Delete Message Reply w/Quote
#13 Report this post to a moderator
Support Apolyton, buy Galactic Civilizations: Deluxe Edition

The AI is certainly a problem and wouldn't bombarding also declare war? Just thought of another possibilty: If in the attack order I execute my special-attacking slic and then return STOP, would that prevent the enemy from knowing who it was?

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 07-09-2002 22:58
Edit/Delete Message Reply w/Quote
#14 Report this post to a moderator
Support Apolyton buy from Amazon

Okay, I changed the settings of the longship instead of creating a new unit just for testing. What works is this - the AI doesn't declare war on me, so he doesn't know who's done it. Nevertheless through the cheat editor I see, that the ship becomes visible after the stopped attack, so it won't work in multiplayer.
If you want to have a lok at it, here it is... Desperate to keep my regular game clean from any modding I always create a new mod, so that's how this is set up.
Next, I'll try the solution with the barbarians.

Attachment: hina.zip
This has been downloaded 4 time(s).

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 08-09-2002 01:16
Edit/Delete Message Reply w/Quote
#15 Report this post to a moderator
Support Apolyton buy from Amazon

Here are the next two. The trigger for the attack is the entrench order for the longship as it can't attack with this setting. The code checks all tiles around and in b kills the enemy unit, in c creates a barbarian battleship nearby which is killed after it has done one attack. However, the barbarian ship can't attack during my turn even though I tell it in the code to do so. So if you don't dissappear with your ships immeadetly it might attack you.

I think I'll try further with b even though one could argue that c is also realistic since government paid pirates tend to be unpredictable... I'd still be happy if someone could get the flics of the privateer into ctp2 sprites since I don't have the appropriate programs.
Note: Just now I had the code only execute when there's one longship and one enemy ship. I'll change that, even though I'm thinking pirates will preferably pick on single ships.

Note2: This time I'm packing just the slc and the units.txt, so you need the first one to run it.

Attachment: hina_b.zip
This has been downloaded 4 time(s).

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 08-09-2002 01:16
Edit/Delete Message Reply w/Quote
#16 Report this post to a moderator
Support Apolyton

and c:

Attachment: hina_c.zip
This has been downloaded 4 time(s).

Locutus is offline Locutus
ACS CTP1/2 Manager & Civ4 Co-Manager
Hengelo, The Netherlands
Nov 1999
time: 06:21
  Old Post 08-09-2002 05:21 Visit Locutus<br><img src=/forums/images/staff-icon.gif>'s homepage!
Edit/Delete Message Reply w/Quote
#17 Report this post to a moderator
Get a bigger avatar today!

Rather than event 'Battle' you could try using some of the movement-related events to get the Barb unit to attack in the same turn: when CtP2 was still under development and Harlan suggested MAD as addition to the game, Mr Ogre told us that that was possible because at that time, units couldn't move outside their own turn. A few days later he reported MAD would be implemented after all since he had found a way to make units move outside their own turn. That might be key here: he may have created a new event that made units move without checking if this was legal. There are many movement related events in the game, so if you try some of these to get the unit to move into the square that should be attacked, that *might* just work...

SMIFFGIG is offline SMIFFGIG
Prince
Great Britain
Jul 2002
time: 05:21
  Old Post 08-09-2002 05:42 Visit SMIFFGIG's homepage!
Edit/Delete Message Reply w/Quote
#18 Report this post to a moderator
Support Apolyton buy from Amazon

This is the original news topic might be of some interest

[QUOTE](8 July 2000, 09:34 | CtP2) That's right! CTP2 is going to model Mutually Assured Destruction! Here's what Mr. Ogre announced on our forums

We now have a system for targeting and then auto-launching nukes when you get nuked in the main game. I had said we weren't doing anything new for nukes, but I was wrong, we are, it's in and working.

There's still a whole lot more in that monster Nuke thread that we're not doing, but this one "little" thing is pretty cool.

If only we had one of those alpha(?) builds to see this in action... [QUOTE]

Now whatever happened to that idea i wonder? Any thoughts on weather it would be good to implement IF it could be done? And gives some backup that there is code there that could be put to use for the privateer but how????


SMIFFGIG

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 08-09-2002 21:04
Edit/Delete Message Reply w/Quote
#19 Report this post to a moderator
Browse Apolyton AD-FREE

code:
//MoveUnits(army_t, location_t, location_t) //An army always moves on this event, no more legality checks at this point //MADLaunch(unit_t) //SetTarget(unit_t, city_t) Give a nuclear missile (unit) a target //TargetOrder(army_t, location_t) Give a nuclear missile a target //INT CreateCity(owner, nearlocation, distance[, savecity])

I've tried all those. The first one has no effect even though it says the army should move.
The second one always gives me a serious error in the ctp.exe while executing no matter how I try. E.g I tried to just create a city at that spot to use settarget. That's all events/functions I could find in the documentation. In the NuclearWar scenario there's a function called
code:
TargetNuclearAttack(1, 2, 1)
but without knowing what the values stand for...

Edit: Made the post a little narrower...

Last edited by mapfi on 09-09-2002 at 16:52

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 09-09-2002 11:19
Edit/Delete Message Reply w/Quote
#20 Report this post to a moderator
Lose 30 kilos (of popups)

Played with other possibilities too, e.g. my own battle deciding algorithm. I had to use the unitrecord variable for accessing the defense value of a unit but somehow the code doesn't work exactly the way I want it yet. Has anybody any experiences with unitrecord array?

Pedrunn is offline Pedrunn
King
of Natal, Brazil
Jul 2001
time: 02:21
  Old Post 09-09-2002 14:49
Edit/Delete Message Reply w/Quote
#21 Report this post to a moderator
Support Apolyton, buy Call to Power 2

Here is the Elite Unit code wich uses the unitrecord array.

Background: This makes code makes a unit only buildable by a civ that dicovered an advance and got luck ina 1/6 random number.
Our CTP2 version of unique units.

Attachment: as_chris.slc
This has been downloaded 2 time(s).

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 09-09-2002 16:50
Edit/Delete Message Reply w/Quote
#22 Report this post to a moderator
Put an end to popups!

Thanks Pedrunn. Seems like I used it the correct way then.
Off the Thread-Topic: Is this code included in any particular mod? I find the refugee bit pretty attractive.

Martin Gühmann is offline Martin Gühmann
Emperor
Berlin, Germany
Mar 2001
time: 06:21
Post  Old Post 09-09-2002 18:24 Visit Martin Gühmann's homepage!
Edit/Delete Message Reply w/Quote
#23 Report this post to a moderator
Support Apolyton, buy Galactic Civilizations

quote:
Originally posted by mapfi
Thanks Pedrunn. Seems like I used it the correct way then.
Off the Thread-Topic: Is this code included in any particular mod? I find the refugee bit pretty attractive.


The file name looks like taken from MedPack2 and the features that it should have are also part of MedPack2.

So play MedPack if you want to see this in action.

-Martin

Pedrunn is offline Pedrunn
King
of Natal, Brazil
Jul 2001
time: 02:21
  Old Post 09-09-2002 19:46
Edit/Delete Message Reply w/Quote
#24 Report this post to a moderator
Avatar Enlargement: We've got the solution

MedMod does have both codes included. But the file isnt from there since I am using it in my owns modifications. The Refugee came as bonus since i was toolazy to take it off. I am glady you liked my laziness consequences though.

Last edited by Pedrunn on 09-09-2002 at 19:53

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 09-09-2002 22:27
Edit/Delete Message Reply w/Quote
#25 Report this post to a moderator
Support Apolyton buy from Amazon

Here's what I've tried now:

code:
HandleEvent(EntrenchOrder) 'PrivateerAttack' pre { unit_t tmpUnit; unit_t tmpUnit2; army_t tmpArmy; army_t tmpArmy2; location_t tmpLocation; location_t tmpLocation2; int_t i; int_t k; int_t end; int_t factor; int_t factor2; tmpLocation = army[0].location; if (UnitsInCell(tmpLocation) == 1) { GetUnitFromCell(tmpLocation, 0, tmpUnit); if (tmpUnit.type == UnitDB(UNIT_LONGSHIP)) { while (i <= 7 && end == 0) { GetNeighbor(tmpLocation, i, tmpLocation2); if(TerrainType(tmpLocation2) >= 10 && TerrainType(tmpLocation2) <= 17) { k = UnitsInCell(tmpLocation2); if (k == 1) { GetUnitFromCell(tmpLocation2, 0, tmpUnit2); if (tmpUnit2.owner != tmpUnit.owner && tmpUnit2.owner != 0) { unitrecord[0] = tmpUnit2.type; factor = tmpUnit2.hp*unitrecord[0].Defense; factor2 = tmpUnit.hp*30; if (factor2 > (factor*2) / 3) { KillUnit(tmpUnit2); } elseif (factor2 < factor2 / 3) { KillUnit(tmpUnit); } else { DamageUnit(tmpUnit, 5); DamageUnit(tmpUnit2, 5); } end = 1; } } } i = i + 1; } } } return STOP; }

Funny thing is - it works exactly once and only once like it should - after that any fortify order to my longship has no effect on the enemy's ships anymore. Anybody got a clue?

Locutus is offline Locutus
ACS CTP1/2 Manager & Civ4 Co-Manager
Hengelo, The Netherlands
Nov 1999
time: 06:21
  Old Post 10-09-2002 01:57 Visit Locutus<br><img src=/forums/images/staff-icon.gif>'s homepage!
Edit/Delete Message Reply w/Quote
#26 Report this post to a moderator
Support Apolyton buy from Amazon

quote:
Originally posted by mapfi
factor = tmpUnit2.hp*unitrecord[0].Defense;


This line is the problem. You can't just use unitrecord[0] out of context, it will give you a void unit record, meaning that all values from it will be 0. Some value should be assigned to unitrecord[0] before it can be used, just like with unit[0], city[0] and any other object. But since you can't assign a value to a unitrecord object yourself, you must use a different approach, namely the database functions:

code:
factor = tmpUnit2.hp*UnitDB(tmpUnit.type).Defense;

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 10-09-2002 10:38
Edit/Delete Message Reply w/Quote
#27 Report this post to a moderator
Support Apolyton, buy Civilization: The Boardgame

code:
unitrecord[0] = tmpUnit2.type;

You mean that part is not working? Thanks a lot, I'll try tonight.

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 11-09-2002 00:55
Edit/Delete Message Reply w/Quote
#28 Report this post to a moderator
Support Apolyton buy from Amazon

Tried and had no luck - it will still execute once and only once - there must be some other flaw we didn't spot. I took out the unitrecord but now I'm not sure if it wouldn't have worked after all. Locutus did you just not see the assigning lign and it should work after all? Even if, that's not what's going wrong in this thingie. The temp variables in this handler are reinitialized each time for sure, aren't they?! What else could it be???

Martin Gühmann is offline Martin Gühmann
Emperor
Berlin, Germany
Mar 2001
time: 06:21
Post  Old Post 11-09-2002 01:16 Visit Martin Gühmann's homepage!
Edit/Delete Message Reply w/Quote
#29 Report this post to a moderator
Support Apolyton, buy Alpha Centauri

quote:
Originally posted by mapfi
The temp variables in this handler are reinitialized each time for sure, aren't they?! What else could it be???


No, the temp variables are just initialized once, that is true for every other variable, too. That saves some time. I learned this lesson the hard way as I tried to used an array to store location data and wondered why the ComImpsForAIs3.slc code still build the tile imps, even if all coditions were wrong. The current version allows now the array to grow to infinite, so far no problems weren't reported. That is actual a memory lack, and I don't know how to reduce the size of the array afterwards it has been grown dinymically. When Dave release Cradle v.1.33 I will put the latest version into the directory, I hope I don't have to modify it.

-Martin

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:21
  Old Post 11-09-2002 12:01
Edit/Delete Message Reply w/Quote
#30 Report this post to a moderator
Support Apolyton, buy Civilization: The Boardgame

You're saying my int_t end stays 1 after this code has been executed the first time? If so then it's clear why it won't work. But hey, what a screwed language this is!!!

 
Pages (2): [ 1   2   ]
< Last Thread     Next Thread > Post New Thread     Post A Reply
All times are GMT. The time now is 05:21.
Apolyton Time is 00:21.
    top of page
Rate This Thread:
archivepost
Forum Jump:
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
 




Contact Us - Apolyton Civilization Site - Support Us!

Building a better Apolyton through better information. Click here and take our poll!
Non-US visitors, click here!

Powered by: vBulletin Version 2.0.3
Copyright ©2000, 2001, Jelsoft Enterprises Limited.

Page generated in 0.0535 seconds (91.28% PHP - 8.72% MySQL) with 31 queries
Page Loading Time:

Support Apolyton: Amazon USA | Amazon UK | Amazon DE | Amazon FR |
Support Apolyton and get FREE PLUS, Buy from Chips&Bits: Galactic Civilizations | Galactic Civilizations: Deluxe Edition | Call to Power 2 | Civilization: The Boardgame | GURPS/ Alpha Centauri | Alpha Centauri | Civilization IV | Civilization III: Complete |


Front Page | Civilization IV | Civilization III | Civilization II | Call to Power II | Alpha Centauri | Master of Orion III
Rise of Nations | Galactic Civilizations | Galactic Civilizations II | Misc
Alt.Civs | Civ I | C:CtP I | About | News | Directory | Apolyton Store | Forums | Chat | Columns | Interviews | Newsletter
Scenario League | CSC | Clash of Civs | Spanish Site | CtP Maps | Cradle of Civ | WesW's Ctp1/2 Site | Civ3 Haven

apolyton.net | apolyton.com | civilization2.net | civilization3.net | civilization4.net | civilizationiv.info | calltopower.net | galciv.net | galciv2.net | moo3.net