| 661 | } |
| 662 | |
| 663 | static cell_t smn_PbAddString(IPluginContext *pCtx, const cell_t *params) |
| 664 | { |
| 665 | GET_MSG_FROM_HANDLE_OR_ERR(); |
| 666 | GET_FIELD_NAME_OR_ERR(); |
| 667 | |
| 668 | char *strValue; |
| 669 | pCtx->LocalToString(params[3], &strValue); |
| 670 | |
| 671 | if (!msg->AddString(strField, strValue)) |
| 672 | { |
| 673 | return pCtx->ThrowNativeError("Invalid field \"%s\" for message \"%s\"", strField, msg->GetProtobufMessage()->GetTypeName().c_str()); |
| 674 | } |
| 675 | |
| 676 | return 1; |
| 677 | } |
| 678 | |
| 679 | static cell_t smn_PbAddColor(IPluginContext *pCtx, const cell_t *params) |
| 680 | { |
nothing calls this directly
no test coverage detected