AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   CSDM (https://forums.alliedmods.net/forumdisplay.php?f=87)
-   -   Restrict weapons for certain maps (https://forums.alliedmods.net/showthread.php?t=46144)

mad_maniac_man 09-14-2010 14:25

Re: Restrict weapons for certain maps
 
Hey guys im a noob with amx. I managed to get csdm working ok with the gun menu etc. But like Darknightcze2 i also want to fix the awp maps so that you auto get a deagle and awp and cant buy anything else. I tried all the above that you said and i still cant get it to work. It will still say awp limit reached when i drop my awp and i cannot pick another one up untill i kill another bot. Even with the sniper commands at the end of the amxx.cfg file adjusted once im in the game it reverts to the default settings. Any ideas as ive spent days not getting any results.

*UPDATE*

Just incase you dont understand here is the error log:

L 09/15/2010 - : -------- Mapchange to awp_bycastor32 --------
L 09/15/2010 - : [AMXX] Plugin "admin.amxx" failed to load: Plugin uses an unknown function (name "admins_lookup") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "admincmd.amxx" failed to load: Plugin uses an unknown function (name "LookupLangKey") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "telemenu.amxx" failed to load: Plugin uses an unknown function (name "LookupLangKey") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "mapsmenu.amxx" failed to load: Plugin uses an unknown function (name "ArrayPushString") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "pluginmenu.amxx" failed to load: Plugin uses an unknown function (name "set_pcvar_string") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "imessage.amxx" failed to load: Plugin uses an unknown function (name "ArrayPushArray") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "adminvote.amxx" failed to load: Plugin uses an unknown function (name "LookupLangKey") - check your modules.ini.
L 09/15/2010 - : [csdm_spawn_preset.amxx] No spawn points file found (addons/amxmodx/configs\csdm\awp_bycastor32.spawns.cfg)
L 09/15/2010 - : [csdm_main.amxx] CSDM spawn mode set to preset
L 09/15/2010 - : [csdm_itemmode.amxx] "//" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "max_awps" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "max_autos" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "winspread_awp" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "winspread_auto" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "autolimit" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "awplimit" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "checkrebuy" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] No items file found (addons/amxmodx/configs\csdm\items\ents_awp_bycastor32.cfg)
L 09/15/2010 - : [maphandler06.amxx] Starting map: awp_bycastor32
L 09/15/2010 - : [maphandler06.amxx] About to write to addons/amxmodx/data/maphandler.dat.
L 09/15/2010 - : [mapchooser4.amxx] Found 17 maps in maps folder
L 09/15/2010 - : [mapchooser4.amxx] xvars for mapchooser 4 setuped.
L 09/15/2010 - : -------- Mapchange to awp_bycastor32 --------
L 09/15/2010 - : [AMXX] Plugin "admin.amxx" failed to load: Plugin uses an unknown function (name "admins_lookup") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "admincmd.amxx" failed to load: Plugin uses an unknown function (name "LookupLangKey") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "telemenu.amxx" failed to load: Plugin uses an unknown function (name "LookupLangKey") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "mapsmenu.amxx" failed to load: Plugin uses an unknown function (name "ArrayPushString") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "pluginmenu.amxx" failed to load: Plugin uses an unknown function (name "set_pcvar_string") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "imessage.amxx" failed to load: Plugin uses an unknown function (name "ArrayPushArray") - check your modules.ini.
L 09/15/2010 - : [AMXX] Plugin "adminvote.amxx" failed to load: Plugin uses an unknown function (name "LookupLangKey") - check your modules.ini.
L 09/15/2010 - : [csdm_spawn_preset.amxx] No spawn points file found (addons/amxmodx/configs\csdm\awp_bycastor32.spawns.cfg)
L 09/15/2010 - : [csdm_main.amxx] CSDM spawn mode set to preset
L 09/15/2010 - : [csdm_itemmode.amxx] "//" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "max_awps" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "max_autos" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "winspread_awp" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "winspread_auto" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "autolimit" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "awplimit" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] "checkrebuy" is not a valid name. Check your restrictions for item mode.
L 09/15/2010 - : [csdm_itemmode.amxx] No items file found (addons/amxmodx/configs\csdm\items\ents_awp_bycastor32.cfg)
L 09/15/2010 - : [maphandler06.amxx] Starting map: awp_bycastor32
L 09/15/2010 - : [maphandler06.amxx] About to write to addons/amxmodx/data/maphandler.dat.
L 09/15/2010 - : [mapchooser4.amxx] Found 17 maps in maps folder
L 09/15/2010 - : [mapchooser4.amxx] xvars for mapchooser 4 setuped.

KWo 09-16-2010 08:04

Re: Restrict weapons for certain maps
 
I believe You are using some of my All-In-One packages with plugins I'm supporting (mapchooser4, maphandler06, sniperlimit etc). Form that what I can see from Your logs You have some troubles with loading even standard (original) AMX X plugins (like admin, admincmd, pluginmenu, imessage etc). That menas You may need to compile that locally against the AMX X version You are currently using.
About max_awps , max_autos, winspread_awp, winspread_auto, autolimit, awplimit, checkrebuy settings - they are for sniperlimit plugin and they have nothing to do to CSDM. If You want to disable this plugin for awp_xxx maps, all You need to do is put the settings for them in amxx.cfg (like for normal maps), but then - in amxmodx/configs/maps/prefix_awp.cfg You should just write
awplimit 0
autolimit 0

That should disable sniperlimit plugin working on awp maps, but it should work normaly on others.

Log messages You provided here about those settings are telling me one thing - You have put them in wrong place (I believe in amxmodx\configs\csdm\extraconfigs\ in some awp_xxx.cfg file and in section [items] or [item_restrictions]. But as I said - those settings have nothing to do with CSDM nor itemomode of CSDM - so they shouldn't be there.

mad_maniac_man 09-16-2010 11:40

Re: Restrict weapons for certain maps
 
#1 "If You want to disable this plugin for awp_xxx maps, all You need to do is put the settings for them in amxx.cfg"

The bottom of my amxx.cfg file reads:

// ***********************
// Custom plugin settings
// ***********************

// gore plugin
// a - Headshot blood
// b - Extra blood effects
// c - Bleeding on low health
// d - Gib explosion (knife, HE, high damage only)
amx_gore ab

// mapchooser4

amx_mapchooser_type 1
amx_mapchooser_mapsfile maps.ini
amx_nominfromfile 0
amx_maxnominperplayer 2
amx_map_history 5

amx_rtv 1
amx_rtv_percent 0.6
amx_rtv_min_time 10

amx_extendmap_max 5
amx_extendmap_step 3
amx_ext_round_max 5
amx_ext_round_step 3
amx_ext_win_max 5
amx_ext_win_step 3

// sniperlimit
max_awps 90
max_autos 90
winspread_awp 0
winspread_auto 0
autolimit 0
awplimit 0
checkrebuy 1

Correct me if im wrong.

#2 "Log messages You provided here about those settings are telling me one thing - You have put them in wrong place (I believe in amxmodx\configs\csdm\extraconfigs\ in some awp_xxx.cfg file and in section [items] or [item_restrictions]. But as I said - those settings have nothing to do with CSDM nor itemomode of CSDM - so they shouldn't be there."

Where should they be then ? As I really want to solve the awp maps problem. All i want is auto awp and auto deagle for every player/bot and to restrict buying completely.

*Update*

I found the compile thingy in scripting folder and used the .exe seems to have fixed somethings as there is less in the error log. Take a look for yourself:

L 09/16/2010 - 17:00:16: -------- Mapchange to awp_bycastor32 --------
L 09/16/2010 - 17:00:16: [AMXX] Plugin "pluginmenu.amxx" failed to load: Plugin uses an unknown function (name "set_pcvar_string") - check your modules.ini.
L 09/16/2010 - 17:00:16: [AMXX] Plugin "csdm_stripper.amxx" failed to load: Plugin uses an unknown function (name "csdm_write_cfg") - check your modules.ini.
L 09/16/2010 - 17:00:17: [csdm_spawn_preset.amxx] No spawn points file found (addons/amxmodx/configs\csdm\awp_bycastor32.spawns.cfg)
L 09/16/2010 - 17:00:17: [csdm_main.amxx] CSDM spawn mode set to preset
L 09/16/2010 - 17:00:18: [maphandler06.amxx] Starting map: awp_bycastor32
L 09/16/2010 - 17:00:18: [maphandler06.amxx] About to write to addons/amxmodx/data/maphandler.dat.
L 09/16/2010 - 17:00:18: [mapchooser4.amxx] Found 17 maps in maps folder
L 09/16/2010 - 17:00:25: [CSDM2] Could not read config file: cstrike\addons\amxmodx\configs\csdm\extraconf igs\items_awp_byca
L 09/16/2010 - 17:00:25: [mapchooser4.amxx] xvars for mapchooser 4 setuped.

I think it has fixed the awp limiting problem and buying seems to be restricted. The few things above I have no idea about. And I think that leaves the last thing to be fixed for everyone to have a deagle by default(auto).

Cheers for your help and patience with me so far mate,

Your padawan,

mad_maniac_man

KWo 09-16-2010 14:54

Re: Restrict weapons for certain maps
 
Quote:

Originally Posted by mad_maniac_man (Post 1300912)
L 09/16/2010 - 17:00:16: [AMXX] Plugin "csdm_stripper.amxx" failed to load: Plugin uses an unknown function (name "csdm_write_cfg") - check your modules.ini.

That means - more than likely - You are using original CSDM module with my stripper plugin. You should use CSDM module (csdm_amxx.dll or csdm_amxx_i386.so) provided by me in beta package (or in All-In-One package - they are the same).

mad_maniac_man 09-17-2010 03:59

Re: Restrict weapons for certain maps
 
Quote:

Originally Posted by KWo (Post 1301066)
That means - more than likely - You are using original CSDM module with my stripper plugin. You should use CSDM module (csdm_amxx.dll or csdm_amxx_i386.so) provided by me in beta package (or in All-In-One package - they are the same).

Yeah I tried the csdm module in your all-in-one package and it still gave me the same error log.

How do i set it that everyone gets a deagle automatically on all awp maps ?

Andy.

KWo 09-17-2010 14:08

Re: Restrict weapons for certain maps
 
CSDM can only automatically equip player with grenades or armor, but it doesn't automatically equip them with any primary or secondary weapon. The only thing You can do with CSDM is to let players have in their gun menu only deagle available (but the players still have to choose it from the gun menu) for awp maps. You may need to create in addons\configs\maps\prefix-awp.cfg with this line:
Code:

csdm_reload "csdm\extraconfigs\guns_awp.cfg"
Then - in addons\configs\csdm\extraconfigs\guns_awp.cfg You should write such lines:

Code:

[secondary]
usp USP 0
glock18 Glock 0
deagle Deagle 1
p228 P228 0
elite Elite 0
fiveseven "Five Seven" 0

[primary]
m4a1 M4A1 0
ak47 AK47 0
aug AUG 0
sg552 SG552 0
galil Galil 0
famas Famas 0
scout Scout 0
awp AWP 0
sg550 SG550 0
m249 M249 0
g3sg1 G3SG1 0
ump45 "UMP 45" 0
mp5navy "MP5 Navy" 0
m3 M3 0
xm1014 XM1014 0
tmp TMP 0
mac10 "Mac 10" 0
p90 P90 0

[botsecondary]
deagle

[botprimary]

You can also try to make the section [primary] empty.

mad_maniac_man 09-19-2010 15:22

Re: Restrict weapons for certain maps
 
Ahh right ok that makes sense mate. Ok scrap that how do I go about making csdm to automatically equip players with grenades and full armor then ?

KWo 09-20-2010 06:22

Re: Restrict weapons for certain maps
 
Quote:

Originally Posted by mad_maniac_man (Post 1303591)
Ok scrap that how do I go about making csdm to automatically equip players with grenades and full armor then?

Do You mean on all maps or only on awp maps?
If on all maps, then You need to have these lines in csdm.cfg:
Code:

[equip]
;Equip Menu flags:
; p - primary
; s - secondary
; a - armor
; g - grenade
; b - buy
menus = ps

;Autoitem flags:
; a - armor
; h - helmet
; g - grenades
; d - defusekit (CTs only!)
; n - nightvision
autoitems = ahg

;Grenade flags:
; f - flashbang
; h - he grenade
; s - smoke grenade
grenades = fhs

;Sets number of flashbangs given if
; grenades are enabled
fnadesnum = 2

If You are just talking about awp maps - then You should have those above lines in guns_awp.cfg file.

Remember - in guns_awp.cfg file You should have to have only settings for differences between normal maps and awp maps (don't write there everything).

Example - on normal maps You want to let the player choose everyting from gun menus, but no flashbangs:
The responsible part of csdm.cfg looks like:
Code:

[equip]
;Equip Menu flags:
; p - primary
; s - secondary
; a - armor
; g - grenade
; b - buy
menus = psag

;Autoitem flags:
; a - armor
; h - helmet
; g - grenades
; d - defusekit (CTs only!)
; n - nightvision
autoitems =

;Grenade flags:
; f - flashbang
; h - he grenade
; s - smoke grenade
grenades = hs

But for awp maps You want to have players automatically equiped with nades (including flashbang), armor and helmet, but no primary weapon menu (only secondary). Then the whole guns_awp.cfg file looks like:
Code:

[equip]
;Equip Menu flags:
; p - primary
; s - secondary
; a - armor
; g - grenade
; b - buy
menus = s

;Autoitem flags:
; a - armor
; h - helmet
; g - grenades
; d - defusekit (CTs only!)
; n - nightvision
autoitems = ahg

;Grenade flags:
; f - flashbang
; h - he grenade
; s - smoke grenade
grenades = fhs

Instead asking - just read the config and play a bit with settings.

mad_maniac_man 09-20-2010 12:52

Re: Restrict weapons for certain maps
 
I tried all variations of that gun_awp.cfg in the extraconfigs folder but no luck so I give up. The other mainly annoying problem im getting is node errors in the waypoints and maps like sa_treetops aint working properly. That might not be in your area of expertize though.

Andy

KWo 09-20-2010 14:11

Re: Restrict weapons for certain maps
 
The only thing I cannot be sure is this prefix awp thing, I mean if this file is whole interpreted by AMX X:
addons\configs\maps\prefix-awp.cfg
To make sure the contents of it is called, rename the file name to awp_bycastor32.cfg (leave everything else as You did it untill now whole testing those configs described by me above) then try to play some map to see if settings for standard maps are working, then call changelevel for Your awp_bycastor32 map. Check how CSDM is working on that map (if there are any differences with equiping players, showing menus etc).

BTW - waypoints problem for podbot mm is also somehow in my scope, byt this is not the right forum to ask such things.

Go there to ask the question related podbot mm waypoints.

mad_maniac_man 09-25-2010 11:01

Re: Restrict weapons for certain maps
 
Good news mate. I found the problem. Somehow my csdm.cfg file was set csdm to 0 so i set it to 1 and changed the prefix-awp.cfg and renamed to awp_bycastor32.cfg and its now allowing me to select deagle only and gives me nades and armor auto. The only thing left to fix is making the bots do this as they seem to be buying any weapon they like. Finally some success eh ?

Andy.

KWo 09-26-2010 07:22

Re: Restrict weapons for certain maps
 
Update Your bots to V3B21 version, so they are buying the weapon on awp map, if the map allows them to.

mad_maniac_man 09-26-2010 09:38

Re: Restrict weapons for certain maps
 
Ok mate think ive managed to fix it. Now how to I set it so there is no timelimit with csdm and also no round end on csdm ?

Andy.

KWo 09-26-2010 10:44

Re: Restrict weapons for certain maps
 
Quote:

Originally Posted by csdm.cfg
[settings]
;Sets whether the bomb is removed
remove_bomb = 1

[misc]
;Map objectives are removed by their flags.
; a - as_ maps
; b - buyzones are removed
; c - cs_ maps
; d - de_ maps
remove_objectives = abcd

Bombs and all objectivities have to be removed to have the round neverending.
To skip the mp_timelimit problem, You should use - whenever You are using CSDM enabled - mp_maxrounds system instead mp_timelimit, I mean - for those maps You should have:
mp_timelimit 0
mp_maxrounds 30
As You can see - if the round is neverending - mp_maxrounds never can be reached...

mad_maniac_man 09-30-2010 07:54

Re: Restrict weapons for certain maps
 
Thanks mate Ive managed to do that and it works fine. For some strange reason after like 8-10 rounds on awp_bycastor32 I start with a knife and no longer automatically get an AWP. Any ideas ?

I swear this is the last question then Ill leave you be lol.

Andy

KWo 09-30-2010 08:57

Re: Restrict weapons for certain maps
 
I can imagine only one situation. You have skipped the awp selection, then - on the next map - You have chosen from Gun Menu "3. 2+Don't show menu again" (so it was rememebering all the time no selection). Another case is some awp limiter plugin is still working. Other than that I cannot imagine why You don't have Your awp. Sorry.

RAFFAK 06-17-2011 01:13

Re: Restrict weapons for certain maps
 
Hello. Just done another configure with restricted guns. I turned off some zoom guns in csdm.cfg and created new folder: cstrike/addons/amxmodx/configs/maps/

There I created files:
plugins-awp_india.ini
plugins-aim_fixit_deagle.ini
plugins_ak-47_map.ini

Inside these files need to write: csdm_equip.amxx disabled

Im doing this configs in maps, there map auto giving gun to you, just switching off Gun meniu, in other maps there is all guns, gun meniu is working, dont need to do config.

But I have a problem, in some maps, for example: aim_map_usp is bug, then I creating this config, T got usp's, CT not, just knife and in a lot of USP maps and other maps. Allways I need to test all maps, to good working. So, please help me for this configuration. I very need this.

c0ma 06-30-2011 14:03

Re: Restrict weapons for certain maps
 
Hello,i need help :( i have a respawn server and awp is restricted,i have this plugin on him but i want to change the price in 5000$ or another price for awp and doesen't work! good,that is the first problem :)) ...second problem: on all maps awp is restricted,actually awp cost 15000$ in this moment,i want to know how can i give free awp on awp maps only?

The code for my first problem,where i want to change the price in 5000$:

Quote:

#include <amxmodx>
#include <cstrike>
#include <fun>

new g_pCvar_Price;

public plugin_init()
{
register_plugin("Buy AWP", "0.0.1", "dinnk.");

register_clcmd("say /awp", "CmdAwp");

g_pCvar_Price = register_cvar("awp_deagle_price", "15000");
}

public CmdAwp(id)
{
new iMoney = cs_get_user_money(id);
new iPrice = get_pcvar_num(g_pCvar_Price);

if( !is_user_alive(id) )
{
client_print(id, print_chat, "* You need to be alive !");
return PLUGIN_HANDLED;
}

if( iMoney < iPrice )
{
client_print(id, print_chat, "* You need more money ! ($%i)", iPrice);
return PLUGIN_HANDLED;
}

give_item(id, "weapon_awp");
give_item(id, "weapon_deagle");
cs_set_user_bpammo(id, CSW_AWP, 30);
cs_set_user_bpammo(id, CSW_DEAGLE, 35);

client_print(id, print_chat, "* You bought an AWP & Deagle for $%i !", iPrice);
cs_set_user_money(id, iMoney - iPrice, true);
return PLUGIN_HANDLED;
}
Edit:i forgot something ;)) i change it the price in 5000$ and i compiled again but doesen't work!

c0ma 07-01-2011 05:01

Re: Restrict weapons for certain maps
 
i made it with my second problem :P thank you all,but with the first problem,i don't know how can i change the price in 5000$

c0ma 07-01-2011 05:32

Re: Restrict weapons for certain maps
 
i made it,i change it the price with cvar awp_deagle_price "5000",it's work now,thanks all

RAFFAK 07-08-2011 15:02

Re: Restrict weapons for certain maps
 
I need a man, who can do to my csdm restricted guns. I will pay. Please write message to me with your contacts.


All times are GMT -4. The time now is 11:52.

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