MattJon
|
  |
| Joined: 28 Apr 2009 |
| Total Posts: 660 |
|
|
| 28 Mar 2012 05:59 PM |
| Does elseif require double ='s like if does? |
|
|
| Report Abuse |
|
|
MattJon
|
  |
| Joined: 28 Apr 2009 |
| Total Posts: 660 |
|
|
| 28 Mar 2012 06:00 PM |
| And also, does elseif require an 'end' like if and function and while true do etc.? |
|
|
| Report Abuse |
|
|
|
| 28 Mar 2012 06:02 PM |
Well, 'if' and 'elseif' equations just check for statements. When comparing using '=' you must use 2 of them.
if (number == 2) then -- ... elseif (number == 3) then end
So yes, in the case that you are checking comparisons between 2 things. |
|
|
| Report Abuse |
|
|
mian
|
  |
| Joined: 05 Nov 2006 |
| Total Posts: 60 |
|
|
| 28 Mar 2012 06:03 PM |
elseif does need a ==, but does not need an (Separate) end.
Sincerely, Mian |
|
|
| Report Abuse |
|
|
MattJon
|
  |
| Joined: 28 Apr 2009 |
| Total Posts: 660 |
|
| |
|