sfml graphics

Hi I'm doing an assignment for my uni course and am stuck with using sfml I have to make a game of blackjack with graphics but the graphics will not show this is the main source code that I have so far:

Source files
useGameboard.cpp

#include <iostream>
#include <ctime>

void Shuffle(bool baCardsDealt[]);
void PrintCard(int iCard);
void PrintHand(int iaHand[], const int kiCardCount);
int GetNextCard(bool baCardsDealt[]);
int ScoreHand(int iaHand[], const int kiCardCount);
void PrintScoresAndHands(int iaHouseHand[], const int kiHouseCardCount, int iaPlayerHand[], const int kiPlayerCardCount);

int main() {
using namespace std;

// Seed the random number generator
time_t qTime;
time(&qTime);
srand(qTime);

bool baCardsDealt[52];
int iHouseCardCount = 0;
int iaHouseHand[12];
int iPlayerCardCount = 0;
int iaPlayerHand[12];

// Loop once for each hand
while (true) {

// "Shuffle" the cards; set them all to undealt
Shuffle(baCardsDealt);

// Deal the hands. Get two cards for each
iaPlayerHand[0] = GetNextCard(baCardsDealt);
iaHouseHand[0] = GetNextCard(baCardsDealt);
iaPlayerHand[1] = GetNextCard(baCardsDealt);
iaHouseHand[1] = GetNextCard(baCardsDealt);
iHouseCardCount = 2;
iPlayerCardCount = 2;

// Signal a new hand.
cout << "--------------------------------------------------------" << endl;
cout << "-----------------------New Hand-------------------------" << endl;
cout << "--------------------------------------------------------" << endl;

char cPlayerChoice;
bool bPlayerHits = true;
int iPlayerScore = ScoreHand(iaPlayerHand, iPlayerCardCount);

// Get Player's hits. Calculate the score and redisplay after each hit.
do {

// Print the dealt cards, but only the House's second card.
cout << "House's Hand" << endl;
cout << "** ";
PrintCard(iaHouseHand[1]);
cout << endl;
cout << "Player's Hand: Score = " << ScoreHand(iaPlayerHand, iPlayerCardCount) << endl;
PrintHand(iaPlayerHand, iPlayerCardCount);

// Ask the Player whether he wants a hit or to stay
cout << "Twist(t) or stick(s): ";
cin >> cPlayerChoice;
if (cPlayerChoice == 't') {
iaPlayerHand[iPlayerCardCount] = GetNextCard(baCardsDealt);
++iPlayerCardCount;
} else if (cPlayerChoice == 's') {
bPlayerHits = false;
} else {
cout << "Error: Try Again!" << endl;
}
cout << endl;

// Get the Player's current score to update and check for bust.
iPlayerScore = ScoreHand(iaPlayerHand, iPlayerCardCount);
} while (bPlayerHits && iPlayerScore < 22);

// Once the player is done taking hits, check whether he busted
if (iPlayerScore > 21) {

// The Player busted. The House wins.
cout << "**** The House Wins!!! ****" << endl;
PrintScoresAndHands(iaHouseHand, iHouseCardCount, iaPlayerHand, iPlayerCardCount);
} else {

// If the player didn't bust, then the house takes hits below 17
int iHouseScore = ScoreHand(iaHouseHand, iHouseCardCount);
while (iHouseScore < 17) {
iaHouseHand[iHouseCardCount] = GetNextCard(baCardsDealt);
++iHouseCardCount;
iHouseScore = ScoreHand(iaHouseHand, iHouseCardCount);
}
bool bHouseBusts = (iHouseScore > 21);
if (bHouseBusts) {

// The House busted. Player wins
cout << "**** The Player Wins!!! ****" << endl;
PrintScoresAndHands(iaHouseHand, iHouseCardCount, iaPlayerHand, iPlayerCardCount);
} else {

// Compare scores and determine the winner
if (iPlayerScore == iHouseScore) {

// Tie.
cout << "**** Tie!!! ****" << endl;
PrintScoresAndHands(iaHouseHand, iHouseCardCount, iaPlayerHand, iPlayerCardCount);
} else if (iPlayerScore > iHouseScore) {

// The Player wins
cout << "**** The Player Wins!!! ****" << endl;
PrintScoresAndHands(iaHouseHand, iHouseCardCount, iaPlayerHand, iPlayerCardCount);
} else {

// The House wins
cout << "**** The House Wins!!! ****" << endl;
PrintScoresAndHands(iaHouseHand, iHouseCardCount, iaPlayerHand, iPlayerCardCount);
}
}
}
}
return EXIT_SUCCESS;
}

void Shuffle(bool baCardsDealt[]) {
for (int iIndex = 0; iIndex < 52; ++iIndex) {
baCardsDealt[iIndex] = false;
}
}

void PrintCard(int iCard) {
using namespace std;

// Print Rank
const int kiRank = (iCard % 13);
if (kiRank == 0) {
cout << 'A';
} else if (kiRank < 9) {
cout << (kiRank + 1);
} else if (kiRank == 9) {
cout << 'T';
} else if (kiRank == 10) {
cout << 'J';
} else if (kiRank == 11) {
cout << 'Q';
} else {
cout << 'K';
}

// Print Suit
const int kiSuit = (iCard/13);
if (kiSuit == 0) {
cout << 'C';
} else if (kiSuit == 1) {
cout << 'D';
} else if (kiSuit == 2) {
cout << 'H';
} else {
cout << 'S';
}
}

void PrintHand(int iaHand[], const int kiCardCount) {
using namespace std;
for (int iCardIndex = 0; iCardIndex < kiCardCount; ++iCardIndex) {
const int kiNextCard = iaHand[iCardIndex];
PrintCard(kiNextCard);
cout << " ";
}
cout << endl;
}

int GetNextCard(bool baCardsDealt[]) {
bool bCardDealt = true;
int iNewCard = -1;
do {
iNewCard = (rand() % 52);
if (!baCardsDealt[iNewCard]) {
bCardDealt = false;
}
} while (bCardDealt);
return iNewCard;
}

int ScoreHand(int iaHand[], const int kiCardCount) {
int iAceCount = 0;
int iScore = 0;
for (int iCardIndex = 0; iCardIndex < kiCardCount; ++iCardIndex) {
const int kiNextCard = iaHand[iCardIndex];
const int kiRank = (kiNextCard % 13);
if (kiRank == 0) {
++iAceCount;
++iScore;
} else if (kiRank < 9) {
iScore = iScore + (kiRank + 1);
} else {
iScore = iScore + 10;
}
}
while (iAceCount > 0 && iScore < 12) {
--iAceCount;
iScore = iScore + 10;
}
return iScore;
}

void PrintScoresAndHands(int iaHouseHand[], const int kiHouseCardCount, int iaPlayerHand[], const int kiPlayerCardCount) {
using namespace std;
cout << "House's Hand: Score = " << ScoreHand(iaHouseHand, kiHouseCardCount) << endl;
PrintHand(iaHouseHand, kiHouseCardCount);
cout << "Player's Hand: Score = " << ScoreHand(iaPlayerHand, kiPlayerCardCount) << endl;
PrintHand(iaPlayerHand, kiPlayerCardCount);
cout << endl;
}

I do have other .cpp and header files which is where I have loaded in the images.
If someone can help me show the graphics loaded instead of just a black window with writing that would be much appreciated also if someone could tell me how to change the jack, queen and king so they are each worth 10 points thanks.
The most basic graphics tutorial is available on the SFML website - http://www.sfml-dev.org/tutorials/2.0/start-vc.php

Topic archived. No new replies allowed.