Results 1 to 6 of 6

Thread: Simple Script for Kingdoms

  1. #1

    Default Simple Script for Kingdoms

    I have a problem with a simple script for my great campaign (running Kingdoms atm); it's supposed to decimate pop in a settlement at the occurrence of an event called "test". Here's the code:

    monitor_event EventCounter EventCounterType test
    and EventCounter = 1

    console_command add_population Paris -3700
    terminate_monitor
    end_monitor

    Obviously, in descr_events I put:

    event historic test
    date 1

    ...and it pops-up just fine on 1081.

    BUT: the population does not decrease.
    I also tried this version of the script:

    monitor_event EventCounter EventCounterType test
    and EventCounter = 1

    add_population Paris, -3700
    end_monitor

    but nothing changes at all. Any idea? PLEASE

  2. #2
    Bibliophilic Member Atilius's Avatar
    Join Date
    Oct 2005
    Location
    America Medioccidentalis Superior
    Posts
    3,837

    Default Re: Simple Script for Kingdoms

    I think this is what you want:
    Code:
    monitor_event EventCounter I_EventCounter test = 1
        console_command add_population Paris -3700
        terminate_monitor
    end_monitor
    The truth is the most valuable thing we have. Let us economize it. - Mark Twain



  3. #3

    Default Re: Simple Script for Kingdoms

    First of all, thank you for your reply!

    Unfortunately, the code you proposed didn't work.
    And: I definitely don't why - it seemed quite reasonable to me...

    I must say that either "add_population Paris -3700" and "add_population Paris, -3700" do work in the in-game consolle. So what ?!?!?!?

    Maybe it's a matter of version: I'm running Kingdoms, which should be equal to medieval + 1.2 patch.

    PLEASE PLEASE

  4. #4
    Bibliophilic Member Atilius's Avatar
    Join Date
    Oct 2005
    Location
    America Medioccidentalis Superior
    Posts
    3,837

    Default Re: Simple Script for Kingdoms

    Quote Originally Posted by Teia
    Unfortunately, the code you proposed didn't work.
    It works just fine, but it does require you to define the event counter and use "historic_event" in the script.

    I tried the code you posted, added an event to descr_events.txt and it worked for me, so I'm afraid I don't know what the problem is. I'm also running Kingdoms. I'd suggest you look at the log file; that may tell you something.
    The truth is the most valuable thing we have. Let us economize it. - Mark Twain



  5. #5

    Default Re: Simple Script for Kingdoms

    Quote Originally Posted by Atilius
    It works just fine, but it does require you to define the event counter and use "historic_event" in the script.


    If "define the event counter" means declare:

    event historic prova
    date 1


    in the descr_events.txt, I did it. If you mean something else in the script, I ask you to be more explicit, because I'm really confused about this scripting-language
    And where should I use the keyword "historic_event" in the script?

    Thank you again for your kind help!

  6. #6

    Default Re: Simple Script for Kingdoms

    Quote Originally Posted by Atilius
    It works just fine, but it does require you to define the event counter and use "historic_event" in the script.


    If "define the event counter" means declare:

    event historic test
    date 1


    in the descr_events.txt, I did it. If you mean something else in the script, I ask you to be more explicit, because I'm really confused about this scripting-language
    And where should I use the keyword "historic_event" in the script?

    Thank you again for your kind help!

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