View Full Version : DoD One Weapon Mod
Hell Phoenix
09-11-2006, 06:34 PM
/* DoD One Weapon Mod
* Originally by: SidLuke ( sidluke@o2.pl )
* Updated by: Hell Phoenix ( Hell_Phoenix@frenchys-pit.com )
* Version: 2.0
* Description:
* With this plugin you can set specific weapon battle
*
* Thanks to Wilson from dodplugins for the scoped fg42/enfield stocks
*
* Commands:
* amx_oneweapon 0|1 - enable/disable plugin
* amx_setoneweapon < weapon index > - use this command to set weapon you want by Index number
* amx_owmmenu - menu
*
* Known Issues:
* When choosing scoped fg42 or scoped enfield, your first shot with it you drop it...but when you pick
* it up again, its then fine. There currently is no way around this. You must either drop your weapon
* and pick it back up or fire it and pick it back up.
*
* Versions:
* 1.0.1 Last known version by Sidluke...fixed some menu things
* 2.0 First version by Hell Phoenix
* - Added all weapons to the plugin including scoped fg42/enfield
* - Rewrote much of the plugin to current standards including using the new menu system
* 2.1 Fixed missing MG34/42 and 30 Cal.
* Fixed it not killing everyone when called from menu
*
*/
Weapon IDs
1 = amer knife
2 = german knife
3 = colt
4 = luger
5 = garand
6 = scoped kar
7 = thompson
8 = mp44
9 = springfield
10 = kar
11 = bar
12 = mp40
13 = handgrenade
14 = stickgrenade
17 = mg42
18 = .30 cal
19 = spade
20 = M1 carbine
21 = mg34
22 = greasegun
23 = fg42
24 = k43
25 = enfield
26 = sten
27 = bren
28 = webley
29 = bazooka
30 = pschreck
31 = piat
32 = Scoped FG42
33 = Folding Carbine
34 = Scoped Enfield
36 = British Knife
PenDragon
09-12-2006, 03:50 PM
Thanks Hell Phoenix. I edited into your post a list of weapons and their respective ID numbers.
Hell Phoenix
09-12-2006, 06:03 PM
Ahh good call =D
strontiumdog
11-12-2006, 02:53 PM
Great mod.:)
Just two questions.
1. Is it supposed to return you to your spawn to change weapon?
2. How can it be returned to normal after using this mod?:D
spitfire
11-13-2006, 12:06 AM
Yes it is supposed to bring you to spawn and to shut it off
amx_oneweapon 0 in console
Atleast I think thats it.. Off the top of my head
OnkelBazi
12-08-2006, 08:20 AM
thx for this Plugin it works fine!
hackrat
12-17-2006, 04:19 PM
Does this plugin have the thing that you drop weapons and pick it back up and use it.
.:WORM:. Bulldogz
01-04-2007, 10:20 PM
I downloaded it and compiled it but it doesnt work, what versions of amxmodx is this compatable with?? I have version 1.71, should it work?
This should be compatiable with every version of amxmodx.
Cheers!
Tony Almeida
02-10-2007, 03:05 PM
Hey guys,
I can't get this to work for some reason...
I added the .sma
I added this in my amxxx.cfg and set it to 1
/* DoD One Weapon Mod
* Author: SidLuke ( sidluke@o2.pl )
* Version: 0.2
* Description:
* With this plugin you can set specific weapon battle
* Commands:
* amx_oneweapon 0|1 - enable/disable plugin
* amx_setoneweapon < weapon index > - use this command to set weapon you want
* amx_owmmenu - menu
*/
It won't recognize the plugin....any ideas?
=|[76AD]|= TatsuSaisei
02-10-2007, 06:53 PM
Hey guys,
I can't get this to work for some reason...
I added the .sma
don't "add" the .sma ... compile the .sma and add the resultant .amxx file
Tony Almeida
02-13-2007, 12:17 PM
Unfortunately I have no idea how to compile the sma to result in an amxx file. I thought that the amxx file would be added as well as the sma.
Little help?
diamond-optic
02-13-2007, 01:36 PM
Unfortunately I have no idea how to compile the sma to result in an amxx file. I thought that the amxx file would be added as well as the sma.
Little help?
http://www.dodplugins.net/pages/resources/compiler.php
Atari
02-13-2007, 04:27 PM
hey buddy make sure you compile it first!! needs to be .amxx file! :D
http://www.dodplugins.net/forums/showthread.php?t=50
this will help you!!!
such blinding speed tatsu and diamond hahah soon as i hit submit you guys are already on it!
Tony Almeida
02-14-2007, 11:28 AM
Thanks for the compiling help guys. Looks really easy now that I know how. :D
Reeslo
03-27-2007, 05:54 AM
I have some idea for the next version if you want to continue.
With more weapons like mg's ang fg scope
and more option with the snipers like uncoped mode, its very funny :)
soz for my bad english im french...
Reeslo
Wilson [29th ID]
03-27-2007, 08:27 PM
huh ?
Garion
03-28-2007, 01:03 AM
I think what he means is he wants to see the scoped FG42 and the Scoped Enfield in the nextversion. But I dunno what he means about the snipers uncoped mode.
{SR} *Raggy*
03-28-2007, 04:46 AM
He means that would it be able to be an option to like stop a person to scope and play with no-scope and no one can scope
Saint_Cyril
03-28-2007, 05:49 AM
I've been using this plugin for awhile now, and there is one major problem that I have. Once I enable one amx_oneweapon, it is possible for players to drop their gun as they spawn, and pick it back up again and keep it. The same goes for maps with weapons on the ground, ready for you to pick up. Is it possible for you to change the code so that once all the weapons are stripped, that players can't use the 'g' (drop weapon) button to drop a gun, and have it prevent them from being able to pick up weapons on the ground, including grenades?
Hell Phoenix
03-28-2007, 12:53 PM
Man its been awhile since I been back here! So many things happened IRL that I havent had time to think =(
Anyways, maybe I will take a look at this again in the next week or so and add a few things to it.
diamond-optic
03-28-2007, 08:39 PM
heh who are you again phoenix :P
...you could always hook CurWeapon and check its weapon id and if its anything but the allowed one.. etc..
Garion
03-28-2007, 09:56 PM
I thought this already prevents the person from dropping the weapon?
Hell Phoenix
03-29-2007, 04:09 PM
I havent looked at it much yet but it does have a curweapon call in it. I wouldnt doubt if a newer version of amxx broke it since its a few years old...lol. Its way past time to update it =D
Reeslo
03-30-2007, 09:55 AM
Hi
Ye i mean for non-scoped (for snipers) mode in this plugin
because i try in my serv and its very funny ^^
Hell Phoenix
04-06-2007, 04:08 PM
Well its taking a bit longer than I had hoped. Im pretty much rewriting this from scratch as it used the old menu system which is a pain to modify and look nice. It will also have the scoped enfield/fg42 included thanks to toolz and Wilson =D
dlambert1989
04-15-2007, 04:09 AM
i like this plugin, but is there anyway to make it so that we cant drop our guns a we respawn?
blobby
04-15-2007, 03:01 PM
dose anyone know how i can get this on my amxmodmenu in its own menu as i cant seem to find out how to and its annoying going into console every time and having to type in the commands not to menchion i dont know what numbers go with what weapon can anyone help.
Regards
Blobby
mantk
04-15-2007, 03:08 PM
Add the next line in addons/amxmodx/configs/cmds.ini and change flags and access level as you like.
"One Weapon" "amx_owmmenu" "b" "u"
Hell Phoenix
04-16-2007, 01:50 AM
Or wait till tomorrow and all your wildest fantasies will come true! Pedro offers you his protection.....
blobby
04-16-2007, 06:39 AM
Or wait till tomorrow and all your wildest fantasies will come true! Pedro offers you his protection.....
HUH? whats that mean lol
Hell Phoenix
04-16-2007, 12:05 PM
It means I will be posting the new version now ;)
_________________________________________________
Updated to 2.0
Changelog:
- Added all weapons to the plugin including scoped fg42/enfield
- Rewrote much of the plugin to current standards including using the new menu system
Known Issues:
When choosing scoped fg42 or scoped enfield, your first shot with it you drop it...but when you pick it up again, its then fine. There currently is no way around this. You must either drop your weapon and pick it back up or fire it and pick it back up.
rebelios
04-16-2007, 02:06 PM
Or wait till tomorrow and all your wildest fantasies will come true! Pedro offers you his protection.....
You sick sick little man
blobby
04-16-2007, 02:10 PM
Add the next line in addons/amxmodx/configs/cmds.ini and change flags and access level as you like.
"One Weapon" "amx_owmmenu" "b" "u"
It didnt work at all was just in dark writing i changed our access flags to the right ones to anymore ideas for me please i need help lol
Regards
Blobby
Hell Phoenix
04-16-2007, 03:39 PM
Some of you really like to make things hard. There is no need to add anything to cmds.ini. Just type amx_owmmenu into the console and up will come the menu. Its always been that way.
blobby
04-24-2007, 08:46 AM
That command dosent work m8 ive tried it like 8 times at random times and im still having to do this via console can any one help me
Regards
blobby
Hell Phoenix
04-24-2007, 12:00 PM
What command doesnt work?
blobby
04-24-2007, 11:25 PM
this command amx_owmmenu it just says unknown command now my mate used to be in a clan which used this plugin and in there modmenu it was in its own file and it said like this
1.k98
2.mp40
and so on and so on so can anyone help me achieve this as my admins cant even work out how to use it as its to much hard work with the 2 different commands i have to put in first can anyone help me i will be great full
regards
blobby
Hell Phoenix
04-25-2007, 12:08 AM
All you do is go to the console by pushing the ~ key and type in amx_owmmenu. Thats it. All my admins have been using it just fine so I know it works.
blobby
04-25-2007, 11:45 PM
All you do is go to the console by pushing the ~ key and type in amx_owmmenu. Thats it. All my admins have been using it just fine so I know it works.
It don't work not one bit unknown command in console m8 honest i wouldn't lie now would i m8
Regards
Blobby
MBosta
04-25-2007, 11:49 PM
blobby i just tested this, amx_owmmenu works, maybe you don't have the right admin flags or something, but that command indeed does work ingame.
blobby
04-25-2007, 11:51 PM
Or maby my plugin is busted but for some reason i have to use to plugins do you tis a little gay at time that actually i have to use these commands amx_setone weapon my number so like 31 the amx_oneweapon 1 i unno y but it works LMAO
ANY HELP
BloBBY
Hell Phoenix
04-26-2007, 12:14 PM
You probably dont have the correct permissions then if the other commands work. I just realized I used different permissions for the menu vs the other commands. Try the attached version instead and see how it works.
For other people looking at this all I did was change ADMIN_SLAY to ADMIN_LEVEL_A.
test69
05-29-2007, 10:26 PM
Hello, there is no choice in the amx_owmmenu for MG42 and 30CAL, i have change the SMA with :
menu_additem(OneWeaponMenu, "MG42", "31", 0)
menu_additem(OneWeaponMenu, "30 CAL", "32", 0)
and
case 31:{
set_owm( id , DODW_MG42)
menu_destroy(OneWeaponMenu)
return PLUGIN_HANDLED
}
case 32:{
set_owm( id , DODW_30CAL)
menu_destroy(OneWeaponMenu)
return PLUGIN_HANDLED
}
The MG42 works (no unlimited ammo) but the DODW_30CAL is not reconiez by the compiler
Any help please ?
diamond-optic
05-29-2007, 11:38 PM
but the DODW_30CAL is not reconiez by the compiler
try: DODW_30_CAL
Hell Phoenix
05-30-2007, 11:51 AM
Wow...cant believe I missed those. I will update the plugin later today, and have hte fix for ammo also =D
Hell Phoenix
05-30-2007, 06:27 PM
Ok...updated to V2.1. Changelog:
2.1 Fixed missing MG34/42 and 30 Cal.
Fixed it not killing everyone when called from menu
Psycho_Bozo
06-28-2007, 02:29 AM
I set the beginning weapon to be a knife (number 1) but it comes up as a garand no matter what i set it to. I can change it from the ingame menu but as soon as the map changes or if i restart the server it chnges back to the garand.
amxmodx ver 1.76d running on windows 2000
amx_oneweapon "1"
amx_setoneweapon "1"
Hell Phoenix
06-28-2007, 11:46 AM
I have a good idea why its doing that....I will look into it.
Psycho_Bozo
06-28-2007, 10:38 PM
Thanks man. I appreciate your help and all the plugins you have made. Good job.
blobby
06-29-2007, 10:21 AM
ok right i have re added this to my server and i can use the amx_owmmenu but i want it so that only choosen people who have admins can have it so how do i go about this and as far as i know if a plugin has its own scripted menu it can be added to the amxmodmenu am i correct but my main objectiive is to be able only to give this to choosen people so if any one can help me do this i want to use one of the custom flags to added it so that only 4 of my admins who have the custom flag can use it but how do i do this please help
Regards
Blobby
P.S. Great plugin works a treat =]
{SR} *Raggy*
06-29-2007, 11:41 AM
I'm pretty sure it's the ADMIN_LEVEL_A thing that you are looking for... You might want to find the stuff about the levels that D-O posted somewhere on these forums :P Or someone else could help ya if you tell 'em what level you want
Psycho_Bozo
07-01-2007, 02:27 AM
So are you guys having the same issue I am having? Which is the server starting with the Garand no matter which weapon you tell it to start with. And if you change it to another weapon it switches back to the Garand at map change.
Just wondering if I am the only person having this issue.
blobby
07-01-2007, 08:51 AM
No it works fine for me i just want to change the admin flags around still but i tried to do the invisibility plugin and it wouldnt compile on custom level T so i unno what to do as im getting dumb admins using it in the wrong way lol.
Hell Phoenix
07-01-2007, 07:05 PM
If you use the menu it works....its only if you try to use the cvar that it doesnt work. Ill have a new version up this week when I have some time to work on it.
Psycho_Bozo
07-02-2007, 02:10 PM
I have solved my issue.
I had to change the order of which I called the cvars from:
amx_oneweapon "1"
amx_setoneweapon "1"
to
amx_setoneweapon "1"
amx_oneweapon "1"
Evidently you have to set the weapon before turning on the plugin.
You may want to change the order you have them listed on page one.
This is great. I have a kniving server now where I don't have to worry about others using guns...
Thanks for the plugin, its great...
blobby
07-02-2007, 02:32 PM
Well i ahev the whole shbang working spot on now the cvar works for me to so np at all with it great stuff Hell phoenix m8y
regards
blobby
TooLz
07-12-2007, 09:44 AM
public eCurWeapon(id){
if ( !g_OneWeaponEnabled )
return PLUGIN_CONTINUE
new ammo, clip, wid
wid = dod_get_user_weapon(id, clip, ammo)
if ( wid != g_owm_weapon && (get_gametime()-g_spawntime[id])>2 ){
client_cmd(id,"drop")
client_print(id,print_chat,"Sorry buddy, but you can't use this weapon :P")
}
return PLUGIN_CONTINUE
}
Okay, now that I have done that - I need to know one thing.. lol
(get_gametime()-g_spawntime[id])>2
Why is this there? I'd imagine to give it a second to spawn the right weapon before throwing it into a loop of trying - but this also adds a glitch in the plugin.
I am able to get w/e gun that I spawned with when the one weapon is set to knife for sure. Bozo and I have a knives only server that we use this mod on and I believe that little piece of code is what will screw us up on that server, I keep pressing "g" while I am getting ready to spawn, it drops my MG42 as soon as I spawn and I can hurry within them 2 seconds its giving me and get the mg42, then I can lay down, put the bipod down anywhere I want and shoot it until I die.. Something we may want to consider removing, I am taking it out on my version now and uploading it later to test and I'll let everyone know if it helps any.
Cya
Hell Phoenix
07-12-2007, 11:59 AM
You cant have it do it too quick or the person doesnt have a weapon to drop yet. Try changing it to 1 or 1.5 and see what happens.
TooLz
07-15-2007, 11:57 PM
Okay I will give that a shot, just trying to get down to the root of the problem on how to fix that and that is the first thing I saw that caught my eye. I'll play with it a little bit and see what I can figure up on my test server.
Thanks
Cya
narcussist
02-25-2008, 08:14 PM
I am sorry if I just seem like I am dumb, but I was wondering how to set this up so like for one map it would work, like I am trying to get this set up for dod_paintball_b3 and have it so everytime that map loads, only gun to use is the greasegun. The reason I wanted to use just the grease gun on this map, as this gun is the closest sounding gun to an actual paintball gun, and almost looks like one too. anyways, I made dod_paintball_b3.cfg and put in
amx_setoneweapon "22"
amx_oneweapon "1"
and that did not work, if I made a maps folder inside amxx/configs/maps and put dod_paintball.ini and add that line in it will it work, or no.
SO if you could please point me in the right direction so I could get this to work this way.
TYIA
Narcussist
diamond-optic
02-25-2008, 11:03 PM
if I made a maps folder inside amxx/configs/maps and put dod_paintball.ini and add that line in it will it work, or no.
make it a *.cfg file instead of *.ini
http://wiki.amxmodx.org/Configuring_AMX_Mod_X#Map_Config_Files
narcussist
02-25-2008, 11:06 PM
thank you D-O
reece
02-29-2008, 03:39 PM
Umm i downloaded this plugin and it says the arcjive is either unknowm format or damaged what do i do?
dodsynthetic
03-01-2008, 08:51 AM
Reece, it sounds like you have WinRAR set to open .sma files. PM me and I'll help you out.
Dumbass
01-10-2009, 05:42 PM
What about add "melee" attacks? like bayonet and others?
i mean, weapon without ammo, so u can just use +attack2...
sry bad english
vBulletin® v3.8.6, Copyright ©2000-2012, Jelsoft Enterprises Ltd.