AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Deleting SVC_TEMPENTITY (https://forums.alliedmods.net/showthread.php?t=251718)

hleV 11-18-2014 03:49

Deleting SVC_TEMPENTITY
 
Is there a way to delete a TE? With a help of a module perhaps?

An example of why this is needed:
  • Show a HUD message with a fade-in time (e.g. fade-in time: 1.5, hold time: 9999.9).
  • Wait for the text to fade in.
  • Show another HUD message with fade-in time on the same channel: the HUD message starts out already faded in, likely because the previous message hasn't ended yet.
I suspect that deleting the previous HUD message's TE could solve this.

.Dare Devil. 11-18-2014 12:14

Re: Deleting SVC_TEMPENTITY
 
There's one message for clearing hud but it clears everything ( weapon icons, timer etc... )
I see one way, sent hudmessage with 0.0 delay ( fadein,fadeout,hold,fx = 0.0 ) ( it will clear the screen ) then sent your hudmessage.
The delay between clear hudmessage and new hudmessage should be something 0.05 - 0.1 sec
It depends on the ping that client is having.

Thats how i made my costom menu color plugin.
You can get the code here: https://forums.alliedmods.net/showthread.php?t=250788
Unfinished zsparkle mod and menu.zs ( open that with any txt editor )

Edit: there's no other proper way to clean hudmessages ... sadly.
Messing with that message ( hudreset or something was it called ) will be really painful since when you pick up the weapon for example ... that icon appears in right side of the screen and after hudreset message it will disappear and you can't make it appear back on its original state ( fade or color )

Jhob94 11-18-2014 12:24

Re: Deleting SVC_TEMPENTITY
 
Quote:

Originally Posted by .Dare Devil. (Post 2225705)
I see one way, sent hudmessage with 0.0 delay ( fadein,fadeout,hold,fx = 0.0 ) ( it will clear the screen ) then sent your hudmessage.

You mean this?
HUD 1 -> HUD 2 -> HUD 3

1- current hud
2- hud with 0.0 delays
3- new hud

hleV 11-18-2014 16:15

Re: Deleting SVC_TEMPENTITY
 
Quote:

Originally Posted by .Dare Devil. (Post 2225705)
The delay between clear hudmessage and new hudmessage should be something 0.05 - 0.1 sec

Not an option for me, sadly. I need it to be instanteanous.


All times are GMT -4. The time now is 17:38.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.