Posted By
|
Message
|
Chris Burrows
Registered 14/09/2002
Points 2396
|
29th August, 2011 at 12:09:50 -
If you have a List Object in your level, run your game, and press Tab, the List Object gets focus and your game loses focus.
So, when you have an action "Upon pressing Tab", it doesn't work. Is there a work around?
Setting the List Object to Always "Lose Focus" and "De highlight" doesn't fix it.
Neither does setting the List Object to "Hide On Start" in the List Object Properties.
Work around?????
n/a
|
Duncan Thelonious Dunc
Registered 18/05/2002
Points 552
|
29th August, 2011 at 18:05:37 -
I would avoid using this object in a game for reasons like the ones you described. It'll also make your game stutter whenever you do anything with it due to some variety of Windows voodoo which I'm sure someone can articulate better than me.
Are you using this as an actual interface element, or to store data or something?
n/a
|
Chris Burrows
Registered 14/09/2002
Points 2396
|
29th August, 2011 at 18:30:53 -
I'm using it to store data.
The List Object can be really useful for creating inventory systems. When you delete a line from a List Object, it disappears and the lines below move up. This means no empty slots in your inventory. You set the List Object to invisible and create your own graphical interface inventory from the data stored in the list. Works great!
I managed to find a work around for my problem. One that doesn't really make sense (typical MMF haha) but works nonetheless.
Are you talking about how sometimes it flickers?
Edited by Chris Burrows
n/a
|
UrbanMonk BRING BACK MITCH
Registered 07/07/2008
Points 49667
|
29th August, 2011 at 20:09:49 -
I do believe there is a setting in the object properties that disables tab lock.
Find it and uncheck it...or check it. I don't remember.
n/a
|
Duncan Thelonious Dunc
Registered 18/05/2002
Points 552
|
29th August, 2011 at 20:13:18 -
Yeah, it flickers every time. If you loop through list items, it'll flicker on every loop step and hang up your game for as long as that takes.
It seems useful, but at the end of the day, it's nothing you can't do with some halfway competent string parsing, and without the heartache
n/a
|
Chris Burrows
Registered 14/09/2002
Points 2396
|
29th August, 2011 at 21:43:22 -
Maybe.
It seems you guys really don't like the List Object. If you fix the tab problem, then it's not a problem. If you set the object to invisible then you won't see it flicker.
And the "Add Line", "Delete Line", "Set Current Line", retrieve "Current Line", actions/conditions etc are FREAKING BOSS!
DEATH BEFORE DISHONORING THE LIST OBJECT
n/a
|
Cecilectomy noPE
Registered 19/03/2005
Points 305
|
29th August, 2011 at 22:01:31 -
Originally Posted by . : UrbanMonk : . I do believe there is a setting in the object properties that disables tab lock.
Find it and uncheck it...or check it. I don't remember.
there is no such setting.
you said you found a workaround. not sure what you did but the easiest way is to add the event:
+ "list object" have focus?
- "list object" lose focus.
n/a
|
Jon Lambert Administrator
Vaporware Master
Registered 19/12/2004
Points 8235
|
29th August, 2011 at 22:16:27 -
I'm nowhere near an MMF2 seeing as I'm running Ubuntu without WINE right now, but does it still tab to the list if you disable it? Wouldn't disabling it only prevent the user from interacting with the list? Is there a disable?
Sandwich Time!Whoo!
JoyCheck & KeyCheck Widgets
For easy implementation of customizable joystick and keyboard controls.
http://www.create-games.com/download.asp?id=8364
|
Chris Burrows
Registered 14/09/2002
Points 2396
|
29th August, 2011 at 22:55:49 -
Forcing the list to lose focus fixes the "Upon pressing tab key" problem but that wasn't exactly my problem.
I'm using the Control X extension as to allow customisable controls in my game.
So, instead of using "Upon pressing tab key" my condition is something like: "CONTROL X: 'Inventory Key' is pressed"
If the "tab" key was assigned as 'Inventory Key' then it wouldn't work. (Even while forcing the List Object to always lose focus, which fixes "Upon pressing tab key" glitch)
This I figure must be a glitch in the Control X extension.
I fixed it by adding the code:
- START OF LEVEL: Set player 1 Fire Button to 'Inventory Key'
So now instead of testing for the key press using the CONTROL X 'Inventory Key' method, I'm testing for Player 1's fire button which seems to work.
In response to John Lambert: I've use the List Object for many different tasks and it seems to be pretty unpredictable and it's functionality is dependent on too many external factors. Also, sometimes pressing the arrow keys gives focus to the List Object. And to make it even more confusing, when and whether or not it does seems to follow different rules to pressing the tab key .
n/a
|
Duncan Thelonious Dunc
Registered 18/05/2002
Points 552
|
29th August, 2011 at 23:01:58 -
Exactly! And try looping through 1200 list object entries - it'll take about 2 seconds, flickering away. It's a lot of crap to deal with for a multiline string, imo
n/a
|
Pixelthief Dedicated klik scientist
Registered 02/01/2002
Points 3419
|
30th August, 2011 at 00:15:46 -
Don't use a list object unless you are actually using it for the list display, as part of your GUI. The list object is a default windows object that you can work with, and is subject to all the quirks of windows. Every time you update it, it has to redraw its graphical GUI even if its not visible, on frame, or if your application is updating. As a form of data storage, its very ungainly and inefficient and will slow down stuff a ton. Its just mean to be used for direct user interaction, not in place of an array.
The "Internal List Object" extension should be available iirc, which is like the list object except without the graphical component:
http://www.clickteam.com/epicenter/ubbthreads.php?ubb=showflat&Number=237508#Post237508
Gridquest V2.00 is out!!
http://www.create-games.com/download.asp?id=7456
|
Chris Burrows
Registered 14/09/2002
Points 2396
|
30th August, 2011 at 16:45:47 -
Cheers Pixeltheif! That is EXACTLY what I need. I didn't even know it existed. Do you still recommend using an array over the Internal List Object?
I don't use arrays, simply because I've never spent the time to learn how. I am lazy and my time is precious. I made an app once using Ini Plus and a shitload of List Objects doing a whole bunch of random operations and I learnt how to use it inside out and I am very comfortable with them.
When using an array, is it easy to make it so when you remove and item, all items below move up a slot?
Thanks again
n/a
|
Chris Burrows
Registered 14/09/2002
Points 2396
|
30th August, 2011 at 16:57:32 -
Upon closer inspection the Internal List Object SUCKS!!!!!! Has anybody used it before?
It doesn't have any of the features that make the normal List Object useful.
Furthermore, adding items crashes the game. When you choose "Insert Item" you are asked to specify where to insert it "before". And no matter what you enter here, the game will crash when it runs the action.
Any good array examples out there floating these rough and shark infested MMF oceans??
n/a
|
Chris Burrows
Registered 14/09/2002
Points 2396
|
30th August, 2011 at 17:44:17 -
Soooooooooo... I've been experimenting with arrays. I've created a loop to update a string with the contents of a 1 dimensional array (x only).
The loop starts "always" and runs "X dimension" times. Will this loop slow down my game? I could start the loop ONLY when the array is modified...
Also, as the string is updated, you can "see it happening" for 1 frame (as in Frames Per Second). I don't like it! It is hard to explain. Here is my mfa: http://www.whenthereisnoroominhellthedeadwalktheearth.com/MMF/array.mfa
Sorry for triple posting. Everybody, please disregard everything I have ever said, and simply answer this 1 question:
What is the most efficient way to display the contents of an array as a string?
Cheers!
n/a
|
lembi2001
Registered 01/04/2005
Points 608
|
30th August, 2011 at 19:15:16 -
Could you not use a standard string and a string tokenizer?
E.G.
Item1;Item2;Item3;Item4
This way you could quite easily remove the items using some clever manipulation??
n/a
|
UrbanMonk BRING BACK MITCH
Registered 07/07/2008
Points 49667
|
30th August, 2011 at 22:49:14 -
Did you try just making the list object invisible?
I've used 2 or 3 list objects outside the frame before and I've never had these problems.
n/a
|
Chris Burrows
Registered 14/09/2002
Points 2396
|
31st August, 2011 at 03:56:18 -
From memory, making the list invisible fixes the problem of pressing the arrow keys and giving focus to the list, but not for pressing tab.
n/a
|
|
|