|
What's the meaning of this |=?
#319044
04/11/10 19:19
04/11/10 19:19
|
Joined: Jan 2010
Posts: 15
mygame4
OP
Newbie
|
OP
Newbie
Joined: Jan 2010
Posts: 15
|
I have a silly question  I found some scripts have |= For example, p.flags |= (BRIGHT | MOVE); or p.flags |= MOVE; I don't know what's the meaning of |=
|
|
|
Re: What's the meaning of this |=?
[Re: mygame4]
#319045
04/11/10 19:24
04/11/10 19:24
|
Joined: Aug 2007
Posts: 1,922 Schweiz
Widi
Serious User
|
Serious User
Joined: Aug 2007
Posts: 1,922
Schweiz
|
|
|
|
Re: What's the meaning of this |=?
[Re: mygame4]
#319189
04/12/10 20:23
04/12/10 20:23
|
Joined: Sep 2009
Posts: 1,032 Budapest
Aku_Aku
Serious User
|
Serious User
Joined: Sep 2009
Posts: 1,032
Budapest
|
In Lite-C there is an operator to make decision about equality. In this language, as like as all "C" like languages, this operator is the "==". Sometime in programming we need to examine the reversed equality for this purpose is being the "|=". So just imagine - 1. == equal
- 2. |= not equal
- 3. >= greater than
- 4. <= less than
and so on...
|
|
|
Moderated by mk_1, Perro, rayp, Realspawn, Rei_Ayanami, rvL_eXile, Spirit, Superku, Tobias, TSG_Torsten, VeT
|