#Creates a instance when i dont want it to

30 messages · Page 1 of 1 (latest)

echo lagoon
#

how do you control the opening and exiting of the menu?

brittle cave
echo lagoon
# brittle cave

well thats the issue, you have no code preventing the left pressing or releasing when one or the other is open or active

brittle cave
echo lagoon
#

well where is the code for the spots you can build on?

brittle cave
echo lagoon
#

well, it could be as easy as wrapping all your left pressed code in a !instance_exists(obUIPanelShop), but I'm not sure if you're creating and destroying the shop with each click or what

#

so how are you controlling the UIpanel visibility? creating/destroying? or just hiding it somehow?

brittle cave
#

hidding it

echo lagoon
#

how?

brittle cave
#

but when the shop button is clicked it will move the instance to a possition

echo lagoon
#

thats not relevant, whats relevant is that you don't want the spots clickable while the UI is open/visible

#

when you click a button, the UI hides itself, so clicking after that should be fine

brittle cave
#

it uses this code to hide and show and the object is hidden outside the room

echo lagoon
#

so you dont have a specific variable that tells when its fully hidden?

#

what event is that in?

brittle cave
#

i dont think i do

echo lagoon
#

so how do you control the position movement?

brittle cave
#

it might be this

#

i can send u a copy of the game if it can help u in any way

#

im kinda new to gamemaker so i dont know much

echo lagoon
#

well I can't say your position_x and y will ever be those exact numbers via lerp like that, but with that said, you want a boolean variable for when the UI is hidden or visible

#

and just check that, so when its visible, you can't click on the placeable spots

#

when its hidden, you can

brittle cave
#

i have no clue how to code it to match that

#

i already have variables which checks if its hidden or shown

brittle cave
#

i tried adding this and it worked however when the ui closes it doesnt open back up