Jump to content

event only partially works


joemann

Recommended Posts

I am trying to get a narrative event to work ( a variation on the KSV mod) I have been trying for hours but it seems like I'm going one step ahead for two backwards. Could somebody please give me a tip.

 

The event code is as follows:

 

# Break-in Slave
narrative_event = {
    id = rsl.3
    desc = rsl3desc
    picture = GFX_evt_rsl.rapeoptions

    is_triggered_only = yes

    option ={
        trigger = {
            FROM = {
                Not = { trait = broken_in }
                Not = { trait = broken }
            }
        }
        name = "rsl3a"        
        random_list = {
                90 = {     #success
                    character_event = { id = rsl.31 }
                    FROM = {
                        spouse = { prestige = -15 }
                        add_trait = broken_in
                        opinion = {
                            who = ROOT
                            modifier = rsl_opinion_slave_master
                            years = 10
                        }
                    }
                }
                10 = {    #fail
                    character_event = { id = rsl.313 }
                    FROM = { add_trait = broken }
                }            
        
            }
            

# Obedience training 10
narrative_event = {
    id = rsl.31
    desc = rsl31desc
    picture = GFX_evt_rsl.trainobediance1

    is_triggered_only = yes

    option = {
        name = rsl_option_further
        character_event = { id = rsl.311 }
    }
}
# Obedience training 113 broken
narrative_event = {
    id = rsl.313
    desc = rsl311desc
    picture = GFX_evt_rsl.broken

    is_triggered_only = yes

    option = {
        name = rsl_option2
    }
}
# Obedience training 11
narrative_event = {
    id = rsl.311
    desc = rsl311desc
    picture = GFX_evt_rsl.trainobediance2

    is_triggered_only = yes

    option = {
        name = rsl_option_further
        character_event = { id = rsl.312 }
    }
}
# Obedience training 12
narrative_event = {
    id = rsl.312
    desc = rsl312desc
    picture = GFX_evt_rsl.trainobediance3

    is_triggered_only = yes

    option = {
        name = rsl_option1
            }
        }
    }
}

 

When I trigger the decision in the diplomacy menu ( right mouse-click on targeted slave) the narrative picture does not open on the screen. However, a trait icon is added to the slave ( broken_in or broken depending on the outcome of the random test which apparently is fired). Then every two weeks the narrative picture fires  but only with the first picture not all the other options.

 

I suppose it's a parsing error but I can't work out which one. Validator is no help , it complains about the first FROM but is not clear about the issue. Anyhow, the traits seem to be correctly applied.

 

Does anybody spot the error(s);

 

Your help is much appreciated!

 

Link to comment
52 minutes ago, joemann said:

You mean just above obedience training 10 ?

 

Problem is I have tried so many different combinations, that I forget which ones I have already tried :frown:

Try this:

 


narrative_event = {
    id = rsl.3
    desc = rsl3desc
    picture = GFX_evt_rsl.rapeoptions

    is_triggered_only = yes

    option ={
        trigger = {
            FROM = {
                Not = { trait = broken_in }
                Not = { trait = broken }
            }
        }
        name = "rsl3a"        
        random_list = {
            90 = {     #success
                character_event = { id = rsl.31 }
                FROM = {
                    spouse = { prestige = -15 }
                    add_trait = broken_in
                    opinion = {
                        who = ROOT
                        modifier = rsl_opinion_slave_master
                        years = 10
                    }
                }
            }
            10 = {    #fail
                character_event = { id = rsl.313 }
                FROM = { add_trait = broken }
            }
        }
    }
}
# Obedience training 10
narrative_event = {
    id = rsl.31
    desc = rsl31desc
    picture = GFX_evt_rsl.trainobediance1

    is_triggered_only = yes

    option = {
        name = rsl_option_further
        character_event = { id = rsl.311 }
    }
}
# Obedience training 113 broken
narrative_event = {
    id = rsl.313
    desc = rsl311desc
    picture = GFX_evt_rsl.broken

    is_triggered_only = yes

    option = {
        name = rsl_option2
    }
}
# Obedience training 11
narrative_event = {
    id = rsl.311
    desc = rsl311desc
    picture = GFX_evt_rsl.trainobediance2

    is_triggered_only = yes

    option = {
        name = rsl_option_further
        character_event = { id = rsl.312 }
    }
}
# Obedience training 12
narrative_event = {
    id = rsl.312
    desc = rsl312desc
    picture = GFX_evt_rsl.trainobediance3

    is_triggered_only = yes

    option = {
        name = rsl_option1
    }
}

Link to comment

I tried this but it works only partially. It works in the sense that the slave gets the trait broken_in, but nothing appears on screen. The appearance of the first event picture every two weeks has gone.

 

I'll check all the lines again for errors.

 

Thx for your help!

Link to comment

I can't find a solution. Is it a trigger problem ?

 

 In my understanding, the first < is_triggered_only >  indicates that the narrative event  including the picture and the description  is fired by the targeted decision. Picture and description do not appear. But the the random list is executed and as a result a trait is added .

Does the <trigger> in the option fire the random list ?

 

Finally, I would like the outcome of the random list not just to trigger the adding of a trait but to also fire the narrative events depending on the outcome of the random list. However there seems to be no connection between the first part of the script which end with four brackets and the following events.

 

I am completely lost :smile:

 

I'll see if the modding wiki can help. If anybody has a solution ?

 

Link to comment

I run it all the time. I often don't understand what it means  ;)

For example, for this event I only get 4 of these;

--- Error 1 of 1 ---
At <mod>\events\RSLBreak-inSlave.txt [narrative_event] (Line 44, column 1):
This narrative event must have a title

 

However, my mod contains lots of events where I get the same error but which run perfectly well

 

I'll try putting in a title but where does it come from?

 

Link to comment

I ran the event in the console command, using both the testevent and the event command, and it works. Since these commands ignore ( replace ? ) the trigger, my problem must be a trigger problem.

 

I understand that <is_triggered_only = yes> is not itself a trigger but a flag. I suppose it refers to the block that follows rather than to the preceding block.

 

The following block is triggered (by the random list ?), the outcome of the random list is applied.

 

None of the narrative screens show up. The first one should be triggered by the decision ( in right mouse click on slave menu)

 

The narratives events after the random list should be triggered by the random list just as  the adding of traits is.

 

What am i getting wrong?:classic_unsure:

Link to comment

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more information, see our Privacy Policy & Terms of Use