SA-MP Forums Archive
[Ajuda] Бrea quadrada - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Бrea quadrada (/showthread.php?tid=648425)



Бrea quadrada - B4dSh33p - 21.01.2018

Alguйm me ajude nгo sei oque pode estб errado no meu cуdigo de algum jeito nгo consigo retornar 1.

PHP код:
new Valor 0;
printf("%f %f %f",X,Y,Z);
if(
267.436309 && > -1610.369262 && 275.307769 && < -1621.699218 && 50.445312 && 46.000000)
{
    
Valor 1;
}
return 
Valor;
//Print dos resultados que estou tendo. 270.324279 -1615.445800 46.020000 



Re: Бrea quadrada - Dayvison_ - 21.01.2018

PHP код:
main()
{
    new
        
Float:270.324279,
        
Float:= -1615.445800,
        
Float:46.020000
    
;
    
printf("0-%d", (267.436309 && 275.307769));
    
printf("1-%d", (< -1610.369262 && > -1621.699218));
    
printf("2-%d", (46.000000 && 50.445312));
    
printf("3-%d", (267.436309));
    
printf("4-%d", (275.307769));
    
printf("5-%d", (< -1610.369262));
    
printf("6-%d", (> -1621.699218));
    
printf("7-%d", (46.000000));
    
printf("8-%d", (50.445312));
    if((
267.436309 && 275.307769) && (> -1610.369262 && < -1621.699218) && (46.000000 && 50.445312)) 
    { 
        print(
"true");
    } 

Os erros, estavam na verificaзгo de nъmeros negativos.
-10 > -15


Re: Бrea quadrada - B4dSh33p - 21.01.2018

Obrigado cara, +REP.