1 registered members (henrybane),
1,499
guests, and 1
spider. |
Key:
Admin,
Global Mod,
Mod
|
|
|
And/or
#243415
12/29/08 22:42
12/29/08 22:42
|
Joined: Jul 2007
Posts: 288 Germany, NRW
Martek
OP
Member
|
OP
Member
Joined: Jul 2007
Posts: 288
Germany, NRW
|
Kurze Frage, gibt es in 3DGS And/or, also einen Vergleich, der true ist wenn eins oder beide wahr sind? Ich mein das währ doch der And/or Vergleich. Oder muss ich das durch ne kompliziertere if-Abfrage lösen?
Mfg, Martek
3D Gamestudio A7 Extra
|
|
|
Re: And/or
[Re: Martek]
#243445
12/30/08 00:56
12/30/08 00:56
|
Joined: Jul 2008
Posts: 1,178 England
MrGuest
Serious User
|
Serious User
Joined: Jul 2008
Posts: 1,178
England
|
i used http://freetranslation.com/ so sorry for grammar if ((true == true) || (false == true)){ =true (or) if ((true == true) && (false == true)){ =false (and) hope this helps
|
|
|
Re: And/or
[Re: MrGuest]
#243536
12/30/08 16:33
12/30/08 16:33
|
Joined: Jul 2007
Posts: 288 Germany, NRW
Martek
OP
Member
|
OP
Member
Joined: Jul 2007
Posts: 288
Germany, NRW
|
No, I mean if there is this in a shorter version??? if((x == true && y == true) ||(x == true || y = true))
3D Gamestudio A7 Extra
|
|
|
Re: And/or
[Re: Martek]
#243552
12/30/08 18:47
12/30/08 18:47
|
Joined: Jul 2008
Posts: 1,178 England
MrGuest
Serious User
|
Serious User
Joined: Jul 2008
Posts: 1,178
England
|
oh, then yes, for x and y true for x or y true for x and y false or write a macro for checking if you want shorter than that
|
|
|
Re: And/or
[Re: MrGuest]
#243554
12/30/08 19:00
12/30/08 19:00
|
Joined: Oct 2007
Posts: 5,210 Ä°stanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
|
if((x == true && y == true) ||(x == true || y = true))
this is same as x or y : if(x||y)
and there is a xor(^) but
if(true^true) = false if(false^false) = false if(ture^false) = true
3333333333
|
|
|
Re: And/or
[Re: Quad]
#243573
12/30/08 20:42
12/30/08 20:42
|
Joined: Jul 2007
Posts: 288 Germany, NRW
Martek
OP
Member
|
OP
Member
Joined: Jul 2007
Posts: 288
Germany, NRW
|
No it' not the same because in your version it's false if x and y are true, but I need true if one or both are true...
3D Gamestudio A7 Extra
|
|
|
Re: And/or
[Re: Martek]
#243575
12/30/08 20:49
12/30/08 20:49
|
Joined: Oct 2007
Posts: 5,210 Ä°stanbul, Turkey
Quad
Senior Expert
|
Senior Expert
Joined: Oct 2007
Posts: 5,210
Ä°stanbul, Turkey
|
if(x||y)
this works when both are true and only one is true.
i just mentioned ^as a side note.
3333333333
|
|
|
Re: And/or
[Re: Quad]
#243587
12/30/08 21:17
12/30/08 21:17
|
Joined: Jul 2007
Posts: 288 Germany, NRW
Martek
OP
Member
|
OP
Member
Joined: Jul 2007
Posts: 288
Germany, NRW
|
Oh, it works. But the manual says something different. So thank you for your help...
3D Gamestudio A7 Extra
|
|
|
|