Fangames > Programming Questions

Making Portals Unusable After Defeating The Area

(1/1)

GalacticHooloovoo:
Hello!

I've been trying to make it so that there are multiple selectable areas which can be chosen at the player's decision, and once the area is defeated, having the player be returned back to the screen with the multiple portals, and having the area be unable to be returned to. Also, I would like it so that once all of the portals are defeated, another portal appears that wasn't there before. As someone with little GameMaker experience, I cannot figure it out.

Can someone help me with how to do this?

Thanks!

Also, I am using the Yuuutu engine.

lawatson:
You can use the global.boss[index] or global.item[index] variables to do that. You don't have to make a pickup or a boss either, you can simply just trigger it secretly after beating the area.
You can do it like so:

global.item[0]=1;

Simple as that. To make portals disappear and appear when you enter the warp room, you can basically do something like:

if global.item[0]==1{
    instance_destroy();
}

Put it in the creation code of the portal, not the create event (The one in the object maker). And if you want to make a portal appear when you have all the items, what you need to do is something like:

if global.item[0]==1 && global.item[1]==1 && global.item[2] ==1 ...{
    a=instance_create(position,position,warp);
    a.roomTo=finalArea;
}

Simple as that. I hope this helps!

Navigation

[0] Message Index

Go to full version