MCPcopy Create free account
hub / github.com/ClassiCube/ClassiCube / Entity_SetSkin

Function Entity_SetSkin

src/Entity.c:468–481  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

466}
467
468void Entity_SetSkin(struct Entity* e, const cc_string* skin) {
469 cc_string tmp; char tmpBuffer[STRING_SIZE];
470 DeleteSkin(e);
471
472 if (Utils_IsUrlPrefix(skin)) {
473 tmp = *skin;
474 e->NonHumanSkin = true;
475 } else {
476 String_InitArray(tmp, tmpBuffer);
477 String_AppendColorless(&tmp, skin);
478 e->NonHumanSkin = false;
479 }
480 String_CopyToRawArray(e->SkinRaw, &tmp);
481}
482
483void Entity_LerpAngles(struct Entity* e, float t) {
484 struct EntityLocation* prev = &e->prev;

Callers 3

LocalPlayer_InitFunction · 0.85
SkinCommand_ExecuteFunction · 0.85
AddEntityFunction · 0.85

Calls 3

DeleteSkinFunction · 0.85
Utils_IsUrlPrefixFunction · 0.85
String_AppendColorlessFunction · 0.85

Tested by

no test coverage detected