Results 1 to 2 of 2

Thread: Help with images in slot machine game

  1. #1

    Thread Starter
    Member
    Join Date
    Jul 2005
    Posts
    43

    Help with images in slot machine game

    I'm developing a slot machine game that is working pretty well but am battling with showing different bars as a winner.

    Roll(0) is the first image in the top row (3) the next and (6) the last in a row of three. Roll(0).Tag = 5 indicate triple bar picture with index = 5 in imagelist1
    Roll(0).Tag = 6 will be double bars and Roll(0).Tag = 7 single bars.

    Using the following to select 3 bars in top row
    '===3 Triple Bars - multiply by 120
    If Roll(0).Tag = 5 And Roll(3).Tag = 5 And Roll(6).Tag = 5 Then
    credits = BetCount(1).Caption * 120
    lblCredits.Caption = lblCredits.Caption + credits
    Exit Sub
    End If

    my problem is to indicate the row as a winner with a mix of triple bar, double bar and single bar. Can experts please help? Don't know if this explains it well enough. I am at [email protected] (that is in South Africa)

    The machine has got three winning rows rows so it makes for endless options to specify. Something like

    If Roll(0).Tag = 5 And Roll(3).Tag = 5 And Roll(6).Tag = 6 Then
    credits = BetCount(1).Caption * 120
    If Roll(0).Tag = 5 And Roll(3).Tag = 5 And Roll(6).Tag = 7 Then
    credits = BetCount(1).Caption * 120
    If Roll(0).Tag = 5 And Roll(3).Tag = 6 And Roll(6).Tag = 7 Then
    credits = BetCount(1).Caption * 120
    If Roll(0).Tag = 6 And Roll(3).Tag = 5 And Roll(6).Tag = 5 Then
    credits = BetCount(1).Caption * 120

    and on and on to specify all combinations of the three indexes

  2. #2
    Hyperactive Member singularis's Avatar
    Join Date
    Nov 2006
    Location
    Over There!
    Posts
    372

    Talking Re: Help with images in slot machine game

    Make a function that checks rows to see if they have been won. The function will need to take in three " Roll's " and you need to use the function everytime you check a winline.

    If you don't understand, ask and I will spoon feed you some code to help you but don't expect me to do it for you!
    If what I said was helpful, give me rep!

    My Complete Games: -- 2D Zone (Space Shooter game) || _2D Zone 2_ || Ninja Blob (2D platformer) || Dren (Co-op up to 4 player base defence game)

    My Projects: -- The Dread Engine (2D VB game Engine) || A* Path Finding


    An excellent site for learning DirectX7, 8 & 9 (for VB6, C# & VB.net) would be: directx4vb.vbgamer.com --- For my projects and games see: pieper.freehostia.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width