Raised This Month: $32 Target: $400
 8% 

TF2 Panel Help


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Nikey646
Member
Join Date: Apr 2011
Old 04-17-2011 , 12:35   TF2 Panel Help
Reply With Quote #1

Ok, so me and my friend are up at 2am, hitting our brains to figure out how to make a mod, we just want a simple mod that can produce a menu or panel (as i found out reading the wiki) that shows the server rules....so basicly, this is the code i used, thinking, that if the map changer can read a text file, chaning that a lil and to make it use panels, it could produce the contents of the text file.....

Code:
new Handle:g_MapMenu = INVALID_HANDLE
 
public OnPluginStart()
{
	RegConsoleCmd("Panel_Rules", Panel_Rules);
}
 
Handle:Buildrulepanel()
{
	new Handle:file = OpenFile("rules.txt", "rt");
	if (file == INVALID_HANDLE)
	{
		return INVALID_HANDLE;
	}

	new Handle:Panel = CreatePanel(Panel_Rules);
	CloseHandle(file);
 
	SetPanelTitle(Panel, "AussieDB Server Rules");
 
	return Panel;
}
i dont have a server to test this on (yet, working on getting it).

but, i can just tell, coding in a new language at 2am anit ganna work out properly....so i was wondering if someone could help me out with the above code alil.....

what its MENT to do, is upon a player typing ''rules'' into chat, it'll then produce a panel with a small prargraph describing the server rules....
Nikey646 is offline
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 04-17-2011 , 12:49   Re: TF2 Panel Help
Reply With Quote #2

Ask in SourceMod section.
__________________
hleV is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 04-17-2011 , 13:10   Re: TF2 Panel Help
Reply With Quote #3

Moved to SourceMod scripting section.
__________________
Arkshine is offline
Nikey646
Member
Join Date: Apr 2011
Old 04-17-2011 , 13:17   Re: TF2 Panel Help
Reply With Quote #4

Sorry, 2am, didnt notice the difference
Nikey646 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 04:20.


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