All pastes #955346 Raw Edit

edude03

public text v1 · immutable
#955346 ·published 2008-03-24 15:46 UTC
rendered paste body
Module Module1
    'Because I have no idea what affect this will have lets define a card at the top
    Friend Class card
        Public Function getinfo() As String 'Need to work out a format, but this gets the information about the card,
            Dim test As String = {dr(0)}
            'Need to make this less abstract and return some important data
            Return test 'Whatever, to make it return a array use this:
            'Dim astr() As String = New String() {"Hello", "World"}
            'Return astr

        End Function
    End Class

    Public Class player
        Dim deck(60) As Integer
        Dim hand(7) As Integer 'Need to be a 2D array atleast so that we can store inforation on that card.
        Dim playarea(7, 6) As Integer 'Yes the play area
        ActiveCard(1, 6) As Integer '2D array, card number, and attached cards, this code needs refactoring already and 

        Public Class ActivePMK
            'it hasn't been written yet :(
        End Class
    End Class

    'Beginning of game
    Sub Main()

        'Set up the Variables,
        Dim i As Integer
        'dim PlayerName as string
        Dim gameinplay As Boolean
        Dim playername As Integer
        Dim CurrentPlayer As Integer

        'We need the code here to pick which player it is
        'Sets up player related activites
        Console.WriteLine("please enter your name")
        playername = Console.ReadLine()
        Dim myplayer As New player
        myplayer = New player()

        'Generate the deck
        For i = 0 To 59
            Dim RandomNumber As Integer
            RandomNumber = RandomNumber(1, 4086)
            myplayer.deck(i) = RandomNumber)
            player.deck(60) = player.deck(60) + 1 'Stores the number of cards in the deck
        Next i

        'Put card in players hand
        For i = 0 To 6
            player.hand(i) = player.deck(59 - i)) 'Moves the top seven cards from the deck
            'moves cards from the "bottom" of the deck, don't ask
            deck(59 - i) = 0
            deck(60) = deck(60) - 1
            'We need some code here to get the information on the card we are working on
            'card.getinfo()
        Next i



    End Sub

End Module