ID:294388
 
BYOND Build Number:
Operating System:
Video/Graphics Card:
Game Hub/Link:
Internet Connection Type:
Firewalls/Routers:

Problem Description:

Steps to Reproduce Problem:
rest()
var/bed=0
for(var/turf/InsideKonoha/bed11/G in locate(x,y,z))bed=1
for(var/turf/InsideKonoha/bed22/G in locate(x,y,z))bed=1
if(!bed)
src<You sit down and began to rest!","infobox")
icon_state="rest"
resting=1
freeze=1
else
src<
You close your eyes and start sleeping!","infobox")
dir=SOUTH
overlays+=/obj/sleep
resting=2
freeze=1
sight+=SEE_SELF
see_invisible-=3
you can clear see that i put ! in there so the first one does not work so i put second one on there but it's still say the first one that mean it's not making first stament false </<output></<output>
Dear Superyao,

If you intend to create a game, the first step should be to start here, since this is going to provide you with material to learn the basics of programming (in BYOND).
Try to have a look at the DM guide (and reference), since these will enlighten you past any tutorial you're working on. But don't 'rush through'(browse), like with a comic.
Sometimes you will think that you already know something, when you do not yet know all of the functionality.
Or, you think that something is 'too basic/of no use' for you, but every advanced bit of code is actually built out of these basic (tiresome) parts.

If you still did not manage, your next step would be to use the forum search (of the right forum, in this case Developers), since it is likely that your problem has been discussed before already and there are various replies.

Whenever you are struggling, a developer should use the Developer forum to seek assistance from like-minded community members.

As for your specific problems, I would have to assume that the object holding the method is of type atom/moveable, because you do not provide this information. If that is the case, it's location is either a turf, an obj, or a mob, but never an area, meaning that you can never find a turf in the content's list of it's location. Again, since you haven't provided ANY clue on what you want to actually do, I'll have to guess again and assume that you want to check for the type of turf that is the object's location, in which case you'd want to use if(istype(loc, /turf/InsideKonoha/bed11) || istype(loc, /turf/InsideKonoha/bed22)).

Thank you in advance.

Yours,
Schnitzelnagler.