MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / GetMessage

Function GetMessage

scripts/LEVEL15.cpp:1609–1621  ·  view source on GitHub ↗

Find a message

Source from the content-addressed store, hash-verified

1607
1608// Find a message
1609const char *GetMessage(const char *name) {
1610 // Make sure given name is valid
1611 if (name == NULL)
1612 return INV_MSGNAME_STRING;
1613
1614 // Search message list for name
1615 for (int j = 0; j < num_messages; j++)
1616 if (strcmp(message_list[j]->name, name) == 0)
1617 return (message_list[j]->message);
1618
1619 // Couldn't find it
1620 return NO_MESSAGE_STRING;
1621}
1622
1623//======================
1624// Name List Arrays

Callers 2

GetMyMessageFunction · 0.70
InitializeDLLFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected