boolean variables

Ideas for Game Editor evolution.

boolean variables

Postby Fojam » Sat Jan 14, 2012 6:27 pm

will boolean variables ever be implimented in game editor? at the moment i just use integers and make 1 true and 0 false, but it would be helpful if booleans were implimented, because they are a little more efficient for switching between two things.
CLICK TO GIVE ME POINTS

My Latest Projects:
Super Smash Bros: viewtopic.php?f=6&t=12307 PLEASE help by making sprites!
User avatar
Fojam
 
Posts: 513
Joined: Thu Mar 19, 2009 10:02 pm
Location: under your bed!!!
Score: 69 Give a positive score

Re: boolean variables

Postby Troodon » Wed Feb 01, 2012 5:26 pm

How can it be more handy to type "false" than "0"? :)
Int allows you to take, let's say -1 and 2 as variable values too if you realise the basic on/off variable isn't enough at some part.

If (machine == -2) //off, broken and burning
{
...
}

is faster than

if (machineWorks && machineOff && machineBurns)
{
...
}
I can't die, I already tried
~on the forums since GE 1.3.3~
User avatar
Troodon
 
Posts: 1539
Joined: Thu Jan 12, 2006 3:29 pm
Location: HELL
Score: 56 Give a positive score


Return to Feature Requests

Who is online

Users browsing this forum: No registered users and 1 guest