My UI works with 14 players and its just 1 dialog, it shows stats based on what weapon/sidearm and then there's like 250 variations of equipment you can have down the bottom part, it updates like 30 labels on the right side and modifies button images/tooltips/labels and stuff when you click on them, but there are certain limitations to having 1 dialog for all players like actually trying to move the dialog to a different position
all of the UI is my map are just 1 dialog so far and it worked when i tested them with a friend.
chill, no need to get rude, i just want to help you and others who didnt figure it out yet.
if you create every dialog/dialog item as an array you will waste a lot of memory, and its really not necessary. if you want i can post some example code later.
greez
I would love some examples - My Custom UI completely works, but I find it very inefficient and I 'know' there is a better way. I'm also willing to share my map if you'd like to see :)
I would love some examples - My Custom UI completely works, but I find it very inefficient and I 'know' there is a better way. I'm also willing to share my map if you'd like to see :)
the following example will show you (and all others who want to) how to create a simple dialog that will count the clicks on the dialog button for each player in display them into a label. no dialog/dialog item array needed.
you can find the map in the attachments.
at first, you must init the dialog. basically, you do as much init work at map startup as possible to avoid lags during the gameplay. in the game you just use show/hide to display dialogs. in fact, they are always there, but not visible.
you could also do the init in a seperate function, just do it how you like it best. if you have much UI, i recommend to use records for better overview, like here.
now you just need to add the trigger that fires if the button gets pressed
as you see, the only array we really need is the integer array, because each player has a different value stored into it, dependig how often he clicked the buttons. the dialog and the dialog item themselfes dont need to be arrays because you can change values for each player seperatly. it also doesnt matter if a lot of players click the same button because only the integer that belongs to the clicking player (triggering player) gets increased.
for sure this is a very simple example, but with this concept you can do nearly everything.
Ok, I see what you're saying here - but the map I'm developing runs completely off of keyboard input;
Basically, I create a cursor that has X,Y location and also has a a variable (ARROW LOCATION), that I use to determine if the cursor is being used on the menu map, battle menu, etc. I.E. if (cursor location) = 1, then I have my battle menu open, or if it's set to 2 I have my main menu open, etc, etc.
I use spacebar atm for my "confirm" key when selecting stuff. So lets say, I hit M to open my main menu, now my arrow location is set to "2" and my X,Y location is set to some start location to where the cursor displays next to the appropriate selections "stats/loot/items/order/etc". I now have events that are enabled when my main menu is open -
Basically, the control for selecting stuff is not based on a button click; So how would I make your example work and incorporate controls based off keyboard input? Clicking just makes me feel like I'm not playing a traditional rpg.
even if i cant really follow you, there is no real difference between keyboard controls and a button click. its nearly the same principe. i dont really get what this has to do with the actual question of dialog arrays.
There is no question of dialog arrays - the ff13 guy mentioned using that.
The issue however is that your function to determine when to turn off the dialogs is based off the "used dialog item" function - which basically means, last clicked function, correct? I.E. how would one implement a key stroke for that position - cause technically i never "use" a button, it's simply there for display.
when you test your UI with more than 1 player and it fails horribly you can post your apology here because what you are talking about flat out does not work. Video or it did not happen.
Now that Mille posted some valid code AND a testmap I think an apology would be appropriate, would it not? :)
There is no question of dialog arrays - the ff13 guy mentioned using that.
The issue however is that your function to determine when to turn off the dialogs is based off the "used dialog item" function - which basically means, last clicked function, correct? I.E. how would one implement a key stroke for that position - cause technically i never "use" a button, it's simply there for display.
hm ok, but both events return the triggering player.
it doesnt really matter if a player presses a button or a key, you can always get this player with "triggering player" and use this for further actions.
sorry if i dont get your problem, maybe we can start from top again with your current issue :/
1) My map is being developed for single player - so making it functional for multiple players is not the focus (especially considering key board input in multiplayer games = lag).
2) I basically wanted an answer to a more efficient method to display a custom, traditional, rpg menu, which can be displayed at any point by pressing a key. The key would then generate a menu that has a keyboard controlled cursor with varying displays governed by variables in the game; such as; The ordering for units, hps, stats, etc (I want to avoid boss bars because they don't have nearly the amount of customization features that buttons/screen images/etc have).
So, I originally did all this by having just a few dialogs, but I ran into an issue when it came to hiding these generic dialogs and displaying them again. Currently there is no "hide all dialogs" function that I am aware - just a destroy all. This became an issue when calling the menu back up because of my cursor. I could create/hide/destroy static dialogs using this method but it was impossible to accomplish for the cursor since it required some kind of unique pointer (i.e. button #, or image #), in order to modify the cursors x,y location. Note; this is just an example of one non-static function (obviously I could just use the last created dialog feature if the only thing that ever moved/changed was just the cursor).
I'm going to PM you my map so you could take a look at the code and maybe offer some input if you feel up to it.
dont know whats exactly the problem with this game menu?
ive made a little example map showing a game menu that can be controlled with keys
press ESC to open or close it and up/down arrow to select an item. then press space to show item information. this is also MUI so it works for up to 16 players. i hope it helps you^
PS: the menu reminds what item you selected when closing it, so you dont start at the first everytime, dont know if you want it like this or not
My UI works with 14 players and its just 1 dialog, it shows stats based on what weapon/sidearm and then there's like 250 variations of equipment you can have down the bottom part, it updates like 30 labels on the right side and modifies button images/tooltips/labels and stuff when you click on them, but there are certain limitations to having 1 dialog for all players like actually trying to move the dialog to a different position
all of the UI is my map are just 1 dialog so far and it worked when i tested them with a friend.
weak
I would love some examples - My Custom UI completely works, but I find it very inefficient and I 'know' there is a better way. I'm also willing to share my map if you'd like to see :)
Fair enough, and thank you :)
the following example will show you (and all others who want to) how to create a simple dialog that will count the clicks on the dialog button for each player in display them into a label. no dialog/dialog item array needed.
you can find the map in the attachments.
at first, you must init the dialog. basically, you do as much init work at map startup as possible to avoid lags during the gameplay. in the game you just use show/hide to display dialogs. in fact, they are always there, but not visible.
you could also do the init in a seperate function, just do it how you like it best. if you have much UI, i recommend to use records for better overview, like here.
now you just need to add the trigger that fires if the button gets pressed
button click
as you see, the only array we really need is the integer array, because each player has a different value stored into it, dependig how often he clicked the buttons. the dialog and the dialog item themselfes dont need to be arrays because you can change values for each player seperatly. it also doesnt matter if a lot of players click the same button because only the integer that belongs to the clicking player (triggering player) gets increased.
for sure this is a very simple example, but with this concept you can do nearly everything.
@Mille25: Go
Ok, I see what you're saying here - but the map I'm developing runs completely off of keyboard input;
Basically, I create a cursor that has X,Y location and also has a a variable (ARROW LOCATION), that I use to determine if the cursor is being used on the menu map, battle menu, etc. I.E. if (cursor location) = 1, then I have my battle menu open, or if it's set to 2 I have my main menu open, etc, etc.
I use spacebar atm for my "confirm" key when selecting stuff. So lets say, I hit M to open my main menu, now my arrow location is set to "2" and my X,Y location is set to some start location to where the cursor displays next to the appropriate selections "stats/loot/items/order/etc". I now have events that are enabled when my main menu is open -
I.E. http://img59.imageshack.us/img59/8689/exmenucontrol.jpg
Basically, the control for selecting stuff is not based on a button click; So how would I make your example work and incorporate controls based off keyboard input? Clicking just makes me feel like I'm not playing a traditional rpg.
@Flapjack46: Go
even if i cant really follow you, there is no real difference between keyboard controls and a button click. its nearly the same principe. i dont really get what this has to do with the actual question of dialog arrays.
@Mille25: Go
There is no question of dialog arrays - the ff13 guy mentioned using that.
The issue however is that your function to determine when to turn off the dialogs is based off the "used dialog item" function - which basically means, last clicked function, correct? I.E. how would one implement a key stroke for that position - cause technically i never "use" a button, it's simply there for display.
Now that Mille posted some valid code AND a testmap I think an apology would be appropriate, would it not? :)
hm ok, but both events return the triggering player.
it doesnt really matter if a player presses a button or a key, you can always get this player with "triggering player" and use this for further actions.
sorry if i dont get your problem, maybe we can start from top again with your current issue :/
@Mille25: Go
No worries at all; First off..
1) My map is being developed for single player - so making it functional for multiple players is not the focus (especially considering key board input in multiplayer games = lag).
2) I basically wanted an answer to a more efficient method to display a custom, traditional, rpg menu, which can be displayed at any point by pressing a key. The key would then generate a menu that has a keyboard controlled cursor with varying displays governed by variables in the game; such as; The ordering for units, hps, stats, etc (I want to avoid boss bars because they don't have nearly the amount of customization features that buttons/screen images/etc have).
So, I originally did all this by having just a few dialogs, but I ran into an issue when it came to hiding these generic dialogs and displaying them again. Currently there is no "hide all dialogs" function that I am aware - just a destroy all. This became an issue when calling the menu back up because of my cursor. I could create/hide/destroy static dialogs using this method but it was impossible to accomplish for the cursor since it required some kind of unique pointer (i.e. button #, or image #), in order to modify the cursors x,y location. Note; this is just an example of one non-static function (obviously I could just use the last created dialog feature if the only thing that ever moved/changed was just the cursor).
I'm going to PM you my map so you could take a look at the code and maybe offer some input if you feel up to it.
Thanks
dont know whats exactly the problem with this game menu?
ive made a little example map showing a game menu that can be controlled with keys
press ESC to open or close it and up/down arrow to select an item. then press space to show item information. this is also MUI so it works for up to 16 players. i hope it helps you^
PS: the menu reminds what item you selected when closing it, so you dont start at the first everytime, dont know if you want it like this or not
@Mille25: Go
This is exactly what I was looking for, thanks!
EDIT: Deleted