Announcement

Collapse
No announcement yet.

CantAttackCity()

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

  • CantAttackCity()

    The CantAttackCity() function does not work correctly. I continue to get an error that tells me I'm using the wrong argument. The argument its choking on is the city argument. I've tried many varations to get the function to work, however, it will not take the city arguement. I've followed the syntax in my SLIC functions reference document so I figure that either the function does not work or Activision has given has given us the wrong syntax. If anyone knows the proper usage of CantAttackCity() please post it.

  • #2
    Another buggy function probably. Others include GetNearestWater, GetCoastalCity, CutImprovements (not broken, but needs a lot of care) etc...

    Its not used in any of the Activision scenarios, and I don't think anyone else here has used it at all Maybe you could do a work around. (Check each attack, and return STOP if necessary) or something.
    Sorry

    Good luck though

    Ben
    Concrete, Abstract, or Squoingy?
    "I don't believe in giving scripting languages because the only additional power they give users is the power to create bugs." - Mike Breitkreutz, Firaxis

    Comment


    • #3
      This code does not produce a slic error, but it doesn't work either I don't know why. It should make all cities on the map immune to attacks and captures but it just doesn't work:

      PHP Code:
      HandleEvent(BeginTurn'MG_CantAttackCity_Test' pre {
      city_t MGCity;
      int_t i;
          for(
      0<= player[0].cities1) {
              
      GetCityByIndex(player[0], i,MGCity);
              if(
      CityisValid(MGCity)) {
                  
      CantAttackCity(MGCity1);
              }
          }

      -Martin
      Civ2 military advisor: "No complaints, Sir!"

      Comment

      Working...
      X