The religious conversion used in the teutonic campaign is a bit more complex then that. What you have there in the above is just an event, all it will do is pop an accept/decline scroll, the resulting click on Accept or Decline hasn't been programmed to actually do anything.
This part of the script is the meat of it in terms of the actual conversion, a lot of the rest just handles timers and things which add complexity. I've color coded some of the relevant lines and left a comment line in red below it to explain what the lines are doing.
Code:
monitor_conditions I_EventCounter lithuania_conversion_accepted = 1
;;This counter is set when you click Accept, so the monitor looks for clicking accept and then everything within this monitor fires
;Three easy steps for conversion
;1 - Convert the people
set_religion lithuania catholic
;;Blue = command to change religion, Green = Faction to change it for, Orange = Religion to change it to; this command is the basic religion change, nothing else is technically needed for the religion itself to change.
change_population_religion lithuania catholic 75 pagan
;;Blue = Command to convert a % of the population to the new religion, Green = Faction to affect the change on, Indigo = Religion to convert them into, Cyan = Total % out of 100 to convert, Orange = Religion to take the converted % from
;;So if religious distribution before was Pagan 95%, Orthodox 5%, Catholic 0%, after the above command runs it would be Pagan 20%, Orthodox 5%, Catholic 75%
;2 - Destroy the pagan buildings
destroy_buildings lithuania temple_dievas true
;;Blue = Command to destroy all buildings across faction of specified type, Green = Faction to affect it on, Indigo = The internal name of the building level to be destroyed, Orange = Whether or not to refund the cost of the building to the faction; Same is true for all below
destroy_buildings lithuania temple_dievas_castle true
destroy_buildings lithuania temple_perkunas true
destroy_buildings lithuania temple_perkunas_castle true
destroy_buildings lithuania temple_giltine true
destroy_buildings lithuania temple_giltine_castle true
;3 - Disband the pagan units
retire_characters Lithuania priest
;;Blue = Command to remove all agents of the specified type, Green = Faction to affect it on, Indigo = Agent to affect it on
end_monitor
So you would need to modify all of the above to work for your event name, factions, religions, buildings, agent types, etc. If you're using the americas event a very simple example would be this:
Code:
monitor_event EventCounter EventCounterType america_discovered_accepted
and I_EventCounter america_discovered_accepted == 1
;;Checks the accepted event counter being set to 1 by the player clicking Accept
;set religion conversion counter to be picked up next turn
set_event_counter religious_conversion 1
;reset the event counter so it doesn't keep firing
set_event_counter america_discovered_accepted 0
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and FactionType mayans
and FactionReligion pagan
and I_EventCounter religious_conversion == 1
;;Checks that the faction is mayans, the religious conversion has been accepted, and the current religion is Pagan
;Change religion for mayans
set_religion mayans catholic
;Convert 75% of the populace to new religion
change_population_religion mayans catholic 75 pagan
end_monitor
That's just an example. The above script doesn't destroy religious buildings or retire characters, you'll have to look up which ones you want to destroy. It also only works for the mayans and only if they're currently pagan and converting to catholic. Furthermore, it doesn't define the reasons why they're getting the conversion or the conversion event, so it doesn't factor in an allied religion.
All of these things you need to define for your script, as well as other specific caveats. For instance it currently converts 75% of the population to the new religion, but if it were my script I'd make that much lower since to me the mere fact that the leader says the state religion has changed isn't going to make that high of a percentage forsake the old religion immediately.