using UnityEngine;
using UnityEngine.UI;
using System.Collections;
publicclass StartView : MonoBehaviour {
public Button Btn_Start { get; set; }
public Button Btn_ReStart { get; set; }
public Button Btn_Set { get; set; }
public Button Btn_Rank { get; set; }
public Text Txt_Title { get; set; }
// Use this for initializationvoid Awake() {
Btn_Start = transform.Find("ButtonGroup/btn_Start").GetComponent
StartView脚本
using UnityEngine;
using UnityEngine.UI;
using System.Collections;
publicclass RunView : MonoBehaviour {
public Button Btn_Pause { get; set; }
public Text Txt_Curr { get; set; }
public Text Txt_Max { get; set; }
// Use this for initializationvoid Awake() {
Btn_Pause = transform.Find("TopGroup/btn_Pasue").GetComponent();
Txt_Curr = transform.Find("TopGroup/txt_Current/Text").GetComponent();
Txt_Max = transform.Find("TopGroup/txt_Max/Text").GetComponent();
}
publicvoid SetScoreText(int curr,int max) {
Txt_Curr.text = curr.ToString();
Txt_Max.text = max.ToString();
}
publicvoid SetScoreText(string curr, string max)
{
Txt_Curr.text = curr;
Txt_Max.text = max;
}
}
RunView脚本
using UnityEngine;
using UnityEngine.UI;
using System.Collections;
publicclass SetView : MonoBehaviour {
public Button Btn_Forum { get; set; }
public Button Btn_WebSite { get; set; }
public Button Btn_Collect { get; set; }
public Button Btn_Sound { get; set; }
public Button Btn_Return { get; set; }
public GameObject mask { get; set; }
// Use this for initializationvoid Awake() {
Btn_Forum = transform.Find("Img_Bg/Btn_Forum").GetComponent();
Btn_WebSite = transform.Find("Img_Bg/Btn_WebSite").GetComponent();
Btn_Collect = transform.Find("Img_Bg/Btn_Collect").GetComponent();
Btn_Sound = transform.Find("Img_Bg/Btn_Sound").GetComponent();
mask = Btn_Sound.transform.Find("Mask").gameObject;
Btn_Return = GetComponent();
}
publicvoid SetSoundMask(bool isActive)
{
mask.SetActive(isActive);
}
publicvoid SetSoundMask() {
mask.SetActive(!mask.activeSelf);
GameManager.instance.Sound = mask.activeSelf;
AudioManager.instance.SetAudioSource(!mask.activeSelf);
}
}
SetView脚本
using UnityEngine;
using UnityEngine.UI;
using System.Collections;
publicclass RankView : MonoBehaviour {
public Button Btn_Clear { get; set; }
public Button Btn_Return { get; set; }
public Text Txt_Curr { get; set; }
public Text Txt_Max { get; set; }
public Text Txt_Count { get; set; }
// Use this for initializationvoid Awake() {
Btn_Clear = transform.Find("Img_Bg/Btn_Clear").GetComponent();
Txt_Curr = transform.Find("Img_Bg/Txt_Name").GetComponent();
Txt_Max = transform.Find("Img_Bg/Txt_Max/Text").GetComponent();
Txt_Count = transform.Find("Img_Bg/Txt_Count/Text").GetComponent();
Btn_Return = GetComponent();
}
void Start()
{
SetScoreText();
}
publicvoid TextClearData() {
Txt_Max.text = 0.ToString();
Txt_Count.text = 0.ToString();
GameManager.instance.Score = 0;
GameManager.instance.highScore = 0;
GameManager.instance.numbersGame = 0;
}
publicvoid SetScoreText() {
Txt_Max.text = GameManager.instance.highScore.ToString();
Txt_Count.text = GameManager.instance.numbersGame.ToString();
}
}
RankView脚本
using UnityEngine;
using System.Collections;
using UnityEngine.UI;
publicclass PasueView : MonoBehaviour {
public Button Btn_Home { get; set; }
public Button Btn_Start { get; set; }
public Text Txt_Curr { get; set; }
// Use this for initializationvoid Awake()
{
Btn_Home = transform.Find("Img_Bg/Btn_Home").GetComponent();
Btn_Start = transform.Find("Img_Bg/Btn_Start").GetComponent();
Txt_Curr = transform.Find("Img_Bg/Txt_Count").GetComponent();
}
}
PasueView脚本
using UnityEngine;
using UnityEngine.UI;
using System.Collections;
publicclass OverView : MonoBehaviour {
public Button Btn_Home { get; set; }
public Button Btn_ReStart { get; set; }
public Text Txt_Curr { get; set; }
// Use this for initializationvoid Awake () {
Btn_Home = transform.Find("Img_Bg/Btn_Home").GetComponent();
Btn_ReStart = transform.Find("Img_Bg/Btn_ReStart").GetComponent();
Txt_Curr = transform.Find("Img_Bg/Txt_Count").GetComponent();
}
publicvoid SetScoreText(int score) {
Txt_Curr.text = score.ToString();
}
}
CMS概述
并发标记清理垃圾回收(Concurrent Mark and Sweep GC)算法的主要目标是在GC过程中,减少暂停用户线程的次数以及在不得不暂停用户线程的请夸功能,尽可能短的暂停用户线程的时间。这对于交互式应用,比如web应用来说,是非常重要的。
CMS垃圾回收针对新生代和老年代采用不同的策略。相比同吞吐量垃圾回收,它要复杂的多。吞吐量垃圾回收在执
1,找到配置文件
vi /etc/sysconfig/iptables
2,添加端口开放,增加一行,开放18081端口
-A INPUT -m state --state NEW -m tcp -p tcp --dport 18081 -j ACCEPT
3,保存
ESC
:wq!
4,重启服务
service iptables
使用Android SDK Manager 更新了Anadroid SDK Tooks 之后,
打开eclipse提示 This Android SDK requires Android Developer Toolkit version 23.0.0 or above, 点击Check for Updates
检测一会后提示 No update were found