Results 1 to 6 of 6

Thread: Event Question

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Heathen Storm's Avatar Where's my axe?
    Join Date
    Jun 2010
    Location
    Vinland
    Posts
    2,895

    Default Event Question

    Okay, so for my mod I'm thinking of having an event on the campaign and I was wondering if it was possible.

    Historical Background - In 987 A.D., Prince Vladimir ("The Great") of Kiev was asked to assist Basil II, Emperor of Constantinople, in crushing the two rebel armies marching towards his capital. In return, Vladimir asked to be married to Basil's sister Anna. Basil agreed, on one condition - Vladimir converted to Christianity, and his people with him. Vladimir immediately converted and Christianized his people entirely.

    So my script idea - if one of the pagan factions in my mod asks to marry a christian faction's princess, an event has a chance of popping up asking if said faction would like to "convert" to Christianity.

    Now by convert, I don't mean officially... I mean, they just gain the ability to build a church, which could not work where there are pagan temples, and most if not all family members gain a trait.

    Is this possible? I hope I made it clear enough.

    Proud mod leader, modeller and public relations officer of Heiðinn Veðr: Total War


  2. #2
    Kiliç Alì's Avatar Domesticus
    Artifex

    Join Date
    Feb 2011
    Location
    Italy
    Posts
    2,114

    Default Re: Event Question

    So my script idea - if one of the pagan factions in my mod asks to marry a christian faction's princess, an event has a chance of popping up asking if said faction would like to "convert" to Christianity.
    This is quite easy.
    You make a Christian trait for christian characters.
    The event is a "conversion_proposal" you can accept, right? so

    monitor_event CharacterMarriesPrincess [some conditions]
    and SpouseTrait Christian = 1
    add_events
    event counter conversion_proposal_accepted
    event counter conversion_proposal_declined
    end_add_events
    historic_event converion_proposal true factions [the factions]
    end_monitor

    this is a base, can be futher inproved if you want to be it random, or occur several times excetera.

    Now by convert, I don't mean officially... I mean, they just gain the ability to build a church, which could not work where there are pagan temples, and most if not all family members gain a trait.
    I can't understand what do you want to obtain... sorry, no english speaker...

    Member of the Imperial House of Hader, proud client of The only and sole Ferrit

  3. #3
    lolIsuck's Avatar WE HAVE NO CAKE!
    Patrician Citizen Moderator Emeritus

    Join Date
    Dec 2010
    Location
    Heerlen, Limburg
    Posts
    13,660

    Default Re: Event Question

    I don't really understand what you mean by that either. You said earlier when the prince of Kiev converted so did most of his people so I thought you meant that a big part of the pop will be converted too. The last part confused me, what do you mean by not officially?

  4. #4
    Heathen Storm's Avatar Where's my axe?
    Join Date
    Jun 2010
    Location
    Vinland
    Posts
    2,895

    Default Re: Event Question

    Quote Originally Posted by Kiliç Alì View Post
    I can't understand what do you want to obtain... sorry, no english speaker...
    Quote Originally Posted by lolIsuck View Post
    I don't really understand what you mean by that either. You said earlier when the prince of Kiev converted so did most of his people so I thought you meant that a big part of the pop will be converted too. The last part confused me, what do you mean by not officially?
    Population will be using culture, not religion. I just mean that the faction would still be considered "pagan" in the overview scroll, but they can build a christian church, relations would improve with christian factions etc. So basically what I'm asking is if the faction leader or heir marries a princess, a yes/no event pops up asking if they wish to convert to Christianity, which would unlock a building tree - is that possible?

    Proud mod leader, modeller and public relations officer of Heiðinn Veðr: Total War


  5. #5

    Icon1 Re: Event Question

    Heathen Storm: Yes, that possible. I would suggest, however, doing it so they stop building pagan temples, and start building Christian ones. Both temples would increase the same religion/culture:
    Spoiler Alert, click show to read: 
    campaign_script:
    Code:
    	monitor_event CharacterMarriesPrincess CharFactionType lithuania
    		and Trait Pagan = 1
    		and SpouseTrait Orthodox = 1
    		and I_EventCounter lithuania_convert_orthodox_accepted = 0
    		and RandomPercent <= 25
    		if I_IsFactionAIControlled lithuania
    		set_event_counter lithuania_convert_orthodox_accepted 1
    	end_if
    		if I_LocalFaction lithuania
    		historic_event lithuania_convert_orthodox true factions { lithuania, }
    	end_if
    	end_monitor
    
    	monitor_conditions I_EventCounter lithuania_convert_orthodox_accepted = 1
    		set_event_counter lithuania_orthodox 1
    	terminate_monitor
    	end_monitor
    
    	monitor_conditions I_EventCounter lithuania_convert_orthodox_declined = 1
    		set_event_counter convert_declined 0
    	end_monitor
    
    ;########################## Lithuania Tech Tree #############################
    
    add_events
    	event	counter	lithuania_pagan
    	event	counter	lithuania_orthodox
    	date	0
    end_add_events
    
    set_event_counter lithuania_pagan 1
    set_event_counter lithuania_orthodox 0
    	
    	monitor_event PreFactionTurnStart FactionType lithuania
    		and I_EventCounter lithuania_orthodox = 1
    		set_event_counter lithuania_pagan 0
    	terminate_monitor
    	end_monitor
    export_descr_buildings:

    Pagan Temple:
    Code:
    building pagan_temple
    {
        religion pagan
        levels pagan_standing_stones pagan_tomb pagan_heroes_shrine
        {
            pagan_standing_stones requires factions { lithuania, } and event_counter lithuania_pagan 1
            {
                capability
                {
                    happiness_bonus bonus 1
                    religion_level bonus 2
                }
                material wooden
                construction  2
                cost  1200 
                settlement_min town
                upgrades
                {
                    pagan_tomb
                }
            }
            pagan_tomb requires factions { lithuania, } and event_counter lithuania_pagan 1
            {
                capability
                {
                    happiness_bonus bonus 1
                    religion_level bonus 3
                }
                material wooden
                construction  3
                cost  2500 
                settlement_min large_town
                upgrades
                {
                    pagan_heroes_shrine
                }
            }
            pagan_heroes_shrine requires factions { lithuania, } and event_counter lithuania_pagan 1
            {
                capability
                {
                    happiness_bonus bonus 2
                    religion_level bonus 4
                }
                material wooden
                construction  4
                cost  5000 
                settlement_min city
                upgrades
                {
                }
            }
        }
        plugins 
        {
        }
    }
    Orthodox Temple:
    Code:
    building orthodox_temple
    {
        religion pagan
        levels orthodox_standing_stones orthodox_tomb orthodox_heroes_shrine
        {
            orthodox_standing_stones requires factions { lithuania, } and event_counter lithuania_orthodox 1
            {
                capability
                {
                    happiness_bonus bonus 1
                    religion_level bonus 2
                }
                material wooden
                construction  2
                cost  1200 
                settlement_min town
                upgrades
                {
                    orthodox_tomb
                }
            }
            orthodox_tomb requires factions { lithuania, } and event_counter lithuania_orthodox 1
            {
                capability
                {
                    happiness_bonus bonus 1
                    religion_level bonus 3
                }
                material wooden
                construction  3
                cost  2500 
                settlement_min large_town
                upgrades
                {
                    orthodox_heroes_shrine
                }
            }
            orthodox_heroes_shrine requires factions { lithuania, } and event_counter lithuania_orthodox 1
            {
                capability
                {
                    happiness_bonus bonus 2
                    religion_level bonus 4
                }
                material wooden
                construction  4
                cost  5000 
                settlement_min city
                upgrades
                {
                }
            }
        }
        plugins 
        {
        }
    }

  6. #6
    Heathen Storm's Avatar Where's my axe?
    Join Date
    Jun 2010
    Location
    Vinland
    Posts
    2,895

    Default Re: Event Question

    Quote Originally Posted by TNZ View Post
    Heathen Storm: Yes, that possible. I would suggest, however, doing it so they stop building pagan temples, and start building Christian ones. Both temples would increase the same religion/culture:
    Spoiler Alert, click show to read: 
    campaign_script:
    Code:
    	monitor_event CharacterMarriesPrincess CharFactionType lithuania
    		and Trait Pagan = 1
    		and SpouseTrait Orthodox = 1
    		and I_EventCounter lithuania_convert_orthodox_accepted = 0
    		and RandomPercent <= 25
    		if I_IsFactionAIControlled lithuania
    		set_event_counter lithuania_convert_orthodox_accepted 1
    	end_if
    		if I_LocalFaction lithuania
    		historic_event lithuania_convert_orthodox true factions { lithuania, }
    	end_if
    	end_monitor
    
    	monitor_conditions I_EventCounter lithuania_convert_orthodox_accepted = 1
    		set_event_counter lithuania_orthodox 1
    	terminate_monitor
    	end_monitor
    
    	monitor_conditions I_EventCounter lithuania_convert_orthodox_declined = 1
    		set_event_counter convert_declined 0
    	end_monitor
    
    ;########################## Lithuania Tech Tree #############################
    
    add_events
    	event	counter	lithuania_pagan
    	event	counter	lithuania_orthodox
    	date	0
    end_add_events
    
    set_event_counter lithuania_pagan 1
    set_event_counter lithuania_orthodox 0
    	
    	monitor_event PreFactionTurnStart FactionType lithuania
    		and I_EventCounter lithuania_orthodox = 1
    		set_event_counter lithuania_pagan 0
    	terminate_monitor
    	end_monitor
    export_descr_buildings:

    Pagan Temple:
    Code:
    building pagan_temple
    {
        religion pagan
        levels pagan_standing_stones pagan_tomb pagan_heroes_shrine
        {
            pagan_standing_stones requires factions { lithuania, } and event_counter lithuania_pagan 1
            {
                capability
                {
                    happiness_bonus bonus 1
                    religion_level bonus 2
                }
                material wooden
                construction  2
                cost  1200 
                settlement_min town
                upgrades
                {
                    pagan_tomb
                }
            }
            pagan_tomb requires factions { lithuania, } and event_counter lithuania_pagan 1
            {
                capability
                {
                    happiness_bonus bonus 1
                    religion_level bonus 3
                }
                material wooden
                construction  3
                cost  2500 
                settlement_min large_town
                upgrades
                {
                    pagan_heroes_shrine
                }
            }
            pagan_heroes_shrine requires factions { lithuania, } and event_counter lithuania_pagan 1
            {
                capability
                {
                    happiness_bonus bonus 2
                    religion_level bonus 4
                }
                material wooden
                construction  4
                cost  5000 
                settlement_min city
                upgrades
                {
                }
            }
        }
        plugins 
        {
        }
    }
    Orthodox Temple:
    Code:
    building orthodox_temple
    {
        religion pagan
        levels orthodox_standing_stones orthodox_tomb orthodox_heroes_shrine
        {
            orthodox_standing_stones requires factions { lithuania, } and event_counter lithuania_orthodox 1
            {
                capability
                {
                    happiness_bonus bonus 1
                    religion_level bonus 2
                }
                material wooden
                construction  2
                cost  1200 
                settlement_min town
                upgrades
                {
                    orthodox_tomb
                }
            }
            orthodox_tomb requires factions { lithuania, } and event_counter lithuania_orthodox 1
            {
                capability
                {
                    happiness_bonus bonus 1
                    religion_level bonus 3
                }
                material wooden
                construction  3
                cost  2500 
                settlement_min large_town
                upgrades
                {
                    orthodox_heroes_shrine
                }
            }
            orthodox_heroes_shrine requires factions { lithuania, } and event_counter lithuania_orthodox 1
            {
                capability
                {
                    happiness_bonus bonus 2
                    religion_level bonus 4
                }
                material wooden
                construction  4
                cost  5000 
                settlement_min city
                upgrades
                {
                }
            }
        }
        plugins 
        {
        }
    }
    Sweet, thanks mate!

    Proud mod leader, modeller and public relations officer of Heiðinn Veðr: Total War


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •