Пример #1
0
 private void Awake()
 {
     vars = ManagerVars.GetManageVars();
     EventCenter.AddListener(EventDefine.ShowMainPlane, Show);
     EventCenter.AddListener(EventDefine.ChangeShopImage, ChangeShopImage);
     Init();
 }
Пример #2
0
 private void Awake()
 {
     vars           = ManagerVars.GetManageVars();
     myBody         = GetComponent <Rigidbody2D>();
     spriteRenderer = GetComponent <SpriteRenderer>();
     EventCenter.AddListener <int>(EventDefine.ChangeSkin, ChangeSkin);
 }
Пример #3
0
    private void Awake()
    {
        vars           = ManagerVars.GetManageVars();
        spriteRenderer = GetComponent <SpriteRenderer>();
        int ranValue = Random.Range(0, vars.bgThemeSpriteList.Count);

        spriteRenderer.sprite = vars.bgThemeSpriteList[ranValue];
    }
Пример #4
0
 /// <summary>
 /// 初始化
 /// </summary>
 public void Awake()
 {
     vars     = ManagerVars.GetManageVars();
     Instance = this;
     EventCenter.AddListener(EventDefine.AddDimond, AddDimond);
     EventCenter.AddListener(EventDefine.AddGameScore, AddGameScore);
     EventCenter.AddListener(EventDefine.PlayerMove, PlayerMove);
     InitGameData();
 }
Пример #5
0
    private bool isSpawnSpike = false;      //是否生成钉子

    private void Awake()
    {
        vars = ManagerVars.GetManageVars();
        EventCenter.AddListener(EventDefine.DecidePath, DecidePath);
    }
Пример #6
0
 private void Awake()
 {
     vars = ManagerVars.GetManageVars();
     EventCenter.AddListener(EventDefine.PlayAudio, PlayAudio);
 }
Пример #7
0
 private void Awake()
 {
     Instance = this;
     vars     = ManagerVars.GetManageVars();
     Init();
 }
Пример #8
0
 private void Awake()
 {
     EventCenter.AddListener(EventDefine.ShowShopPlane, Show);
     vars = ManagerVars.GetManageVars();
 }