View Full Version : game maker 7 help
09-15-2009, 08:01 PM
hi I am makeing a break out game on game maker7 my problem is that I am useing multiple diffrent types of blocks, and I am having trouble geting it to change levels here is what I have tryed, one thing I tryed was this script:
if (instance_number(block_1_room_0) == 0) and (instance_number(blue_block) == 0)and(instance_number(broken_blue_block) == 0) and (instance_number(bomb_block) == 0) and (instance_number(missle) == 0)
I also tryed makeing several objects with the instance count, that after counting the instance of one object it swaped to another object. oh and I have the plan version not upgraded.
oh and I was not sure if I sould put this in game paradise or tech support
09-15-2009, 10:18 PM
oh your siginature right
09-16-2009, 08:45 AM
ha ha that is funny
09-16-2009, 09:04 AM
Your way of thinking should work, really. My memory's really fuzzy from not using Game Maker in a long time, but I don't see why using instance_count for each block in an invisible instance in the room that keeps track of instance_count wouldn't work.
Of course, to avoid messy scripts you could make up your own variable. I'm not positive this would work, but maybe...
1.) Create an invisible instance for a room. in Create, have it set a variable to however many blocks there are.
2.) Also in create, write a script (or drag n' drop if/then statements, this is sometimes easier for me since I forget GML easily) that basically says "if (variable=0) then (whatever the change room command is)"
3.) Have each block, upon destruction, lower the variable by 1
The only problem is I don't remember if variables can be room-wide or if they always have to be instance-specific.
09-16-2009, 06:36 PM
yeah when ever I used variable I found the variable has to be mentioned in the script as b= a value before hand Inless there is something I do not know, which there probly is Oh and for the instance switch one I set it up so that that it would check it and then switch to the next instance in the list. but I will try with the variable a bit thanks
yeah I tryed useing the variable like you said but when I pressed L which is the cheat code I set to destroy all blocks, it does not go on to the next level. everytime I tryed something it did not work with that result or error in text which I always fixed.
I wish they would send me a confirmation email already so I could post this on their site.:mad:
you don't happen to have an accout on their offical site to post my problem on?
09-16-2009, 08:21 PM
No, I don't.
09-17-2009, 09:34 PM
oh ok::D: thanks
vBulletin® v3.8.2, Copyright ©2000-2013, Jelsoft Enterprises Ltd.