Raised This Month: $51 Target: $400
 12% 

CSGO Progressbar


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Totenfluch
AlliedModders Donor
Join Date: Jan 2012
Location: Germany
Old 09-20-2016 , 12:51   CSGO Progressbar
Reply With Quote #1

Is it possible to change the Text that is displayed on a progressbar in csgo?


The Code bellow starts a 5s Progressbar.
PHP Code:
    SetEntPropFloat(clientProp_Send"m_flProgressBarStartTime"GetGameTime());
    
SetEntProp(clientProp_Send"m_iProgressBarDuration"5); 
__________________
Notable Projects:
Event Item Spawner | Scissors, Rock, Paper for ZephStore
tVip | Smart Link Remover
PLG & GGC - CS:GO Roleplay

and countless more...

I can make a helicopter shoot missles if you want me to...
Totenfluch is offline
Mitchell
~lick~
Join Date: Mar 2010
Old 09-20-2016 , 13:16   Re: CSGO Progressbar
Reply With Quote #2

I'm not sure about csgo since I haven't played with it before but you were able to create usermessages to send to the client that displayed custom messages.
https://forums.alliedmods.net/showth...light=progress
It's worth a shot, if that doesn't work then it may not be possible (hard-coded).
Mitchell is offline
Totenfluch
AlliedModders Donor
Join Date: Jan 2012
Location: Germany
Old 09-20-2016 , 13:49   Re: CSGO Progressbar
Reply With Quote #3

PHP Code:
L 09/20/2016 19:47:33"Totenfluch<2><STEAM_1:0:12277066><TERRORIST>" say "!testgui"
L 09/20/2016 19:47:33: [SMPlugin encountered error 21Native is not bound
L 09
/20/2016 19:47:33: [SMNative "BfWriteString" reported
L 09/20/2016 19:47:33: [SMDisplaying call stack trace for plugin "vguitest.smx":
L 09/20/2016 19:47:33: [SM]   [0]  Line 26test.sp::cmdOnTestGui() 
with

PHP Code:
public void OnPluginStart()
{
    
RegConsoleCmd("sm_testgui"cmdOnTestGui);
}

public 
Action cmdOnTestGui(int clientint args){
    new 
Handle:hBf Handle:StartMessageOne("VGUIMenu"client); 
    
BfWriteString(hBf"nav_progress");    // Panel name 

    
BfWriteChar(hBf0x01);    // 0x01 (SOH) - Use normal color from this point forward 
    
BfWriteChar(hBf0x03); // 0x03 (ETX) - Use team color from this point forward 
    
BfWriteString(hBf"msg"); // keyvalue name. Whole string would be "\x01\x03msg" in usermessage actually, thanks to above two characters. 

    
BfWriteString(hBf"My custom message"); // Message 
    
BfWriteString(hBf"total"); // keyvalue name 
    
BfWriteString(hBf"300"); // Max ticks in loading bar 
    
BfWriteString(hBf"current");// keyvalue name 
    
BfWriteString(hBf"30"); // Current loading bar status by ticks 
    
EndMessage();  

SourceMod 1.7.3-dev+5301, by AlliedModders LLC
__________________
Notable Projects:
Event Item Spawner | Scissors, Rock, Paper for ZephStore
tVip | Smart Link Remover
PLG & GGC - CS:GO Roleplay

and countless more...

I can make a helicopter shoot missles if you want me to...
Totenfluch is offline
Mitchell
~lick~
Join Date: Mar 2010
Old 09-20-2016 , 14:12   Re: CSGO Progressbar
Reply With Quote #4

You would need to convert it to protobuf messages.
Mitchell is offline
Totenfluch
AlliedModders Donor
Join Date: Jan 2012
Location: Germany
Old 09-20-2016 , 15:14   Re: CSGO Progressbar
Reply With Quote #5

Quote:
Originally Posted by Mitchell View Post
You would need to convert it to protobuf messages.
I have no idea what the "field" values for those keyvalues are. And the wiki is not that helpful tbh

Could you take some time and convert the code please?
__________________
Notable Projects:
Event Item Spawner | Scissors, Rock, Paper for ZephStore
tVip | Smart Link Remover
PLG & GGC - CS:GO Roleplay

and countless more...

I can make a helicopter shoot missles if you want me to...
Totenfluch is offline
Mitchell
~lick~
Join Date: Mar 2010
Old 09-20-2016 , 15:27   Re: CSGO Progressbar
Reply With Quote #6

If it's something like the motd panel here is an example:
https://wiki.alliedmods.net/Protobuf...essage_example
Mitchell is offline
Neuro Toxin
Veteran Member
Join Date: Oct 2013
Location: { closing the void; }
Old 09-20-2016 , 19:41   Re: CSGO Progressbar
Reply With Quote #7

Interesting. Im gonna give this a run in csgo at some point!
__________________
Neuro Toxin is offline
ESK0
BANNED
Join Date: May 2014
Location: Czech Republic
Old 10-03-2016 , 15:58   Re: CSGO Progressbar
Reply With Quote #8

Someone ported this to csgo ?
ESK0 is offline
Totenfluch
AlliedModders Donor
Join Date: Jan 2012
Location: Germany
Old 10-03-2016 , 18:20   Re: CSGO Progressbar
Reply With Quote #9

Quote:
Originally Posted by ESK0 View Post
Someone ported this to csgo ?
Do you want to use it for your private plugins again and not post the solution?

And Yes.
__________________
Notable Projects:
Event Item Spawner | Scissors, Rock, Paper for ZephStore
tVip | Smart Link Remover
PLG & GGC - CS:GO Roleplay

and countless more...

I can make a helicopter shoot missles if you want me to...
Totenfluch is offline
Mitchell
~lick~
Join Date: Mar 2010
Old 10-03-2016 , 18:40   Re: CSGO Progressbar
Reply With Quote #10

Quote:
Originally Posted by Totenfluch View Post
Do you want to use it for your private plugins again and not post the solution?

And Yes.
You are potentially doing what you're asking..
Mitchell is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:47.


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