Not exactly sure if I'm posting this in the right section, but I've got a question about the particle effects on Unusual Hats.
Are there specific co-ordinates in which each effect is placed at?
The reason I'm asking is because I'm working on a plugin for a friends TF2 server and one of the features is the ability to give yourself any of the Unusual Hat particles.
Currently, in my coding, I've got the following:
stock Handle:CreateParticle(String:type[], Float:time, entity, attach=NO_ATTACH, Float:xOffs=0.0, Float:yOffs=0.0, Float:zOffs=0.0)
{
new particle = CreateEntityByName("info_particle_system");
if (IsValidEdict(particle)) {
decl Float:pos[3];
GetEntPropVector(entity, Prop_Send, "m_vecOrigin", pos);
pos[0] += xOffs;
pos[1] += yOffs;
pos[2] += zOffs;
TeleportEntity(particle, pos, NULL_VECTOR, NULL_VECTOR);
DispatchKeyValue(particle, "effect_name", type);
if (attach != NO_ATTACH) {
SetVariantString("!activator");
AcceptEntityInput(particle, "SetParent", entity, particle, 0);
if (attach == ATTACH_HEAD) {
SetVariantString("head");
AcceptEntityInput(particle, "SetParentAttachmentMaintainOffset", particle, particle, 0);
}
}
I realize this forum may not be the best place to ask about things relating to TF2 plugins made for AMX/SourceMod, but I figured since you guys do alot of work in regards to creating new weapons and such, you'd know what the exact particle placement co-ordinates are, and if the co-ordinates differ for each effect.
Currently, with the above code, the particle effects end up appearing on top of a players head, and I want to try to get the effects to appear in the same area that they would when wearing an actual Unusual Hat.
Any help would be greatly appreciated, and I apologize in advance if I've posted this in the wrong section.