diff --git a/Sources/Plasma/CoreLib/HeadSpin.cpp b/Sources/Plasma/CoreLib/HeadSpin.cpp index 0fcb0b9b..c9fd08f7 100644 --- a/Sources/Plasma/CoreLib/HeadSpin.cpp +++ b/Sources/Plasma/CoreLib/HeadSpin.cpp @@ -216,22 +216,6 @@ void hsStatusMessageF(const char * fmt, ...) #endif -// TODO: Deprecate these in favor of plString -char * hsFormatStr(const char * fmt, ...) -{ - va_list args; - va_start(args,fmt); - char * result = hsFormatStrV(fmt,args); - va_end(args); - return result; -} - -char * hsFormatStrV(const char * fmt, va_list args) -{ - plString buf = plString::IFormat(fmt, args); - return hsStrcpy(buf.c_str()); -} - class hsMinimizeClientGuard { #ifdef CLIENT diff --git a/Sources/Plasma/CoreLib/HeadSpin.h b/Sources/Plasma/CoreLib/HeadSpin.h index ba1c21bb..74183f66 100644 --- a/Sources/Plasma/CoreLib/HeadSpin.h +++ b/Sources/Plasma/CoreLib/HeadSpin.h @@ -338,8 +338,6 @@ void SWAP (T & a, T & b) { char* hsStrcpy(char dstOrNil[], const char src[]); void hsStrLower(char *s); -char * hsFormatStr(const char * fmt, ...); // You are responsible for returned memory. -char * hsFormatStrV(const char * fmt, va_list args); // You are responsible for returned memory. inline char* hsStrcpy(const char src[]) { diff --git a/Sources/Plasma/CoreLib/hsTemplates.cpp b/Sources/Plasma/CoreLib/hsTemplates.cpp index 9ea60db1..408d3adc 100644 --- a/Sources/Plasma/CoreLib/hsTemplates.cpp +++ b/Sources/Plasma/CoreLib/hsTemplates.cpp @@ -43,39 +43,6 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com -//////////////////////////////////////////////////////////////////////////////// -// -//hsTempString::hsTempString(KStringFormatConstructor, char * fmt, ...) -//{ -// va_list args; -// va_start(args,fmt); -// fStr = hsFormatStrV(fmt,args); -// va_end(args); -//} -// -//hsTempString::hsTempString(KStringFormatVConstructor, char * fmt, va_list args) -//{ -// fStr = hsFormatStrV(fmt,args); -//} -// -//////////////////////////////////////////////////////////////////////////////// -//void hsTempStringF::Format(char * fmt, ...) -//{ -// delete [] fStr; -// va_list args; -// va_start(args,fmt); -// fStr = hsFormatStrV(fmt,args); -// va_end(args); -//} -// -//hsTempStringF::hsTempStringF(char * fmt, ...) -//{ -// va_list args; -// va_start(args,fmt); -// fStr = hsFormatStrV(fmt,args); -// va_end(args); -//} - ////////////////////////////////////////////////////////////////////////////// #ifdef HS_DEBUGTARRAY diff --git a/Sources/Plasma/CoreLib/hsTemplates.h b/Sources/Plasma/CoreLib/hsTemplates.h index 56a1e6b5..f25d4261 100644 --- a/Sources/Plasma/CoreLib/hsTemplates.h +++ b/Sources/Plasma/CoreLib/hsTemplates.h @@ -160,65 +160,6 @@ public: } }; -//////////////////////////////////////////////////////////////////////////////// -// -//// Like hsTempArray, but more useful when working with char * type arrays. -//enum KStringFormatConstructor {kFmtCtor}; -//enum KStringFormatVConstructor {kFmtVCtor}; -//class hsTempString -//{ -//public: -// char * fStr; -// hsTempString(): fStr(nil){} -// hsTempString(char * p) : fStr(p) {} -// hsTempString(const char * p) { fStr=hsStrcpy(p); } -// hsTempString(KStringFormatConstructor, char * fmt, ...); -// hsTempString(KStringFormatVConstructor, char * fmt, va_list args); -// hsTempString(const hsTempString & other):fStr(hsStrcpy(other.fStr)){} -// virtual ~hsTempString() { delete [] fStr; } -// hsTempString & operator=(char * ptr) -// { -// if (fStr!=ptr) -// { -// delete [] fStr; -// fStr=ptr; -// } -// return *this; -// } -// hsTempString & operator=(const hsTempString & other) -// { -// delete [] fStr; -// fStr=hsStrcpy(other.fStr); -// return *this; -// } -// operator char *() const { return fStr; } -// operator char *&() { return fStr; } -// operator const char *() const { return fStr; } -// operator bool() const { return fStr!=nil;} -// char * operator *() const { return fStr; } -// const char* c_str() const { return fStr; } -// char* c_str() { return fStr; } -//}; -// -//// shorthand -//typedef hsTempString tmpstr_t; -// -//class hsTempStringF : public hsTempString -//{ -//public: -// hsTempStringF(char * fmt, ...); -// void Format(char * fmt, ...); -// -// hsTempString & operator=(char * ptr) { return hsTempString::operator=(ptr); } -// hsTempString & operator=(const hsTempString & other) { return hsTempString::operator=(other); } -// hsTempString & operator=(const hsTempStringF & other) { return hsTempString::operator=(other); } -// operator char *() const { return fStr; } -// operator char *&() { return fStr; } -// operator const char *() const { return fStr; } -// operator bool() const { return fStr!=nil;} -// char * operator *() const { return fStr; } -//}; - ////////////////////////////////////////////////////////////////////////////// template class hsDynamicArray {