how do i make my attribute not able to go passed a certain number? i tried this but its not working.
i want it to only go from 1-3 but stop at 1 and stop at 3. thank you fellow game makers
Comments
tenrdrmerMember, Sous Chef, Senior Sous-ChefPosts: 9,934
That might work if you change it to an any rul instead of an all rule. top left of the rule box.
But you should read up on min and max as they are really the functions you should be using. I can't really explain how to use them cause it all ways seems to me like the work opposite if what you think.
What you've got there looks correct and with ALL, not ANY. Are the numbers and attributes correct though, checking between 1 and 3 along the X axis is quite a small movement, and 1 and 3 would also be the far left of the screen with your actor being half off the screen.
tenrdrmerMember, Sous Chef, Senior Sous-ChefPosts: 9,934
No I mean in the expression editor you need to look at using the min and max functions. not greater than and less than conditions.
@tenrdrmer oh i have no idea how to use the expression editor and searched everywhere for how to use them... i read the whole gs cook book and the definitions dont really help. but ill play with them a bit and see what i can come up with.
@kevincross 1 and 3 are positions in tables.... there the row numbers.in tables i have the X coordinates ... something isnt right. ill have to keep trying. thanks guys.
It's definitely not right as you're checking the actors position not a table. Your actor will probably never be between pixels 1 and 3 on your scene as I remember seeing a wall in that position in your last video.
i fixed it to the table cell @kevincross but now it just stops all actions to my actor. it cant move left or right or rotate after i try and go less then 1 or greater then 3.
Is it the rotation button that's broken? From what I can see in the video you're moving blocks left and right between 3 columns so is that bit working correctly now? Does the rotation break the left and right movement? I didn't see you move the blocks once you pressed the rotate button.
Is it the rotation button that's broken? From what I can see in the video you're moving blocks left and right between 3 columns so is that bit working correctly now? Does the rotation break the left and right movement? I didn't see you move the blocks once you pressed the rotate button.
no the rotate button was just to show that when i try to go left after the 1st column thats on the wall. i lose control of all actors. same goes for the right 3rd column. once i get to the end it will just start droping cubes lol. sorry for not clarifying
Comments
But you should read up on min and max as they are really the functions you should be using. I can't really explain how to use them cause it all ways seems to me like the work opposite if what you think.
i fixed it to the table cell @kevincross but now it just stops all actions to my actor. it cant move left or right or rotate after i try and go less then 1 or greater then 3.
also tried to make a max for it but didnt have a clue on how to write it