Visual Basic > Visual Basic Forums > Visual Basic General > How to Make A (Mp3 Player) Ingame Menu?
Ask a questionAsk a question
 

Proposed AnswerHow to Make A (Mp3 Player) Ingame Menu?

  • Saturday, October 10, 2009 3:44 AMTj.. Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    I want to make an ingame menu. When you open a game a menu will pop up with a hotkey. I don't need you to do the work for me I just need a sample of a ingame menu with a hot toggle (ie: the menu doesnt need an interface, a black square that pops up with key). Thanks in advanced.
    • Edited byTj.. Saturday, October 10, 2009 4:51 AM
    • Edited byTj.. Saturday, October 10, 2009 3:49 AM
    • Edited byTj.. Saturday, October 10, 2009 1:16 PM
    •  

All Replies

  • Saturday, October 10, 2009 3:49 AMkaymaf Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    For windows Application, use Menustrip or ContextMenu

    kaymaf
    I hope this helps, if that is what you want, just mark it as answer so that we can move on
  • Saturday, October 10, 2009 4:02 AMkaymaf Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    I need a ingame menu I know the basics.

     Well, for Windows Application, that was the only options unless you create your own menu. You may also consider game forum (DirectX or XNA ) http://forums.xna.com

    kaymaf
    I hope this helps, if that is what you want, just mark it as answer so that we can move on
  • Saturday, October 10, 2009 4:02 AMTj.. Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    I need to make a D3D ingame menu...Does anyone have any sample projects?
  • Thursday, October 15, 2009 1:17 PMXingwei HuMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Has Code
    Hi Tj

    Do you wan to implement the Splash screens effect in your project, Splash screens are often used to display information to a user while an application is loading. Visual Basic provides a preconfigured Splash Screen form template that you can add to your Windows Application project, and a Splash Screen property in the Project Designer that allows you to specify a splash screen for your project.


    http://msdn.microsoft.com/en-us/library/bfkbc5a3(VS.80).aspx

    To add a splash screen template

    1. Select a project in Solution Explorer, and then on the Project menu, click Add New Item.

    2. In the Add New Item dialog box, select the Splash Screen template, and then click Add. The template is added to your project.

    To specify a splash screen

    1. Select a project in Solution Explorer, and then on the Project menu, click Properties.

    2. Click the Application tab.

    3. Under Windows application framework properties, in the Splash screen: list, click the form that you want to use as a splash screen.


      Well, you could make a sub routine in your splash screen form's class, that displays the message box.  That would ensure the message box is "owned" by the splash screen, so that it shows as a dialog in front of splash screen. Of course you might have to make a delegate sub to call it from, if your other code runs in a different thread than the splash screen form.Something like:

    Public Class SplashForm
    
    Sub DisplayMessage(byval Msg as string)
    
     Messagebox.Show(Msg)
    
    End Sub 
    End Class
    
    Module LoadModule
    
    ' This assumes you have a shared
    
    ' Instance of splashform named "MySplashForm".
    
    Try
    
      ' Work that can cause exception.
    
    Catch ex as exception
    
      If Not Mysplashform.IsDisposed Then
    
        MySplashForm.DisplayMessage(ex.tostring)
    
      End If
    
    End Try
    
    End Module
    
    
    Other reference:

    http://social.msdn.microsoft.com/Forums/en-US/vblanguage/thread/1103d880-de95-46d0-bcc4-5e14c3f2b127



    Best wishes
    Xingwei Hu



    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
  • Saturday, November 07, 2009 6:03 AMTj.. Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Has Code
    Hi Tj

    Do you wan to implement the Splash screens effect in your project, Splash screens are often used to display information to a user while an application is loading. Visual Basic provides a preconfigured Splash Screen form template that you can add to your Windows Application project, and a Splash Screen property in the Project Designer that allows you to specify a splash screen for your project.


    http://msdn.microsoft.com/en-us/library/bfkbc5a3(VS.80).aspx

    To add a splash screen template

    1. Select a project in Solution Explorer , and then on the Project menu, click Add New Item .

    2. In the Add New Item dialog box, select the Splash Screen template, and then click Add . The template is added to your project.

    To specify a splash screen

    1. Select a project in Solution Explorer , and then on the Project menu, click Properties .

    2. Click the Application tab.

    3. Under Windows application framework properties , in the Splash screen: list, click the form that you want to use as a splash screen.


      Well, you could make a sub routine in your splash screen form's class, that displays the message box.  That would ensure the message box is "owned" by the splash screen, so that it shows as a dialog in front of splash screen. Of course you might have to make a delegate sub to call it from, if your other code runs in a different thread than the splash screen form.Something like:

    Public
     Class
     SplashForm
    
    Sub
     DisplayMessage(byval
     Msg as
     string
    )
    
     Messagebox.Show(Msg)
    
    End
     Sub
     
    End
     Class
    
    
    Module
     LoadModule
    
    ' This assumes you have a shared
    
    
    ' Instance of splashform named "MySplashForm".
    
    
    Try
    
    
      ' Work that can cause exception.
    
    
    Catch
     ex as
     exception
    
      If
     Not
     Mysplashform.IsDisposed Then
    
    
        MySplashForm.DisplayMessage(ex.tostring)
    
      End
     If
    
    
    End
     Try
    
    
    End
     Module
    
    
    
    Other reference:

    http://social.msdn.microsoft.com/Forums/en-US/vblanguage/thread/1103d880-de95-46d0-bcc4-5e14c3f2b127



    Best wishes
    Xingwei Hu



    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.


    Read the thread I'm not asking for for a simple splash screen.
  • Saturday, November 07, 2009 10:04 AMDJ PIP Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Proposed Answer
    Hi everyone,

    I tried doing this and created a hook so that every-time I hit the 'Home' key on the keyboard, a windows form would load allowing me to pick a song.
    Unfortunately although this works when you are on the desktop or using a web-browser, the form's 'Top-Most' property even when set to true , has no effect with Direct X games.

    My form never appears above the game window and after searching on the subject I could never work out how to fix this.
    People suggested that you manually 'draw' on the screen although I have no knowledge on the subject.

    I hope this helps somewhat, and at the very least, if your trying to get your program to appear above a game like 'Halo: Combat Evolved', 'Call of Duty' or anything that is using Direct X , you can't use Windows Forms.

    :-(

    DJ PIP
    • Proposed As Answer byDJ PIP Saturday, November 07, 2009 10:05 AM
    •