Raised This Month: $ Target: $400
 0% 

Model Menu


Post New Thread Reply   
 
Thread Tools Display Modes
siosios
SourceMod Donor
Join Date: Jan 2008
Old 06-08-2008 , 11:06   Re: Model Menu
Reply With Quote #151

moggiex,

our menu is setup properly. what natalya was trying to point out was that only our admin have the rights to use skins (per the group assignments) but if a regular user trys the cmd and selects an option not available to him or an admin selects the wrong option in the menu (look at my example below) then the menu will not come up again until after a map change... for anyone.

example cfg below:

Code:
//Configure your menu here
"Models"
{
 //Name of the item to appear in the menu
 "g0ds skins"
 {
  //Sourcemod admin group required to see/access this submenu
  "Admin"  "g0ds"
  //Models available for team 1 (terrorist / allies)
  "Team1"
  {
   //Name to appear in submenu
   "T Admin"
   {
    //path to the model file. This will automatically be precached
    "path"  "models/player/custom_plugin/t_sykoterror1_gizzmo/t_phoenix.mdl"
   }
  }
  //Models available for team 2 (ct / axis)
  "Team2"
  {
   "CT Admin"
   {
    "path"  "models/player/custom_plugin/ct_snake1_gizzmo/urban.mdl"
   } 
  }
 }
 "Admin-A skins"
 {
  //Sourcemod admin group required to see/access this submenu
  "Admin"  "admina"
  //Models available for team 1 (terrorist / allies)
  "Team1"
  {
   //Name to appear in submenu
   "T Admin"
   {
    //path to the model file. This will automatically be precached
    "path"  "models/player/custom_plugin/t_sykoterror1_gizzmo/t_phoenix.mdl"
   }
  }
  //Models available for team 2 (ct / axis)
  "Team2"
  {
   "CT Admin"
   {
    "path"  "models/player/custom_plugin/ct_snake1_gizzmo/urban.mdl"
   } 
  }
 }
 "Admin-b skins"
 {
  //Sourcemod admin group required to see/access this submenu
  "Admin"  "adminb"
  //Models available for team 1 (terrorist / allies)
  "Team1"
  {
   //Name to appear in submenu
   "T Admin"
   {
    //path to the model file. This will automatically be precached
    "path"  "models/player/custom_plugin/t_sykoterror1_gizzmo/t_phoenix.mdl"
   }
  }
  //Models available for team 2 (ct / axis)
  "Team2"
  {
   "CT Admin"
   {
    "path"  "models/player/custom_plugin/ct_snake1_gizzmo/urban.mdl"
   } 
  }
 }
 "Jr-Owner skins"
 {
  //Sourcemod admin group required to see/access this submenu
  "Admin"  "jrowners"
  //Models available for team 1 (terrorist / allies)
  "Team1"
  {
   //Name to appear in submenu
   "T Admin"
   {
    //path to the model file. This will automatically be precached
    "path"  "models/player/custom_plugin/t_sykoterror1_gizzmo/t_phoenix.mdl"
   }
  }
  //Models available for team 2 (ct / axis)
  "Team2"
  {
   "CT Admin"
   {
    "path"  "models/player/custom_plugin/ct_snake1_gizzmo/urban.mdl"
   } 
  }
 }
 
}
//All other files needed for the above models must be listed in modeldownloads.ini
//This forces the clients to download the needed files
thanks
siosios
__________________
siosios is offline
Cooltad
Veteran Member
Join Date: Apr 2008
Old 06-08-2008 , 12:11   Re: Model Menu
Reply With Quote #152

In case anyone cares, I figured out how to successfully have custom skins for weapons in TF2 in just my server, without overriding the users default skin.
I've just been too lazy to do all the work required for more than the wrench, lol.
Cooltad is offline
MoggieX
Veteran Member
Join Date: Aug 2007
Location: n00bville
Old 06-08-2008 , 16:18   Re: Model Menu
Reply With Quote #153

Quote:
Originally Posted by siosios View Post
moggiex,

our menu is setup properly. what natalya was trying to point out was that only our admin have the rights to use skins (per the group assignments) but if a regular user trys the cmd and selects an option not available to him or an admin selects the wrong option in the menu (look at my example below) then the menu will not come up again until after a map change... for anyone.

thanks
siosios
Just had a nose at the code and around line 192, its checking the users group access; Humour me on this, break it and then try sm_reloadadmins then try again (takes ~2 mins if you are using MySQL for admins)


Matt
__________________

Last edited by MoggieX; 06-08-2008 at 16:27.
MoggieX is offline
Send a message via Skype™ to MoggieX
Natalya[AF]
BANNED
Join Date: Oct 2007
Old 06-08-2008 , 18:35   Re: Model Menu
Reply With Quote #154

Okay we refreshed one of our servers with a map change, and the menu worked as expected. So, I went and tried to open the menu for an admin group that I'm not part of, and it broke it again, doing the whole no access message for
the menu groups, even the one I do have access to... So I did a sm_reloadadmins and waited a minute, but still no luck.

Note that we do use the Source Bans plugin so maybe that is conflicting?

Last edited by Natalya[AF]; 06-08-2008 at 18:38.
Natalya[AF] is offline
MoggieX
Veteran Member
Join Date: Aug 2007
Location: n00bville
Old 06-08-2008 , 19:51   Re: Model Menu
Reply With Quote #155

Quote:
Originally Posted by Natalya[AF] View Post
Okay we refreshed one of our servers with a map change, and the menu worked as expected. So, I went and tried to open the menu for an admin group that I'm not part of, and it broke it again, doing the whole no access message for
the menu groups, even the one I do have access to... So I did a sm_reloadadmins and waited a minute, but still no luck.

Note that we do use the Source Bans plugin so maybe that is conflicting?
Looks like the plugin needs to check the players access to each menu option, thus the ones they do not have access to are not shown, resolving the issue.

No idea on how to do that :-(

Matt
__________________
MoggieX is offline
Send a message via Skype™ to MoggieX
Natalya[AF]
BANNED
Join Date: Oct 2007
Old 06-08-2008 , 23:27   Re: Model Menu
Reply With Quote #156

Or make the models grayed out in the selection list so players can look in sections they don't have access for, but not select anything. Like the sm_super menu plugin... Maybe if the menu was designed like that in terms of access, relying on admin flags for skin access as opposed to groups or something. Iunno.

Last edited by Natalya[AF]; 06-09-2008 at 03:31.
Natalya[AF] is offline
siosios
SourceMod Donor
Join Date: Jan 2008
Old 06-09-2008 , 23:45   Re: Model Menu
Reply With Quote #157

anyone got the skills to fix this issue? would hate to have to use an ES script to be able to do this.

thanks
siosios
__________________
siosios is offline
Cooltad
Veteran Member
Join Date: Apr 2008
Old 06-10-2008 , 00:16   Re: Model Menu
Reply With Quote #158

Quote:
Originally Posted by MoggieX View Post
Looks like the plugin needs to check the players access to each menu option, thus the ones they do not have access to are not shown, resolving the issue.

No idea on how to do that :-(

Matt
Make a new type of admin flag assigned automatically to players, and change permissions of the menu etc with that flag.
Cooltad is offline
MoggieX
Veteran Member
Join Date: Aug 2007
Location: n00bville
Old 06-10-2008 , 05:16   Re: Model Menu
Reply With Quote #159

Quote:
Originally Posted by Cooltad View Post
Make a new type of admin flag assigned automatically to players, and change permissions of the menu etc with that flag.
Thats not the issue at hand, this is about the code not showing the menu option to players that should not see that option.

Matt
__________________
MoggieX is offline
Send a message via Skype™ to MoggieX
siosios
SourceMod Donor
Join Date: Jan 2008
Old 06-11-2008 , 01:53   Re: Model Menu
Reply With Quote #160

its pretty bad when my admin have to change the map to get it working again becuase one of the other admins decided to see what rights they had.
__________________
siosios 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 12:42.


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