ā2022-04-19 12:39 PM
Hello,
I would like to add a button depending on the amount that is selected from the list of values.
For example, in Parameters I have:
VALUES "Shelf_Amount", 1, 2, 3, 4, 5, 6, 7If I select 1 from the list, one buttom will be added, if I select 2, then two buttons will be added and so on. The idea behind this is that each button will control something different, like using a different gosub depending on which button is pushed.
I have managed to add a simple button on the UI, but not sure how to do it in a dynamically way and with a incremental name per button. I thought that adding the variable name + 1 would do the trick, but did failed.
Master:
Button_Name = "Test"
Interface:
UI_BUTTON UI_FUNCTION, Button_Name, 0, 0, 150, 50
Juan.
Solved! Go to Solution.
ā2022-04-25 09:52 AM
Thank you, yes I have an array in a condition if all the shelves are the same, but there is another condition where the shelves can be different, user's choice.
My script works flawless, just not sure if there is a more optimal way on doing it when all the shelves are different.
ā2022-04-29 03:21 PM
not sure if that is what you were looking for...
https://drive.google.com/file/d/1N8-0rHlxeE7StJ23wwTwROxMKqIzpGhW/view?usp=drivesdk
ā2022-04-29 08:49 PM
Here is a quick video of where i took my shelving object
ā2022-05-02 07:05 AM - edited ā2022-05-02 07:17 AM
Yes, exactly what I'm looking after. š
Thank you.
ā2022-05-02 07:15 AM
You are using the same hotspot to perform different tasks depending on the direction to where you move it?.
That is fantastic, didn't know that.
ā2022-05-02 03:50 PM
I'll post a link in a bit so you can look at it if you are interested.
ā2022-05-03 01:38 PM
Absolutely, very interested on your method.