Skip to content

Commit a416613

Browse files
committed
Requested changes
1 parent 7f6a513 commit a416613

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

Client/core/CNickGen.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#include "time.h"
1212

1313
// These words are of a maximum length of 10 characters, capitalized, and stripped of whitespace
14-
const char* const CNickGen::m_szAdjectives[] = {
14+
const std::array<const char*, NICKGEN_NUM_ADJECTIVES> m_szAdjectives = {
1515
"Aback", "Abaft", "Abandoned", "Abashed", "Aberrant", "Abhorrent", "Abiding", "Abject", "Ablaze", "Able", "Abnormal",
1616
"Aboard", "Aboriginal", "Abortive", "Abounding", "Abrasive", "Abrupt", "Absent", "Absorbed", "Absorbing", "Abstracted", "Absurd",
1717
"Abundant", "Abusive", "Acceptable", "Accessible", "Accidental", "Accurate", "Acid", "Acidic", "Acoustic", "Acrid", "Actually",
@@ -106,10 +106,10 @@ const char* const CNickGen::m_szAdjectives[] = {
106106
"Warm", "Wary", "Wasteful", "Watery", "Weak", "Wealthy", "Weary", "Well-made", "Well-off", "Well-to-do", "Wet",
107107
"Whimsical", "Whispering", "White", "Whole", "Wholesale", "Wicked", "Wide", "Wide-eyed", "Wiggly", "Wild", "Willing",
108108
"Windy", "Wiry", "Wise", "Wistful", "Witty", "Woebegone", "Womanly", "Wonderful", "Wooden", "Woozy", "Workable",
109-
"Worried", "Worthless", "Wrathful", "Wretched", "Wrong", "Wry"
109+
"Worried", "Worthless", "Wrathful", "Wretched", "Wrong", "Wry",
110110
};
111111

112-
const char* const CNickGen::m_szNouns[] = {
112+
const std::array<const char*, NICKGEN_NUM_NOUNS> m_szNouns = {
113113
"Aardvark", "Buffalo", "Alligator", "Ant", "Anteater", "Antelope", "Ape", "Armadillo", "Donkey", "Baboon", "Badger",
114114
"Barracuda", "Bat", "Bear", "Beaver", "Bee", "Bison", "Boar", "Bush", "Butterfly", "Camel", "Calf",
115115
"Cat", "Kitten", "Cattle", "Chamois", "Cheetah", "Chicken", "Chick", "Chimpanzee", "Infant", "Empress", "Troop",
@@ -193,7 +193,7 @@ const char* const CNickGen::m_szNouns[] = {
193193
"Crook", "Hijacker", "Carjacker", "Villain", "Convict", "Fugitive", "Mug", "Outlaw", "Ruffian", "Cutthroat", "Devil",
194194
"Murderer", "Psycho", "Punk", "ASBO", "Offender", "Drifter", "Rioter", "Goon", "Roughneck", "Brute", "Hacker",
195195
"Cabbie", "Wheeler", "Driver", "Rider", "Cyclist", "Cowboy", "Operative", "Carrier", "Transporter", "Trucker", "Wheelman",
196-
"Vampire", "Parasite", "Tramp", "Bum", "Hobo", "Hitchhiker", "Deadbeat", "Acrobat"
196+
"Vampire", "Parasite", "Tramp", "Bum", "Hobo", "Hitchhiker", "Deadbeat", "Acrobat",
197197
};
198198

199199
SString CNickGen::GetRandomNickname()

Client/core/CNickGen.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
class CNickGen
1616
{
1717
public:
18-
static const char* const m_szAdjectives[NICKGEN_NUM_ADJECTIVES];
19-
static const char* const m_szNouns[NICKGEN_NUM_NOUNS];
18+
static const std::array<const char*, NICKGEN_NUM_ADJECTIVES> m_szAdjectives;
19+
static const std::array<const char*, NICKGEN_NUM_NOUNS> m_szNouns;
2020
static SString GetRandomNickname();
2121
};

0 commit comments

Comments
 (0)