Exemple #1
0
 protected static bool assign <T>(ref T thisScript, LayoutScript value, bool created) where T : LayoutScript
 {
     if (typeof(T) == value.GetType())
     {
         thisScript = created ? value as T : null;
         return(true);
     }
     return(false);
 }
 public static void onScriptChanged(LayoutScript script, bool created = true)
 {
     // 只有布局与脚本唯一对应的才能使用变量快速访问
     if (mLayoutManager.getScriptMappingCount(script.GetType()) > 1)
     {
         return;
     }
     if (assign(ref mScriptDemo, script, created))
     {
         return;
     }
     if (assign(ref mScriptDemoStart, script, created))
     {
         return;
     }
 }
Exemple #3
0
 public static void onScriptChanged(LayoutScript script, bool created = true)
 {
     // 只有布局与脚本唯一对应的才能使用变量快速访问
     if (mLayoutManager.getScriptMappingCount(script.GetType()) > 1)
     {
         return;
     }
     //if (assign(ref mScriptObjectEditor, script, created)) return;
     if (assign(ref mScriptSceneEditor, script, created))
     {
         return;
     }
     if (assign(ref mScriptSceneAdvanceEditor, script, created))
     {
         return;
     }
     if (assign(ref mScriptEditorSelect, script, created))
     {
         return;
     }
     if (assign(ref mScriptEffectTextureEditor, script, created))
     {
         return;
     }
     if (assign(ref mScriptEffectSpriteEditor, script, created))
     {
         return;
     }
     if (assign(ref mScriptMonsterSpriteEditor, script, created))
     {
         return;
     }
     if (assign(ref mScriptHumanSpriteEditor, script, created))
     {
         return;
     }
 }
Exemple #4
0
 public static void onScriptChanged(LayoutScript script, bool created = true)
 {
     // 只有布局与脚本唯一对应的才能使用变量快速访问
     if (mLayoutManager.getScriptMappingCount(script.GetType()) > 1)
     {
         return;
     }
     if (assign(ref mScriptGlobalTouch, script, created))
     {
         return;
     }
     if (assign(ref mScriptLogin, script, created))
     {
         return;
     }
     if (assign(ref mScriptRegister, script, created))
     {
         return;
     }
     if (assign(ref mScriptMainFrame, script, created))
     {
         return;
     }
     if (assign(ref mScriptBillboard, script, created))
     {
         return;
     }
     if (assign(ref mScriptCharacter, script, created))
     {
         return;
     }
     if (assign(ref mScriptRoomMenu, script, created))
     {
         return;
     }
     if (assign(ref mScriptMahjongHandIn, script, created))
     {
         return;
     }
     if (assign(ref mScriptMahjongDrop, script, created))
     {
         return;
     }
     if (assign(ref mScriptAllCharacterInfo, script, created))
     {
         return;
     }
     if (assign(ref mScriptDice, script, created))
     {
         return;
     }
     if (assign(ref mScriptMahjongBackFrame, script, created))
     {
         return;
     }
     if (assign(ref mScriptPlayerAction, script, created))
     {
         return;
     }
     if (assign(ref mScriptGameEnding, script, created))
     {
         return;
     }
     if (assign(ref mScriptAddPlayer, script, created))
     {
         return;
     }
     if (assign(ref mScriptMahjongFrame, script, created))
     {
         return;
     }
     if (assign(ref mScriptJoinRoomDialog, script, created))
     {
         return;
     }
     if (assign(ref mScriptMessageOK, script, created))
     {
         return;
     }
     if (assign(ref mScriptMainLoading, script, created))
     {
         return;
     }
     if (assign(ref mScriptMahjongLoading, script, created))
     {
         return;
     }
     if (assign(ref mScriptFreeMatchTip, script, created))
     {
         return;
     }
     if (assign(ref mScriptBackToMainHall, script, created))
     {
         return;
     }
     if (assign(ref mScriptMainFrameBack, script, created))
     {
         return;
     }
     if (assign(ref mScriptRoomList, script, created))
     {
         return;
     }
 }
 public static void onScriptChanged(LayoutScript script, bool created = true)
 {
     // 只有布局与脚本唯一对应的才能使用变量快速访问
     if (mLayoutManager.getScriptMappingCount(script.GetType()) > 1)
     {
         return;
     }
     if (assign(ref mScriptLogo, script, created))
     {
         return;
     }
     if (assign(ref mScriptStartVideo, script, created))
     {
         return;
     }
     if (assign(ref mScriptStandBy, script, created))
     {
         return;
     }
     if (assign(ref mScriptSelectRole, script, created))
     {
         return;
     }
     if (assign(ref mScriptVolumeSetting, script, created))
     {
         return;
     }
     if (assign(ref mScriptButtomPrompt, script, created))
     {
         return;
     }
     if (assign(ref mScriptReturn, script, created))
     {
         return;
     }
     if (assign(ref mScriptSelectTrack, script, created))
     {
         return;
     }
     if (assign(ref mScriptLoading, script, created))
     {
         return;
     }
     if (assign(ref mScriptConfirmSelection, script, created))
     {
         return;
     }
     if (assign(ref mScriptTopTime, script, created))
     {
         return;
     }
     if (assign(ref mScriptTrack, script, created))
     {
         return;
     }
     if (assign(ref mScriptProps, script, created))
     {
         return;
     }
     if (assign(ref mScriptAiming, script, created))
     {
         return;
     }
     if (assign(ref mScriptCountDown, script, created))
     {
         return;
     }
     if (assign(ref mScriptSettlement, script, created))
     {
         return;
     }
     if (assign(ref mScriptCircleTip, script, created))
     {
         return;
     }
     if (assign(ref mScriptPlayerRaceInfo, script, created))
     {
         return;
     }
     if (assign(ref mScriptAttackTip, script, created))
     {
         return;
     }
     if (assign(ref mScriptDebugInfo, script, created))
     {
         return;
     }
     if (assign(ref mScriptGlobalAudio, script, created))
     {
         return;
     }
 }