<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://www.wlabsocks.com/wiki/index.php?action=history&amp;feed=atom&amp;title=OnClanCultureChanged</id>
	<title>OnClanCultureChanged - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://www.wlabsocks.com/wiki/index.php?action=history&amp;feed=atom&amp;title=OnClanCultureChanged"/>
	<link rel="alternate" type="text/html" href="http://www.wlabsocks.com/wiki/index.php?title=OnClanCultureChanged&amp;action=history"/>
	<updated>2026-05-12T22:56:24Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.5</generator>
	<entry>
		<id>http://www.wlabsocks.com/wiki/index.php?title=OnClanCultureChanged&amp;diff=926&amp;oldid=prev</id>
		<title>Tayfunwiki: Created page with &quot;== &lt;code&gt;onClanCultureChanged&lt;/code&gt; Event in Clan Class ==  === Overview === The &lt;code&gt;onClanCultureChanged&lt;/code&gt; event in the Clan class is activated when there is a change in the clan's cultural background. This event is crucial for adapting to and reflecting changes in the clan's cultural identity within the game's world.  === Event Definition === &lt;syntaxhighlight lang=&quot;c#&quot;&gt; public event Action&lt;Culture&gt; onClanCultureChanged; &lt;/syntaxhighlight&gt;  === Description ===...&quot;</title>
		<link rel="alternate" type="text/html" href="http://www.wlabsocks.com/wiki/index.php?title=OnClanCultureChanged&amp;diff=926&amp;oldid=prev"/>
		<updated>2024-01-05T00:33:15Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;== &amp;lt;code&amp;gt;onClanCultureChanged&amp;lt;/code&amp;gt; Event in Clan Class ==  === Overview === The &amp;lt;code&amp;gt;onClanCultureChanged&amp;lt;/code&amp;gt; event in the Clan class is activated when there is a change in the clan&amp;#039;s cultural background. This event is crucial for adapting to and reflecting changes in the clan&amp;#039;s cultural identity within the game&amp;#039;s world.  === Event Definition === &amp;lt;syntaxhighlight lang=&amp;quot;c#&amp;quot;&amp;gt; public event Action&amp;lt;Culture&amp;gt; onClanCultureChanged; &amp;lt;/syntaxhighlight&amp;gt;  === Description ===...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== &amp;lt;code&amp;gt;onClanCultureChanged&amp;lt;/code&amp;gt; Event in Clan Class ==&lt;br /&gt;
&lt;br /&gt;
=== Overview ===&lt;br /&gt;
The &amp;lt;code&amp;gt;onClanCultureChanged&amp;lt;/code&amp;gt; event in the Clan class is activated when there is a change in the clan's cultural background. This event is crucial for adapting to and reflecting changes in the clan's cultural identity within the game's world.&lt;br /&gt;
&lt;br /&gt;
=== Event Definition ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;c#&amp;quot;&amp;gt;&lt;br /&gt;
public event Action&amp;lt;Culture&amp;gt; onClanCultureChanged;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Description ===&lt;br /&gt;
&lt;br /&gt;
* Delegate Type: &amp;lt;code&amp;gt;Action&amp;lt;Culture&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
* Purpose: Notifies when the clan's culture has been changed.&lt;br /&gt;
* Parameters:&lt;br /&gt;
** &amp;lt;code&amp;gt;Culture&amp;lt;/code&amp;gt;: The previous culture of the clan before the change.&lt;br /&gt;
&lt;br /&gt;
=== Functionality ===&lt;br /&gt;
&lt;br /&gt;
* The &amp;lt;code&amp;gt;onClanCultureChanged&amp;lt;/code&amp;gt; event is raised when the clan adopts a new cultural background.&lt;br /&gt;
* It provides the previous &amp;lt;code&amp;gt;Culture&amp;lt;/code&amp;gt; object as a parameter, enabling a comparison between the old and new cultures.&lt;br /&gt;
* This event allows various game elements, such as narrative scripts, clan behavior, and user interface, to respond dynamically to changes in the clan's culture.&lt;br /&gt;
&lt;br /&gt;
=== Usage ===&lt;br /&gt;
This event is particularly useful in scenarios where the cultural identity of a clan influences gameplay mechanics, storylines, or player interactions. It can be used to trigger updates or actions that align with the clan's new cultural characteristics.&lt;br /&gt;
&lt;br /&gt;
=== Example of Usage ===&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;c#&amp;quot;&amp;gt;&lt;br /&gt;
public class ClanCultureChangeHandler : MonoBehaviour {&lt;br /&gt;
    void Start() {&lt;br /&gt;
        Clan playerClan = IM.Player.Clan;&lt;br /&gt;
        if (playerClan != null) {&lt;br /&gt;
            playerClan.onClanCultureChanged += HandleClanCultureChange;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    private void HandleClanCultureChange(Culture oldCulture) {&lt;br /&gt;
        Debug.Log($&amp;quot;The player's clan culture has changed from {oldCulture.CultureName}. New Culture: {IM.player.Clan.CultureName}&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    void OnDestroy() {&lt;br /&gt;
        if (IM.Player.Clan != null) {&lt;br /&gt;
            IM.Player.Clan.onClanCultureChanged -= HandleClanCultureChange;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Description ====&lt;br /&gt;
&lt;br /&gt;
* This example shows subscribing to the &amp;lt;code&amp;gt;onClanCultureChanged&amp;lt;/code&amp;gt; event for the player's clan.&lt;br /&gt;
* When the clan's culture changes, the &amp;lt;code&amp;gt;HandleClanCultureChange&amp;lt;/code&amp;gt; method is called, logging the old culture's name.&lt;br /&gt;
* It also ensures to unsubscribe from the event upon the destruction of the GameObject to prevent memory leaks or unintended behavior.&lt;br /&gt;
&lt;br /&gt;
=== Remarks ===&lt;br /&gt;
&lt;br /&gt;
* The &amp;lt;code&amp;gt;onClanCultureChanged&amp;lt;/code&amp;gt; event is vital for maintaining narrative consistency and gameplay relevance when a clan undergoes cultural changes.&lt;br /&gt;
* It provides a mechanism for developers to create dynamic gameplay and storytelling that adapts to the evolving cultural identities of clans.&lt;br /&gt;
* Effective handling of this event is essential for enhancing the player's immersion and interaction with the game's social and cultural dynamics.&lt;/div&gt;</summary>
		<author><name>Tayfunwiki</name></author>
	</entry>
</feed>