Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NeedHelp] Not possible to spawn a decal dynamically? #500

Open
joleman11 opened this issue Jun 15, 2024 · 1 comment
Open

[NeedHelp] Not possible to spawn a decal dynamically? #500

joleman11 opened this issue Jun 15, 2024 · 1 comment
Labels
untriaged New issue has not been triaged

Comments

@joleman11
Copy link

joleman11 commented Jun 15, 2024

Non-working pseudocode:

CProjectedDecal decalEnt = Utilities.CreateEntityByName<CProjectedDecal>("info_projecteddecal");
decalEnt.Texture = 0 // How do you get/set the texture id?
decalEnt.Distance = 64.0f;
decalEnt.Teleport(
    new Vector(
        pawn!.AbsOrigin!.X,
        pawn!.AbsOrigin!.Y,
        pawn!.AbsOrigin!.Z
    ),
    pawn!.EyeAngles,
    new Vector(0.0f, 0.0f, 0.0f)
);
decalEnt.DispatchSpawn(); // Crashes server instantly
decalEnt.AcceptInput("Activate"); // Needed in the hammer editor for the decal to appear.
@github-actions github-actions bot added the untriaged New issue has not been triaged label Jun 15, 2024
@KillStr3aK
Copy link
Contributor

not sure if related but might work with #615

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
untriaged New issue has not been triaged
Projects
None yet
Development

No branches or pull requests

2 participants