Announcement

Collapse
No announcement yet.

New units

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Would that mean that if I had an old settler sitting around after I discovered the tech to build engineers (or whatever), and used it to build a city, it would only be pop 1? Not sure I like that...

    I'd at least like the option to disband the settler in a city and reclaim the pop point, and then rebuild a new engineer.

    wheathin
    [This message has been edited by wheathin (edited December 09, 1999).]

    Comment


    • #17
      Maybe it's possible to automatically disband all settlers and add the pop points to the nearest city or replace them by engineers or whatever. This would solve your issue. It's still a question if that's a good solution. Personally I'd just keep those settlers for what they are and accept my loss of the smaller cities (don't build too many settlers if you're close to inventing engineers )
      Administrator of WePlayCiv -- Civ5 Info Centre | Forum | Gallery

      Comment


      • #18
        What do you think if this new settler - engineer - could plant some good too ?
        Apolyton QuickStart for CTP PBEM

        Comment


        • #19
          I'm not so sure. How close together could the good be planted? Would it cost money to plant?

          The problem is that then the human player plants goods in every square around a city, and gets thousands of free gold, while the AI remains blissfully cleuless.

          Wheathin

          Comment


          • #20
            For a scenario, I write a trigger who add one good for each new cities build, so AI players add the good too when the build a city.
            My question is:
            Is-it possible to know in SLIC which unit build a city ?
            [This message has been edited by slamp (edited December 11, 1999).]
            Apolyton QuickStart for CTP PBEM

            Comment


            • #21
              Not sure...
              One would definitely need to find a way for settlers to be "replaced" by engineers, or else don't have them disbanded, just have them excluded from build lists when the advance enables engineers....But how does one make settlers obsolete without condemning all remaining ones to immediate death?
              Civ2's way was cool--they all turn into engineers, with the L. Workshop wonder. I wonder what code did that...and if that can be done thru Slic...?
              Existence is Futile.

              Comment


              • #22
                Obsolete units don't disappear. At least, my phalanxes are always still around in the modern era if I don't disband them. So you should just obsolete settlers with the advance that allows engineers.

                Comment


                • #23
                  Nordicus:
                  Good idea to replace settlers with engineers, hadn't thought of that yet. I think it should be possible, here's a quick idea of how it might be done (don't have the time to work it out in detail, but it's a good starting point - I'll try and fill in the details later. Update: details filled in):

                  trigger 'ReplaceSettlers' when (HasAdvance(g.player, "ADVANCE_INDUSTRIAL_REVOLUTION")) {
                    &nbsp i = i + 1;
                    &nbsp SetUnitByIndex(1, g.player, i);
                    &nbsp if (unit.type == UnitType("UNIT_SETTLER")) {
                       &nbsp KillUnit(unit);
                       &nbsp CreatUnit(g.player, UnitType("UNIT_ENGINEER"), unit.location, 0);
                    &nbsp }
                    &nbsp if (i == player.totalunits) {
                       &nbsp DisableTrigger('ReplaceSettlers');
                    &nbsp }
                  }

                  Should work like this although I haven't tested it yet.

                  Locutus

                  [This message has been edited by Locutus (edited December 16, 1999).]
                  Administrator of WePlayCiv -- Civ5 Info Centre | Forum | Gallery

                  Comment


                  • #24
                    Paul:
                    Yes, good point--I think it was a momentary lapse of reason: had government changes in mind, yunno, like when you switch out of Monarchy and all your Clerics croak? (This happens in everyone's game, I hope!)


                    Lucutus:
                    (Did you guys get a new Borg Queen yet? )
                    Hey, looks good--my files are too whacked right now to test that, but it definitely appears to have potential.

                    What advance do you (and to anyone) think would be appropriate for an engineer unit? I had Industrial Revolution in mind...what do you all think?
                    Existence is Futile.

                    Comment


                    • #25
                      Okay people, I updated the trigger above, it should work like this although I haven't tested it yet (will do that tonight or tomorrow). I used Nordicus's suggestion of Industrial Revolution as the required advance, but this could obviously be changed.

                      Nordicus:
                      IMHO the advance that should enable the engineer is dependant on its extra capabilities apart from building cities. If it will make a city autogrow to e.g. size 3, then Industrial Revolution is what I have in mind as well. During the period of the Industrial Revolutian (in reality that is) a large movement from the countryside to the city took place. Small villages rapidly grew out into large cities. So the engineer would really fit in here, as it rapidly creates large cities.
                      Would you give it some terraforming or similar (e.g. trade goods creating) capabilities, than Explosives might be better in place. This because terraforming or smoothening terrain for installations or whatever will require explosive materials.
                      A third option, that has been mentioned in the "How can I create a city with a granary"-thread, is to auto-build units and, if possible, buildings. I'm not sure about what advance would fit best here, but maybe Mass Production is an idea? After all, you are building large amounts of units/buildings in a very short time.

                      Well, thats enough for know, see ya

                      Locutus
                      [This message has been edited by Locutus (edited December 16, 1999).]
                      Administrator of WePlayCiv -- Civ5 Info Centre | Forum | Gallery

                      Comment


                      • #26
                        Hey, sounds good--lemme know how the test goes. We seem to be on the same page here--precisely what I thought regarding the Industrial Rev.
                        Explosives...that was Civ2's enabling advance...yeah, now I remember (been a while!). I don't think any special qualities like that are necessary...the bigger city size should do, hey?
                        If there would be another unit, part three of the settler, for still more modern times (our current era perhaps, if...), then something like what you're suggesting would make sense (a "terraformer"?). But for now, I think this is fine.

                        (PS: did ya get that Nordicus Giganticus working ok?)

                        (PPS: Nevermind: you just emailed about that.)
                        [This message has been edited by Nordicus (edited December 19, 1999).]
                        Existence is Futile.

                        Comment


                        • #27
                          You could make the size of the city built dependent on other factors too:
                          Whether the individual has certain tech advances, for example (if just explosives, city size=2, if mass production then 3, etc)
                          This could also be linked in to the year, if you wanted to maintain the realism of the timeline (although I don't like the idea much - why penalise yourself for being more advanced in the same year than you usually are?).

                          On a related point, would the AI also be able to take advantage of this - ie would the SLIC trigger when the AI build cities (haven't got around to reading any of the SLIC documentation yet - saved it all to disk, planning to use it as an escape from realtives over Christmas! ).

                          Finally, how long does SLIC code take to process in-game? What I'm thinking is that if you tried (sorry, when you succeeded ) to implement the advance-dependent city size and ready-built improvements, it would take a fair bit of nesting - would this cause any problems?
                          Just a thought......

                          Comment


                          • #28
                            *Ahem* It wasn't so impotrant I needed to post it twice.... :/
                            [This message has been edited by DanMc (edited December 20, 1999).]
                            Just a thought......

                            Comment


                            • #29
                              DanMc:

                              SLIC applies to human players as well as to AI-players, there's no difference at all. You can however, if you would like to, make a trigger that uses the IsHumanPlayer()-function to make a trigger apply to humans (or AI-players) only.
                              About the speed, right now the trigger is problably going to take up more time than necessary, because it is tested for every turn (g.player-triggers are evaluated every turn - all g.something-triggers are). I will make it more efficient once I get this thing to work properly. (I ran into some trouble and Nordicus send me a great map that's keeping me occupied - I'll mail you about it later, Nordicus) I don't think it will take up too much time as long as one doesn't make a lot of triggers like this.

                              Locutus
                              Administrator of WePlayCiv -- Civ5 Info Centre | Forum | Gallery

                              Comment


                              • #30
                                Can anyone help me out here? I've tested the function I mentioned above, but it didn't work as well as I had expected (so far business as usual). I made a few changes and now I have this function:

                                Code:
                                TypeLocation settlerlocation;
                                TypeUnit settlerunit;
                                
                                trigger 'Locutus_ReplaceSettlers' when (HasAdvance(g.player,
                                                              ID_ADVANCE_INDUSTRIAL_REVOLUTION) ) {
                                	i = 0;
                                	while (i < player.totalunits) {
                                		SetUnitByIndex(1, g.player, i);
                                		if (unit.type == UnitType("UNIT_SETTLER")) {
                                			settlerunit = unit.1;
                                			settlerlocation = unit.location;
                                			KillUnit(settlerunit);
                                			CreateUnit(g.player, UnitType("UNIT_MACHINE_GUNNER"), settlerlocation, 0);
                                		}
                                		i = i + 1;
                                	}
                                }
                                The strange thing is, this trigger doesn't replace all settler by machine-gunners (I don't have an engineer-unit yet, so I used machine-gunners for testing purposes), but it replaces a few settlers every turn, apparently at random. Could anyone tell me what I've done wrong? I can't see why it doesn't replace all settlers at once.
                                [This message has been edited by Locutus (edited January 10, 2000).]
                                Administrator of WePlayCiv -- Civ5 Info Centre | Forum | Gallery

                                Comment

                                Working...
                                X