Code: Select all
DispatchKeyValue(sprite, "classname", "env_sprite_oriented");
DispatchKeyValue(sprite, "spawnflags", "1");
DispatchKeyValue(sprite, "scale", "0.3");
DispatchKeyValue(sprite, "rendermode", "1");
DispatchKeyValue(sprite, "rendercolor", "255 255 255");
DispatchKeyValue(sprite, "model", OVERLAY);
if(DispatchSpawn(sprite)) return sprite;
GetClientAbsOrigin(client, origin);
origin[2] = origin[2] + 90.0;
TeleportEntity(entity, origin, NULL_VECTOR, NULL_VECTOR);
SetVariantString("!activator");
AcceptEntityInput(entity, "SetParent", client);
if(IsValidEntity(entity)) {
AcceptEntityInput(entity, "Kill");
}
following is what i have come up with but not sure if it'll work
Syntax: Select all
entity = BaseEntity(index)
sprite = BaseEntity(create_entity('env_sprite_oriented'))
sprite.spawnflags = 10
sprite.scale = 1
sprite.rendermode = 1
sprite.rendercolor = 255 255 255
sprite.model = model
PlayerEntity(index).location[1] + 90