|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 |
#include <iostream>
#include <conio.h>
#include <windows.h>
#include <string>
using namespace std;
int land;
#include "start.h"
#include "menu.h"
#include "charakter.h"
#include "NM_L8_Sektor1.h"
#include "farbe.h"
int main (int argc, char *argv[])
{
Start WarStart;
WarStart.startablauf();
while (land != 99)
{
switch (land)
{
case 1: break;
case 2: break;
case 3: break;
case 4: break;
case 5: break;
case 6: break;
case 7: break;
case 8: NM_L8_Sektor1 WarNML8S1; WarNML8S1.NM_L8_Sektor1ablauf(); break;
case 9: break;
case 10: break;
case 11: break;
case 12: break;
case 13: break;
case 14: cout << "Südmenschen"; break;
case 15: break;
case 16: break;
case 17: break;
case 18: cout << "Untote"; break;
case 19: break;
case 20: break;
case 21: break;
case 22: break;
case 23: break;
case 24: cout << "Trolle"; break;
case 25: break;
case 26: break;
case 27: break;
case 28: break;
case 29: break;
case 30: break;
case 31: break;
}
}
getch();
}
|
This post has been edited 1 times, last edit by "Jerome" (Jan 8th 2011, 10:47am)
)|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 |
// start.h
#ifndef __START_H
#define __START_H
#include <iostream>
using namespace std;
#include "menu.h"
#include "charakter.h"
#include "NM_L8_Sektor1.h"
#include "farbe.h"
class Start
{
public:
void startablauf()
{
Farbe WarFarbe;
WarFarbe.farbeblau();
cout << "\n\n\n\n\n\n\n\n War on the Battleground\n _______________________\n";
int zahl = 0;
while ( zahl != 20)
{
system ( "cls");
cout << "\n\n\n\n\n\n\n\n War on the Battleground\n _______________________\n";
zahl = zahl + 1;
}
int zahl2 = 0;
if ( zahl2 != 10)
{
system ( "cls");
cout << "\n\n\n\n\n\n\n War on the Battleground\n _______________________\n";
zahl2 = zahl2 + 1;
}
int zahl3 = 0;
if ( zahl3 != 10)
{
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
zahl3 = zahl3 + 1;
}
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (0%): ß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
int zahl4 = 0;
while ( zahl4 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (0%): ß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl4 = zahl4 + 1;
}
int zahl5 = 0;
while (zahl5 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
Farbe Warfarbe2;
Warfarbe2.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (10%): ßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl5 = zahl5 + 1;
}
int zahl6 = 0;
while ( zahl6 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (15%): ßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl6 = zahl6 + 1;
}
int zahl7 = 0;
while ( zahl7 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (20%): ßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl7 = zahl7 + 1;
}
int zahl8 = 0;
while ( zahl8 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (25%): ßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl8 = zahl8 + 1;
}
int zahl9 = 0;
while ( zahl9 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (30%): ßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl9 = zahl9 + 1;
}
int zahl10 = 0;
while ( zahl10 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (35%): ßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl10 = zahl10 + 1;
}
int zahl11 = 0;
while ( zahl11 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (40%): ßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl11 = zahl11 + 1;
}
int zahl12 = 0;
while ( zahl12 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
Farbe Warfarbe2;
Warfarbe2.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (45%): ßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl12 = zahl12 + 1;
}
|
This post has been edited 1 times, last edit by "Jerome" (Jan 8th 2011, 12:14pm)
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 |
int zahl13 = 0;
while ( zahl13 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
Farbe Warfarbe2;
Warfarbe2.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (50%): ßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl13 = zahl13 + 1;
}
int zahl14 = 0;
while ( zahl14 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
Farbe Warfarbe2;
Warfarbe2.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (55%): ßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl14 = zahl14 + 1;
}
int zahl15 = 0;
while ( zahl15 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (60%): ßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl15 = zahl15 + 1;
}
int zahl16 = 0;
while ( zahl16 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (65%): ßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl16 = zahl16 + 1;
}
int zahl17 = 0;
while ( zahl17 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
Farbe Warfarbe2;
Warfarbe2.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (70%): ßßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl17 = zahl17 + 1;
}
int zahl18 = 0;
while ( zahl18 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (75%): ßßßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl18 = zahl18 + 1;
}
int zahl19 = 0;
while ( zahl19 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
Farbe Warfarbe2;
Warfarbe2.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (80%): ßßßßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl19 = zahl19 + 1;
}
int zahl20 = 0;
while ( zahl20 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
Farbe Warfarbe2;
Warfarbe2.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (85%): ßßßßßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl20 = zahl20 + 1;
}
int zahl21 = 0;
while ( zahl21 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (90%): ßßßßßßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl21 = zahl21 + 1;
}
int zahl22 = 0;
while ( zahl22 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (95%): ßßßßßßßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl22 = zahl22 + 1;
}
int zahl23 = 0;
while ( zahl23 != 3)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (100%): ßßßßßßßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl23 = zahl23 + 1;
}
int zahl01 = 0;
while ( zahl01 != 2)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (100%):";
WarFarbe.farbeblau();
cout << "ßßßßßßßßßßßßßßßßßßß ";
WarFarbe.farbegrün();
cout << " ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl01 = zahl01 + 1;
}
int zahl02 = 0;
while ( zahl02 != 2)
{
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (100%): ßßßßßßßßßßßßßßßßßßß ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
zahl02 = zahl02 +1;
}
WarFarbe.farbeblau();
system ( "cls");
cout << "\n\n\n\n\n\n War on the Battleground\n _______________________\n\n\n";
WarFarbe.farbegrün();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß ß\n";
cout << " ß Loading (100%):";
WarFarbe.farbeblau();
cout << "ßßßßßßßßßßßßßßßßßßß ";
WarFarbe.farbegrün();
cout << " ß\n";
cout << " ß ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß\n\n\n";
int nichts;
WarFarbe.farberot();
cout << " Bitte etwas tippen!\n";
cout << " ";
cin >> nichts;
Menu WarMenu;
WarMenu.menuablauf();
};
};
#endif
|
This post has been edited 1 times, last edit by "Jerome" (Jan 8th 2011, 12:15pm)
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 |
//menu.h
#ifndef __MENU_H
#define __MENU_H
#include <iostream>
using namespace std;
#include "start.h"
#include "charakter.h"
#include "NM_L8_Sektor1.h"
#include "farbe.h"
class Menu{
public:
void menuablauf()
{
system ("cls");
Farbe Warfarbe;
Warfarbe.farberot();
cout << "\n";
cout << " Willkommen zu War on the Battleground!\n";
cout << " ______________________________________\n\n\n\n";
cout << " Menu\n";
cout << " ________\n\n";
Warfarbe.farbeweiss();
cout << " 1:Spiel starten\n";
cout << " 2:Spiel laden\n";
cout << " 3:Spiel beenden\n";
int menu;
cout << " ";
cin >> menu;
int fraktionswahl;
switch (menu)
{
case 1:
system ("cls");
Warfarbe.farberot();
cout << "\n";
cout << " Willkommen zu War on the Battleground!\n";
cout << " ______________________________________\n\n\n\n";
cout << " Einen neuen Charakter erstellen...\n\n\n";
Warfarbe.farbeblau();
cout << " Waehlen Sie Ihre Fraktion!\n\n";
Warfarbe.farbeweiss();
cout << " 1:Rebellen\n";
cout << " 2:Menschen\n";
cout << " ";
cin >> fraktionswahl;
break;
case 2:
system ("cls");
cout << " Funktion noch nicht verfuegbar!\n";
cout << " 1:Menu\n";
cout << " ";
cin >> menu;
Menu Warmenu;
Warmenu.menuablauf();
break;
case 3:
system ("cls");
cout << "\n\n Das Programm wird geschlossen...\n";
exit(1);
break;
}
int menuorstory;
switch (fraktionswahl)
{
case 1:
fraktion = "Rebellen";
system ("cls");
Warfarbe.farberot();
cout << "\n";
cout << " Willkommen zu War on the Battleground!\n";
cout << " ______________________________________\n\n\n\n";
cout << " Einen neuen Charakter erstellen...\n\n\n";
Warfarbe.farbeblau();
cout << " Geben Sie den Namen Ihres Heldens ein!\n\n";
Warfarbe.farbeweiss();
cout << " ";
cin >> charname;
system ("cls");
Warfarbe.farberot();
cout << "\n";
cout << " Willkommen zu War on the Battleground!\n";
cout << " ______________________________________\n\n\n\n";
cout << " Einen neuen Charakter erstellen...\n\n\n";
Warfarbe.farbeblau();
cout << " " << charname << " lvl 1 Troll.\n\n";
Warfarbe.farbeweiss();
cout << " 1:Welt betreten\n";
cout << " 2:Menu\n";
cout << " ";
cin >> menuorstory;
break;
case 2:
fraktion = "Menschen";
system ("cls");
Warfarbe.farberot();
cout << "\n";
cout << " Willkommen zu War on the Battleground!\n";
cout << " ______________________________________\n\n\n\n";
cout << " Einen neuen Charakter erstellen...\n\n\n";
Warfarbe.farbeblau();
cout << " Geben Sie den Namen Ihres Heldens ein!\n\n";
Warfarbe.farbeweiss();
cout << " ";
cin >> charname;
system ("cls");
Warfarbe.farberot();
cout << "\n";
cout << " Willkommen zu War on the Battleground!\n";
cout << " ______________________________________\n\n\n\n";
cout << " Einen neuen Charakter erstellen...\n\n\n";
Warfarbe.farbeblau();
cout << " " << charname << " lvl 1 Nordmensch.\n\n";
Warfarbe.farbeweiss();
cout << " 1:Welt betreten\n";
cout << " 2:Menu\n";
cout << " ";
cin >> menuorstory;
break;
}
switch (menuorstory)
{
case 1:
if (fraktion == "Rebellen")
{
}
if (fraktion == "Menschen")
{
land = 8;
}
break;
case 2:
Menu Warmenu;
Warmenu.menuablauf();
break;
}
};
};
#endif
|
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
//charakter.h
#ifndef __CHARAKTER_H
#define __CHARAKTER_H
using namespace std;
#include "NM_L8_Sektor1.h"
#include "start.h"
#include "menu.h"
#include "farbe.h"
// Charakterwerte
string charname;
int chardamage = 20;
int charleben = 50;
int charruestung = 0;
int charmana = 100;
//Allgemein
string fraktion;
string klasse;
class Statusbar
{
public:
void statusbaraufruf()
{
Farbe Statusfarbe;
Statusfarbe.farbeweiss();
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
cout << " ß " << charname << "\n";
cout << " ß ";
Statusfarbe.farberot();
cout << "HP: " << charleben << "\n";
Statusfarbe.farbeweiss();
cout << " ß ";
Statusfarbe.farbeblau();
cout << "MP: " << charmana << "\n";
Statusfarbe.farbeweiss();
cout << " ß\n";
cout << " ßßßßßßßßßßßßßßßßßßßßßßßßßßß\n";
};
};
#endif
|
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
// NM_L8_Sektor1.h
#ifndef __NM_L8_SEKTOR1_H
#define __NM_L8_SEKTOR1_H
using namespace std;
#include "start.h"
#include "menu.h"
#include "charakter.h"
#include "farbe.h"
class NM_L8_Sektor1 {
public:
void NM_L8_Sektor1ablauf(){
int weiter;
system ("cls");
Statusbar WarStatus;
WarStatus.statusbaraufruf();
Farbe WarFarbe;
WarFarbe.farberot();
cout << "\n\n\n\n Ihr befindet euch im Lager der Nordmenschen\n\n";
WarFarbe.farbeblau();
cout << " Ihr steht vor Halur dem Rekrutenausbildner";
cin >> weiter;
};
};
#endif
|

|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
#ifndef __FARBE_H
#define __FARBE_H
#include <iostream>
#include "start.h"
#include "menu.h"
#include "charakter.h"
#include "NM_L8_Sektor1.h"
using namespace std;
class Farbe{
public:
void farbeblau(){
HANDLE hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
SetConsoleTextAttribute(
hStdout,
FOREGROUND_BLUE | FOREGROUND_BLUE | FOREGROUND_INTENSITY
);
};
void farberot(){
HANDLE hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
SetConsoleTextAttribute(
hStdout,
FOREGROUND_RED | FOREGROUND_RED | FOREGROUND_INTENSITY
); };
void farbeweiss(){
HANDLE hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
SetConsoleTextAttribute(
hStdout,
FOREGROUND_BLUE| FOREGROUND_GREEN | FOREGROUND_RED| FOREGROUND_INTENSITY
); };
void farbegrau(){
HANDLE hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
SetConsoleTextAttribute(
hStdout,
FOREGROUND_GREEN| FOREGROUND_GREEN | FOREGROUND_GREEN |FOREGROUND_INTENSITY
); };
void farbegrün(){
HANDLE hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
SetConsoleTextAttribute(
hStdout,
FOREGROUND_GREEN| FOREGROUND_GREEN|FOREGROUND_INTENSITY
); };
};
#endif
|
|
|
Source code |
1 2 3 4 5 6 7 |
In file included from charakter.h:5:0,
from menu.h:7,
from start.h:6,
from main.cpp:7:
NM_L8_Sektor1.h: In member function 'void NM_L8_Sektor1::NM_L8_Sektor1ablauf()':
NM_L8_Sektor1.h:19:3: error: 'Statusbar' was not declared in this scope
|