예제 #1
0
    private void AjustaZonaPassLevel()
    {
        NGUIDebug.Clear();
        float ajuste_zona = 0f;

        if (zona == PlayerState.LOW)
        {
            Debug.Log("zonaL");
            NGUIDebug.Log("zl");
            ajuste_zona = 1.5f;
        }
        else if (zona == PlayerState.NORMAL)
        {
            Debug.Log("zonaN");
            NGUIDebug.Log("zn");
            ajuste_zona = 1f;
        }
        else   //(zona == PlayerState.HIGH)
        {
            Debug.Log("zonaH");
            NGUIDebug.Log("zh");
            ajuste_zona = 0.5f;
        }

        NGUIDebug.Log((ajuste_zona) + "35470" + DataCenter.instance.velMinInicial + "0" + asteroidSpeed);
        asteroidSpeed += (ajuste_zona);
    }
예제 #2
0
    public void AjustaExcitacaoPassLevel()
    {
        NGUIDebug.Clear();

        float ajuste_ext = 0f;

        if (excitacao == PlayerState.HIGH)
        {
            Debug.Log("extH");
            NGUIDebug.Log("eh");
            ajuste_ext = 0f;
        }
        else if (excitacao == PlayerState.NORMAL)
        {
            Debug.Log("extN");
            NGUIDebug.Log("en");
            ajuste_ext = 0.5f;
        }
        else if (excitacao == PlayerState.LOW)
        {
            Debug.Log("extL");
            NGUIDebug.Log("el");
            ajuste_ext = 1f;
        }
        else   //excitacao == NULL
        {
            Debug.Log("Warning: excitacao == Null (AjustaExcitacao)");
            NGUIDebug.Log("e-");
            ajuste_ext = 0.5f;
        }

        float ajuste_zona = 0f;

        if (zona == PlayerState.LOW)
        {
            Debug.Log("zonaL");
            NGUIDebug.Log("zl");
            ajuste_zona = 1f;
        }
        else if (zona == PlayerState.NORMAL)
        {
            Debug.Log("zonaN");
            NGUIDebug.Log("zn");
            ajuste_zona = 0.5f;
        }
        else   //(zona == PlayerState.HIGH)
        {
            Debug.Log("zonaH");
            NGUIDebug.Log("zh");
            ajuste_zona = 0f;
        }

        Debug.Log("Ajuste pass nivel: " + (ajuste_ext + ajuste_zona) + " vel inicial: " + DataCenter.instance.velMinInicial + " vel final: " + asteroidSpeed);
        NGUIDebug.Log((ajuste_ext + ajuste_zona) + "35470" + DataCenter.instance.velMinInicial + "0" + asteroidSpeed);

        asteroidSpeed += (ajuste_ext + ajuste_zona);
    }
예제 #3
0
    private void AjustaDesempenhoPassLevel()
    {
        NGUIDebug.Clear();

        float ajuste_des = 0f;

        if (desempenho == PlayerState.LOW)
        {
            Debug.Log("desL");
            NGUIDebug.Log("dl");
            ajuste_des = 0f;
        }
        else if (desempenho == PlayerState.NORMAL)
        {
            Debug.Log("desN");
            NGUIDebug.Log("dn");
            ajuste_des = 0.5f;
        }
        else if (desempenho == PlayerState.HIGH)
        {
            Debug.Log("desH");
            NGUIDebug.Log("dh");
            ajuste_des = 1f;
        }
        else   //desempenho == NULL
        {
            Debug.Log("Warning: Desempenho == Null (AjustaDesempenho)");
            NGUIDebug.Log("d-");
            ajuste_des = 0.5f;
        }

        float ajuste_zona = 0f;

        if (zona == PlayerState.LOW)
        {
            Debug.Log("zonaL");
            NGUIDebug.Log("zl");
            ajuste_zona = 1f;
        }
        else if (zona == PlayerState.NORMAL)
        {
            Debug.Log("zonaN");
            NGUIDebug.Log("zn");
            ajuste_zona = 0.5f;
        }
        else   //(zona == PlayerState.HIGH)
        {
            Debug.Log("zonaH");
            NGUIDebug.Log("zh");
            ajuste_zona = 0f;
        }

        Debug.Log("Ajuste pass nivel: " + (ajuste_des + ajuste_zona) + " vel inicial: " + DataCenter.instance.velMinInicial + " vel final: " + asteroidSpeed);
        NGUIDebug.Log((ajuste_des + ajuste_zona) + "35470" + DataCenter.instance.velMinInicial + "0" + asteroidSpeed);
        asteroidSpeed += (ajuste_des + ajuste_zona);
    }
예제 #4
0
 static public int Clear_s(IntPtr l)
 {
     try {
         NGUIDebug.Clear();
         pushValue(l, true);
         return(1);
     }
     catch (Exception e) {
         return(error(l, e));
     }
 }
예제 #5
0
    private void SetTextDesExtZon()
    {
        DDAAply inst = DDAAply.instance;
        string  desempenho, excitacao, zona;


        if (inst.desempenho == State.PlayerState.HIGH)
        {
            desempenho = "h";
        }
        else if (inst.desempenho == State.PlayerState.NORMAL)
        {
            desempenho = "n";
        }
        else if (inst.desempenho == State.PlayerState.LOW)
        {
            desempenho = "l";
        }
        else
        {
            desempenho = "-";
        }

        if (inst.excitacao == State.PlayerState.HIGH)
        {
            excitacao = "h";
        }
        else if (inst.excitacao == State.PlayerState.NORMAL)
        {
            excitacao = "n";
        }
        else if (inst.excitacao == State.PlayerState.LOW)
        {
            excitacao = "l";
        }
        else
        {
            excitacao = "-";
        }

        if (inst.zona == State.PlayerState.HIGH)
        {
            zona = "h";
        }
        else if (inst.zona == State.PlayerState.NORMAL)
        {
            zona = "n";
        }
        else if (inst.zona == State.PlayerState.LOW)
        {
            zona = "l";
        }
        else
        {
            zona = "-";
        }

        if (inst.IsDesempenho)
        {
            if (DataCenter.instance.numberOfLevelDeaths == 1)
            {
                NGUIDebug.Clear(); //o afetivo ja faz o clear antes
                NGUIDebug.Log("d" + desempenho + "z" + zona);
            }
        }
        else if (inst.IsAfetivo)
        {
            if (DataCenter.instance.numberOfLevelDeaths == 1)
            {
                NGUIDebug.Log("e" + excitacao + "z" + zona);
            }
        }
        else if (inst.IsZona)
        {
            if (DataCenter.instance.numberOfLevelDeaths == 1)
            {
                NGUIDebug.Clear(); //o afetivo ja faz o clear antes
                NGUIDebug.Log("z" + zona);
            }
        }

        TextEnable.SetHiperspaceText("Pressione Espaço");
        flagAuxBugFixGambiarra = false;
    }
예제 #6
0
 static int Clear(IntPtr L)
 {
     LuaScriptMgr.CheckArgsCount(L, 0);
     NGUIDebug.Clear();
     return(0);
 }
예제 #7
0
	private void FF9FieldMapMain(Int32 MapNo)
	{
		EBin eBin = this.ee.eBin;
		Int32 varManually = eBin.getVarManually(6357);
		if ((this.FF9.attr & 256u) == 0u)
		{
			if (!MBG.IsNull)
			{
				Singleton<fldfmv>.Instance.ff9fieldFMVService();
			}
			if ((this.FF9.attr & 2u) == 0u)
			{
				Int32 varManually2 = eBin.getVarManually(6357);
				if (varManually2 != this.prevPrg)
				{
					this.prevPrg = varManually2;
					if (varManually2 != 1 || this.FF9.fldMapNo != 50)
					{
						if (this.FF9.fldMapNo != 150 || varManually2 != 5)
						{
							if (this.FF9.fldMapNo != 404)
							{
								if (this.FF9.fldMapNo == 404)
								{
								}
							}
						}
					}
				}
				Int32 num = this.ee.ServiceEvents();
				HonoluluFieldMain.eventEngineRunningCount++;
				this.updatePlayerObj();
				switch (num)
				{
				case 3:
					this.FF9Sys.attr |= 8u;
					this.FF9FieldMap.nextMode = 2;
					this.fieldmap.ff9fieldInternalBattleEncountStart();
					this.ee.BackupPosObjData();
					FF9StateSystem.Battle.isDebug = false;
					FF9StateSystem.Battle.mappingBattleIDWithMapList = false;
					NGUIDebug.Clear();
					break;
				case 4:
					if (this.FF9FieldMap.nextMapNo == 16000)
					{
						this.FF9FieldMap.nextMode = 4;
						this.FF9Sys.attr |= 2u;
					}
					else
					{
						this.FF9FieldMap.nextMode = 1;
						this.FF9Sys.attr |= 8u;
					}
					break;
				case 5:
					this.FF9FieldMap.nextMode = 3;
					this.FF9Sys.attr |= 2u;
					break;
				case 7:
					this.FF9FieldMap.nextMode = 9;
					this.FF9Sys.attr |= 2u;
					break;
				case 8:
					this.FF9FieldMap.nextMode = 7;
					this.FF9Sys.attr |= 2u;
					this.FF9.attr |= 2u;
					PersistenSingleton<EventEngine>.Instance.eTb.InitMessage();
					PersistenSingleton<UIManager>.Instance.SetMenuControlEnable(false);
					this.shutdownField();
					EventService.OpenGameOver();
					break;
				}
			}
			if ((this.FF9.attr & 4u) == 0u && this.fieldmap != (UnityEngine.Object)null)
			{
				this.fieldmap.ff9fieldCharService();
			}
			if ((this.FF9.attr & 8u) == 0u && FF9StateSystem.Common.FF9.fldMapNo != 70 && this.fieldmap.walkMesh != null)
			{
				this.fieldmap.walkMesh.BGI_simService();
			}
			if ((this.FF9Field.attr & 16u) == 0u)
			{
				vib.VIB_service();
			}
			if ((this.FF9Field.attr & 8u) == 0u)
			{
				this.fieldmap.rainRenderer.ServiceRain();
			}
			Boolean flag = !MBG.IsNull && MBG.Instance.isFMV55D;
			if ((this.FF9Field.attr & 2048u) == 0u || flag)
			{
				SceneDirector.ServiceFade();
			}
			if ((this.FF9Field.attr & 4u) == 0u)
			{
				this.fieldmap.ff9fieldInternalBattleEncountService();
			}
		}
		this.ff9fieldInternalLoopEnd();
		UInt32 num2 = this.FF9Sys.attr & 15u;
		if (num2 != 0u)
		{
			if (this.ff9fieldDiscCondition())
			{
				this.FF9FieldMap.nextMode = 1;
				this.FF9FieldMap.nextMapNo = (Int16)PersistenSingleton<EventEngine>.Instance.GetFldMapNoAfterChangeDisc();
			}
			this.shutdownField();
			switch (this.FF9FieldMap.nextMode)
			{
			case 1:
				SceneDirector.Replace("FieldMap", SceneTransition.FadeOutToBlack_FadeIn, false);
				break;
			case 2:
				if (FF9StateSystem.Common.FF9.fldMapNo == 1663)
				{
					Int32 varManually3 = PersistenSingleton<EventEngine>.Instance.eBin.getVarManually(EBin.SC_COUNTER_SVR);
					Int32 varManually4 = PersistenSingleton<EventEngine>.Instance.eBin.getVarManually(EBin.MAP_INDEX_SVR);
					if (varManually3 == 6950 && varManually4 == 40)
					{
						global::Debug.Log("Force close all dialog for <SQEX> #3105");
						PersistenSingleton<UIManager>.Instance.Dialogs.CloseAll();
					}
				}
				SFX_Rush.SetCenterPosition(0);
				SceneDirector.Replace("BattleMap", SceneTransition.SwirlInBlack, true);
				break;
			case 3:
				SceneDirector.Replace("WorldMap", SceneTransition.FadeOutToBlack_FadeIn, false);
				break;
			case 4:
				SceneDirector.Replace("Ending", SceneTransition.FadeOutToBlack_FadeIn, false);
				break;
			case 9:
				SceneDirector.Replace("QuadMist", SceneTransition.FadeOutToBlack_FadeIn, true);
				break;
			}
		}
	}
예제 #8
0
    // lê todos os números maiores que id
    //vou usar essa. o id vou salvar antes.
    //se calcularExcitacao for true, calcula a excitacao. Se for false, apenas le os dados (usado para descartar os dados do questionario)
    IEnumerator GetReadBigger(bool calcularExcitacao)
    {
        Debug.Log("Entrou no GetReadBigger com id==" + ultimo_id_lido);
        using (UnityWebRequest www = UnityWebRequest.Get("http://localhost/android_connect/read_bigger.php" + "?id=" + ultimo_id_lido)) {
            www.SetRequestHeader("Content-Type", "application/json");
            yield return(www.SendWebRequest());

            if ((www.isNetworkError || www.isHttpError))
            {
                NGUIDebug.Log("Erro de conecção");
                Debug.Log("Erro de conecção");
                Debug.Log(www.error);
            }
            else
            {
                string jsonString = www.downloadHandler.text;
                System.Threading.Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("en-US"); //para converter os Doubles considerando '.' e nao ','
                sinais = JsonUtility.FromJson <EDASignals>(jsonString);
                if (sinais.eda.Count > 0)
                {
                    ultimo_id_lido = sinais.eda[sinais.eda.Count - 1].id;
                }
                else
                {
                    ultimo_id_lido = 0; //caso dê clear no banco de dados no meio da partida
                }

                NGUIDebug.Clear();
                if (calcularExcitacao)
                {
                    NGUIDebug.Log(sinais.eda.Count + "lid");
                    Debug.Log(sinais.eda.Count + " sinais lidos");
                }
                else
                {
                    NGUIDebug.Log(sinais.eda.Count + "desc");
                    Debug.Log(sinais.eda.Count + " sinais descartados");
                }
                if (calcularExcitacao)
                {
                    picos.Clear();
                    CalculaPicos(); //pontos máximos e minimos relativos
                    NGUIDebug.Log(picos.Count + "pic");
                    Debug.Log(picos.Count + " picos achados");
                    if (picos.Count > 1)
                    {
                        CaclulaExcitacao();
                    }
                    else if (sinais.eda.Count > 0)
                    {
                        Debug.Log("Warning: Excitação: NORMAL (picos.Count <= 0");
                        DDAAply.instance.excitacao = State.PlayerState.NORMAL; //normal pq temos poucos sinais, entao pouca variacao
                    }
                    else
                    {
                        Debug.Log("Warning: Excitação: NULL (sinais.eda.Count <= 0");
                        DDAAply.instance.excitacao = State.PlayerState.NULL; //null pq nao temos nenhum sinal
                    }
                    DDAAply.instance.AjustaExcitacaoPassLevel();
                }
            }
        }
        calculandoExcitacao = false;
    }
예제 #9
0
 public unsafe static long $Invoke0(long instance, long *args)
 {
     NGUIDebug.Clear();
     return(-1L);
 }