Results 1 to 9 of 9

Thread: Destroying buildings - scripting question?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Member Member Nero's Avatar
    Join Date
    Feb 2005
    Location
    Netherlands
    Posts
    52

    Default Re: Destroying buildings - scripting question?

    Another question like this: Is it possible to script building construction, and make a city build a building as soon as it's captured? Maybe something to put a building in the building queue directly after the city is captured? I've just read something about create_building, what does this do?

  2. #2
    Shaidar Haran Senior Member SAM Site Champion Myrddraal's Avatar
    Join Date
    Feb 2004
    Location
    UK
    Posts
    5,752

    Default Re: Destroying buildings - scripting question?

    create building makes the building appear immidiately, not put it on the building queue.

    You could do this by simulating the mouse clicks again.

  3. #3

    Default Re: Destroying buildings - scripting question?

    @ Nero
    How to: Create Buildings using scripts

    @ Myrddraal
    Yes, of course, my head was just in completely the wrong place.

    So, just to spout code randomly:
    Code:
    	declare_counter TarquiniiCaptured
    
    monitor_event GeneralCaptureSettlement FactionType romans_julii
    		and SettlementName Tarquinii
    
    		set_counter TarquiniiCaptured 1
    		inc_counter citiescaptured 1
    
    		terminate_monitor
    	end_monitor
    
    	monitor_conditions I_CompareCounter TarquiniiCaptured = 1
    
    console_command destroy_building milita_barracks ; if such a command exists
    ;don't know if you could destroy AI buildings by mouse clicks
    
    	end_monitor
    Last edited by Epistolary Richard; 04-25-2005 at 15:18.
    Epistolary Richard's modding Rules of Cool
    Cool modders make their mods with the :mod command line switch
    If they don't, then Cool mod-users use the Mod Enabler (JSGME)
    Cool modders use show_err
    Cool modders use the tutorials database Cool modders check out the Welcome to the Modding Forums! thread Cool modders keep backups Cool modders help each other out

  4. #4

    Default Re: Destroying buildings - scripting question?

    ^Wow

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Single Sign On provided by vBSSO