# General tidying.

Encryption: Deleted, just in case anyone was ever tempted to use it.
debug_warn: Removed redundant quotes around message.
oglCheck: Added error number to displayed messages, to help when
debugging errors.
Simulation: Fixed syntax confusion.
Entity: Preserve unit ID across entity-template changes (e.g. upgrades).
Atlas: Made some floating-point code less dodgy. Support number keys to
change player while placing units.

This was SVN commit r4814.
This commit is contained in:
Ykkrosh
2007-01-27 02:36:33 +00:00
parent 8a9ddae60b
commit adc8c64724
11 changed files with 72 additions and 158 deletions
+2 -5
View File
@@ -209,11 +209,8 @@ JSBool CEntity::Construct( JSContext* cx, JSObject* UNUSED(obj), uint argc, jsva
jsval CEntity::ToString( JSContext* cx, uintN UNUSED(argc), jsval* UNUSED(argv) )
{
wchar_t buffer[256];
swprintf( buffer, 256, L"[object Entity: %ls]", m_base->m_Tag.c_str() );
buffer[255] = 0;
utf16string str16(buffer, buffer+wcslen(buffer));
return( STRING_TO_JSVAL( JS_NewUCStringCopyZ( cx, str16.c_str() ) ) );
CStrW name( L"[object Entity: " + m_base->m_Tag + L"]" );
return( STRING_TO_JSVAL( JS_NewUCStringCopyZ( cx, name.utf16().c_str() ) ) );
}
jsval CEntity::JSI_GetPlayer()