Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Can someone who uses DK test out marvel vs capcom  (Read 2141 times)

0 Members and 1 Guest are viewing this topic.

Shieldwolf

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 636
  • Last login:November 16, 2020, 12:48:53 am
  • SpearShield.com
Can someone who uses DK test out marvel vs capcom
« on: May 30, 2004, 06:25:36 pm »
I tried to email Howard, but the emails keep getting sent back.

When I play marvel vs capcom and then try and back out I go back to the game selection menu where I am immediatly relaunched into the game. Does this happen for anyone else. I have tried other games and even reinstalled the rom, but both the rom and other games work fine on command line and DK except for Marvel vs Capcom

Howard_Casto

  • Idiot Police
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19427
  • Last login:Yesterday at 12:27:54 pm
  • Your Post's Soul is MINE!!! .......Again??
    • The Dragon King
Re:Can someone who uses DK test out marvel vs capcom
« Reply #1 on: May 31, 2004, 03:58:28 am »
It's not a game specific thing, you just think it is.....

Probably your problem:

Due to the way directx caches the keyboard keys, they are "saved" when the gui is busy.  Let's say you press the select key twice quickly....  Dk launches marvel vs capcom and "freezes" to save memory.  Upon exiting mame it "unfreezes" and finds a select key saved in the cache and thus immediately launches the same game again.  

So your solution is not to keep pressing a key when the game doesn't launch immediately and not to press keys while mame is exiting and dk is unfreezing itself.    Also if you are not using an ipac, the typematic keyrate tends to start repeating a key if it's held down for a while.  So don't hold down the select key, just press it.  

Unfortunately, there is not much i can do to stop this syndrome as it's just the way keys are handled.  

sorry.  

Teknique

  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 204
  • Last login:October 02, 2015, 10:35:46 am
  • I'm a Gauntlet wizard in real life
Re:Can someone who uses DK test out marvel vs capcom
« Reply #2 on: June 02, 2004, 07:53:51 am »
Just tried it here Shield, It works ok for me.

Tek
Your screen name has been added to my frag list.

Minwah

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 7662
  • Last login:January 18, 2019, 05:03:20 am
    • MAMEWAH
Re:Can someone who uses DK test out marvel vs capcom
« Reply #3 on: June 02, 2004, 08:19:01 am »
Due to the way directx caches the keyboard keys, they are "saved" when the gui is busy.  Let's say you press the select key twice quickly....  Dk launches marvel vs capcom and "freezes" to save memory.  Upon exiting mame it "unfreezes" and finds a select key saved in the cache and thus immediately launches the same game again.  

So your solution is not to keep pressing a key when the game doesn't launch immediately and not to press keys while mame is exiting and dk is unfreezing itself.    Also if you are not using an ipac, the typematic keyrate tends to start repeating a key if it's held down for a while.  So don't hold down the select key, just press it.  

Unfortunately, there is not much i can do to stop this syndrome as it's just the way keys are handled.  

I don't use DirectX but MAMEWAH has the same problem, particularly if you whack a load of keys while a list is being generated or a game is being launched.  It seemed to me that it *should* be possible to stop this problem, turning KeyPreview off and on, or simply ignoring inputs until whatever is happening has completed.  I spent a load of time on this but could never eradicate the problem completely :(  I must say tho that I don't find it a problem, unless I purposely hit loads of buttons.

Just to add to what Howard said re non-IPAC's, it's worth mentioning that an IPAC in USB mode enables key-repeat (like a keyboard), so if you have one of these I'd recommend you set it to PS/2 mode.

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Can someone who uses DK test out marvel vs capcom
« Reply #4 on: June 02, 2004, 09:40:25 am »
It is possible to flush the keyboard cache, so that after you launch a game, all stored keystrokes in memory are discarded.


-PMF
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

Minwah

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 7662
  • Last login:January 18, 2019, 05:03:20 am
    • MAMEWAH
Re:Can someone who uses DK test out marvel vs capcom
« Reply #5 on: June 02, 2004, 11:09:47 am »
It is possible to flush the keyboard cache, so that after you launch a game, all stored keystrokes in memory are discarded.

I'm sure that is so, but I couldn't find a way to do it from VB...any clues?

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Can someone who uses DK test out marvel vs capcom
« Reply #6 on: June 02, 2004, 12:27:05 pm »
It really depends on how you are reading the keyboard. In my FE, I'm using GetAsyncKeyState, but I could also use DirectInput.

For clearing the windows keyboard buffer, you need to iterate through the messages of the window using PeekMessage, and get the keyboard-specific messages using GetMessage.

I can post a c++ example if you need it.

-PMF
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

Minwah

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 7662
  • Last login:January 18, 2019, 05:03:20 am
    • MAMEWAH
Re:Can someone who uses DK test out marvel vs capcom
« Reply #7 on: June 02, 2004, 01:30:52 pm »
It really depends on how you are reading the keyboard. In my FE, I'm using GetAsyncKeyState, but I could also use DirectInput.

For clearing the windows keyboard buffer, you need to iterate through the messages of the window using PeekMessage, and get the keyboard-specific messages using GetMessage.

I can post a c++ example if you need it.

Thanks, but C code is pretty much lost on me  ::)

OT Did you get that MW layout code I emailed you?  Sorry I haven't checked out Kymaera enough to see if you included it  :-[

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Can someone who uses DK test out marvel vs capcom
« Reply #8 on: June 02, 2004, 01:42:22 pm »
Yeah, I got it a while back, But I was having a hard time making heads or tails of it. It would be nice to create a converter so users of MameWah and Kymaera could swap skins.

-PMF
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

Minwah

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 7662
  • Last login:January 18, 2019, 05:03:20 am
    • MAMEWAH
Re:Can someone who uses DK test out marvel vs capcom
« Reply #9 on: June 02, 2004, 06:20:49 pm »
Yeah, I got it a while back, But I was having a hard time making heads or tails of it. It would be nice to create a converter so users of MameWah and Kymaera could swap skins.

It looks worse than it is, purely as there are so many objects (the way I did it is pretty cheap to be honest, just reading values and applying to objects' properties).  If anyone wants to make a converter then sure, good idea.  I'm not willing to do it really as I know I will be changing the format in the future...and I wouldn't want to have to do it again!  If anyone is serious about making the converter, I could turn my code into English so anyone could understand what each line of the LAY file does...

PacManFan

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 858
  • Last login:December 06, 2005, 12:18:56 pm
    • Kymaera Home Page
Re:Can someone who uses DK test out marvel vs capcom
« Reply #10 on: June 03, 2004, 09:30:42 pm »
If you'd like, I could give you the code for the XML based skin file format I created. It's very flexable, and the way the file format  is created, you can add new data types without breaking it and still maintain backward compatibilty. I remember someone asking an open ended question about swapping skins between different FE's and asking if that was possible.

-PMF
All Hail Smezznar! The Giant purple centipede of Omnicron 5. Regail him with your odiferous offerings of onion powder!

Howard_Casto

  • Idiot Police
  • Trade Count: (+1)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 19427
  • Last login:Yesterday at 12:27:54 pm
  • Your Post's Soul is MINE!!! .......Again??
    • The Dragon King
Re:Can someone who uses DK test out marvel vs capcom
« Reply #11 on: June 05, 2004, 05:19:41 pm »
Getting back to the topic at hand...

I think I found a solution, one that doesn't involve crazy stuff like intercepting the key buffer and clearing it.

It's so stupid, but apparently it works.  If you use the setfocus api call (often renamed putfocus in vb)  and set the focus to null just before you launch then nothing gets the keys pressed until something else sets focus on itself (in this case the emulator)  upon exiting, windows sets the focus back to the next to highest thing in the zorder (which should be your fe).  So it doesn't kill the keypresses they just go away to some magical non existant form that we don't care about.  :)

Minwah

  • Trade Count: (+3)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 7662
  • Last login:January 18, 2019, 05:03:20 am
    • MAMEWAH
Re:Can someone who uses DK test out marvel vs capcom
« Reply #12 on: June 06, 2004, 11:46:49 am »
Getting back to the topic at hand...

I think I found a solution, one that doesn't involve crazy stuff like intercepting the key buffer and clearing it.

It's so stupid, but apparently it works.  If you use the setfocus api call (often renamed putfocus in vb)  and set the focus to null just before you launch then nothing gets the keys pressed until something else sets focus on itself (in this case the emulator)  upon exiting, windows sets the focus back to the next to highest thing in the zorder (which should be your fe).  So it doesn't kill the keypresses they just go away to some magical non existant form that we don't care about.  :)

Sounds good, I'll have to give it a try :)