MCPcopy Create free account
hub / github.com/GarageGames/Torque3D / markGroup

Method markGroup

Engine/source/console/consoleInternal.cpp:1357–1379  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1355}
1356
1357void Namespace::markGroup(const char* name, const char* usage)
1358{
1359 static U32 uid=0;
1360 char buffer[1024];
1361 char lilBuffer[32];
1362 dStrcpy(buffer, name);
1363 dSprintf(lilBuffer, 32, "_%d", uid++);
1364 dStrcat(buffer, lilBuffer);
1365
1366 Entry *ent = createLocalEntry(StringTable->insert( buffer ));
1367 trashCache();
1368
1369 if(usage != NULL)
1370 lastUsage = (char*)(ent->mUsage = usage);
1371 else
1372 ent->mUsage = lastUsage;
1373
1374 ent->mMinArgs = -1; // Make sure it explodes if somehow we run this entry.
1375 ent->mMaxArgs = -2;
1376
1377 ent->mType = Entry::GroupMarker;
1378 ent->cb.mGroupName = name;
1379}
1380
1381extern S32 executeBlock(StmtNode *block, ExprEvalState *state);
1382

Callers 1

markCommandGroupFunction · 0.80

Calls 4

dStrcpyFunction · 0.85
dSprintfFunction · 0.85
dStrcatFunction · 0.85
insertMethod · 0.45

Tested by

no test coverage detected