|
Post by tom on Nov 2, 2008 12:10:29 GMT -8
I see there was a previous thread regarding activating custom weapon slots (by adding // to the front of the line of the weapon you want to activate in the excludeweapons.txt in the scripts folder) which was a great help but I was wondering about how to use the proper names of the weapons for spawning like in the v5.56 in Smod:Tactical?
For example, at the moment you have to type "give weapon_custom6" to get the M16A4.
Sorry if this has previously been covered - I tried searching but couldn't find anything apart from the aforementioned thread.
Thanks T...
|
|
ClaneLord
New Member
Furry surviver.
Posts: 98
|
Post by ClaneLord on Nov 2, 2008 16:32:23 GMT -8
There should be some script or something.That throws game from weapon_m16a4 to weapon_custom6
|
|
|
Post by tom on Nov 3, 2008 3:25:42 GMT -8
Yeah - any idea which one? I was wondering about just changing the names the text files in the scripts folder but obviously if some file is looking for "weapon_customxx.txt" then it won't find it if I've renamed it - does anybody have any idea which file it would be? Vet? No worries if you're busy though! That zombie dog idea sounds great btw!
Thanks T...
|
|
|
Post by tom on Nov 4, 2008 13:02:33 GMT -8
Useful over in the Smod:Tactical forums suggested the override_class.txt in scripts - I tried this (the bottom one):
"default_map" { "weapon_smg1" { "weapon_custom4" "100" } "weapon_shotgun" { "weapon_custom5" "100" } "weapon_crossbow" { "weapon_custom9" "100" } "weapon_ar2" { "weapon_custom8" "100" } "weapon_pistol" { "weapon_custom2" "100" } "weapon_357"{ "weapon_custom3" "100" } "weapon_m4a1"{ "weapon_custom19" "100" }
But it didn't work. T...
|
|
|
Post by veteran_gamer on Nov 7, 2008 15:00:31 GMT -8
Tom whats up
are you trying to simply rename the weapons? or change the actual entity name via console
let me know I can tell you how to do either
|
|
|
Post by tom on Nov 10, 2008 14:05:20 GMT -8
Hi Vet - I just would like to be able to type into the console (for example, if I have a custom m4a1 at weapon custom 13 slot) "give weapon_m4a1" instead of typing "give weapon_custom13". I guess renaming the weapons would be great too actually.
That's all - any help would be brilliant!
Thanks T...
|
|
|
Post by veteran_gamer on Nov 15, 2008 1:03:46 GMT -8
ahh, you can do that through the smod\scripts\override.txt script, kenneth showed me once how do to it exactly, he is currently AWAY, but when he gets back, i'm sure he'd be more than willing to give you the PROPER instructions, i think its pretty simple too, but i rather not give bad advice
yeah, what you need is like "give weapon_tomsfavoritegun" to equal the value of give weapon_customxx
now i fully understand, i may even experiment myself for my own purpose, good thinking in outbreak, i could use this such as..
give mp5 = weapon_custom4 give spas = weapon_custom5
etc etc
ill find out and post the result ASAP for ya T!
|
|
|
Post by business on Nov 15, 2008 1:56:12 GMT -8
Here is an example from my override_class.txt script and it works:
// // SMOD class override data (sample) // OverrideClasses { "default_map" { //WEAPON REPLACEMENTS "weapon_shotgun" { "weapon_custom2" "100" } "weapon_pistol" { "weapon_custom4" "100" } "weapon_smg1" { "weapon_custom9" "100" } "weapon_ak47" { "weapon_custom1" "100" } "weapon_ar2" { "weapon_custom14" "100" } "weapon_grease" { "weapon_custom10" "100" } "weapon_357" { "weapon_custom7" "100" } "weapon_frag" { "weapon_custom30" "100" } "weapon_crossbow" { "weapon_svd" "100" } } }
If you are getting some sort of error you may be missing a brace somewhere.
Also, I do not know if this works with mappadds, but it 100% works with the console.
If you get tired of typing out your new commands you can save them into the console permanently in this script:
smodaclist.txt
|
|
|
Post by tom on Nov 15, 2008 4:19:24 GMT -8
Woohoo! That all looks like great stuff - thanks very much, I'll give it all a go then get back to you! Thanks Vet and Business!
T...
|
|
|
Post by tom on Nov 15, 2008 6:36:40 GMT -8
Sorry to be really thick business but do I need that //SMOD CLASS OVERRIDE DATA bit in? I've also gotten rid of the paragraphs in mine so I could see which braces went with what - does that matter?
OverrideClasses { "default_map" { //WEAPON REPLACEMENTS "weapon_cleaver" {"weapon_custom1" "100"} "weapon_beretta" {"weapon_custom2" "100"} "weapon_deagle" {"weapon_custom3" "100"} "weapon_mp5" {"weapon_custom4" "100"} "weapon_spas12" {"weapon_custom5" "100"} "weapon_m16" {"weapon_custom6" "100"} "weapon_bizon" {"weapon_custom7" "100"} "weapon_tavor" {"weapon_custom8" "100"} "weapon_xbow" {"weapon_custom9" "100"} "weapon_m249" {"weapon_custom10" "100"} "weapon_overwatch" {"weapon_custom11" "100"} "weapon_m16acog" {"weapon_custom12" "100"} "weapon_hkm3" {"weapon_custom13" "100"} "weapon_dualxm10" {"weapon_custom14" "100"} "weapon_dualsvi" {"weapon_custom15" "100"} "weapon_m16a1" {"weapon_custom16" "100"} "weapon_ak-47" {"weapon_custom17" "100"} "weapon_oicw" {"weapon_custom28" "100"} "weapon_laser" {"weapon_custom19" "100"} "weapon_g36" {"weapon_custom20" "100"} "weapon_m3super" {"weapon_custom21" "100"} "weapon_mp7" {"weapon_custom22" "100"} "weapon_kalash" {"weapon_custom23" "100"} "weapon_xm8" {"weapon_custom24" "100"} "weapon_hk23e" {"weapon_custom25" "100"} "weapon_dualberet" {"weapon_custom26" "100"} "weapon_pp19" {"weapon_custom27" "100"} "weapon_m4a1" {"weapon_custom28" "100"} "weapon_f2000" {"weapon_custom29" "100"} "weapon_g2a2" {"weapon_custom30" "100"} } }
I haven't tried this yet but will do after I've had some lunch. I also think that smodaclist.txt will have something to do with it - what does that file actually do?
Thanks! T....
|
|
|
Post by veteran_gamer on Nov 15, 2008 12:14:40 GMT -8
yeah, smodaclist will have something to do with it
if you open it up, youll see it has all the "give" or "npc_create" auto-completes when you type in the console
so after the override.txt was done properly, the last step would be to simply add your custom names in the smodaclist
and the brackets are super important in all coding and scripts, always keep the same structure in the script files, only modifying the values you need or adding the ones desired, i dont think what you just posted would work, im almost certain
after the "weapon_xxxx" a bracket is needed
{
this closes the conversation of WHAT we are going to to declare now
so it would be
"weapon_tomsgun" {
now after that, you're in business
so lets start clean ___________________________
"weapon_tomsgun" { "weapon_custom10" } "give weapon_custom10" { "give weapon_tomsgun" } } } //endscript
HAH! try that!
i think that'll work dude
*edit*
and after you do that, open smodaclist and add
weapon_tomsgun
then vualah, when you open up smod, type it in the console, your weapon will be embedded with its custom named cvar
I gotta tell ya though T, let me know if you experience anything abnormal with these applied to a BUNCH of weapons, i'm a paranoid freak when it comes to these things
good luck buddy
|
|
|
Post by tom on Nov 16, 2008 11:00:51 GMT -8
AArrrgghhh!! It's driving me crazy! I don't understand what i'm doing wrong. I've re-done the override (copied the file from smod tactical and edited out or in the bits I didn't want/wanted) and I've added the correct lines to the smodaclist (e.g. weapon_m249) but still it doesn't work. The lines come up in the console when starting to type them (e.g. give weapon_m249) but on pressing enter it just says something like "couldn't find the weapon". If I type it's equivalent give weapon_customxx then it works but as I've added the (seemingly) correct lines to the override.txt I don't understand why it shouldn't work. I was really careful with the braces in the text too.
Here is my override_class.txt:
// weapon_custom1 cleaver // weapon_custom2 Beretta // weapon_custom3 Deagle // weapon_custom4 Mp5 // weapon_custom5 Spas12 // weapon_custom6 M16 // weapon_custom7 Bizon // weapon_custom8 Tavor // weapon_custom9 xbow // weapon_custom10 m249 // weapon_custom11 Overwatch // weapon_custom12 m16acog // weapon_custom13 hkm3 // weapon_custom14 dual xm10 // weapon_custom15 dual svi // weapon_custom16 m16a1 // weapon_custom17 ak-47 // weapon_custom18 OICW // weapon_custom19 Laser // weapon_custom20 g36 // weapon_custom21 m3super // weapon_custom22 mp7 // weapon_custom23 kalash // weapon_custom24 xm8 // weapon_custom25 hk23e // weapon_custom26 dual berettas // weapon_custom27 pp19 // weapon_custom28 m4a1 // weapon_custom29 F2000 // weapon_custom30 g2a2
OverrideClasses { "default_map" { "weapon_cleaver" { "weapon_custom1" "100" }
"weapon_beretta" { "weapon_custom2" "100" } "weapon_deagle" { "weapon_custom3" "100" } "weapon_mp5" { "weapon_custom4" "100" } "weapon_spas12" { "weapon_custom5" "100" } "weapon_m16" { "weapon_custom6" "100" } "weapon_bizon" { "weapon_custom7" "100" } "weapon_tavor" { "weapon_custom8" "100" } "weapon_xbow" { "weapon_custom9" "100" } "weapon_m249" { "weapon_custom10" "100" } "weapon_overwatch" { "weapon_custom11" "100" } "weapon_m16acog" { "weapon_custom12" "100" } "weapon_hkm3" { "weapon_custom13" "100" } "weapon_dualxm10" { "weapon_custom14" "100" } "weapon_dualsvi" { "weapon_custom15" "100" } "weapon_m161a1" { "weapon_custom16" "100" } "weapon_ak-47" { "weapon_custom17" "100" } "weapon_oicw" { "weapon_custom18" "100" } "weapon_laser" { "weapon_custom19" "100" } "weapon_g36" { "weapon_custom20" "100" } "weapon_m3super" { "weapon_custom21" "100" } "weapon_mp7" { "weapon_custom22" "100" } "weapon_kalash" { "weapon_custom23" "100" } "weapon_xm8" { "weapon_custom24" "100" } "weapon_hk23e" { "weapon_custom25" "100" } "weapon_dualberet" { "weapon_custom26" "100" } "weapon_pp19" { "weapon_custom27" "100" } "weapon_m4a1" { "weapon_custom28" "100" } "weapon_f2000" { "weapon_custom29" "100" } "weapon_g2a2" { "weapon_custom30" "100" } "item_battery" { "item_ammo_ar2" "50" "item_ammo_357" "50" } "item_healthkit" { "item_ammo_smg1" "25" "item_ammo_ar2" "40" "item_ammo_357" "30" } "item_healthvial" { "weapon_frag" "100" } "npc_poisonzombie" { "npc_zombie2" "50" "npc_fastzombie" "50" } "npc_combine_c" { "npc_combine_s" "100" } } "d1_town_04" { "npc_zombie" { "npc_zombie2" "100" } }
And here is (the relevant part of) my smodaclist:
"give" { "npc_helicopter" "npc_combinegunship" "item_suit" "item_ammo_pistol" "item_ammo_smg1" "item_ammo_ar2" "item_ammo_357" "item_ammo_crossbow" "item_rpg_round" "item_ammo_smg1_grenade" "item_box_buckshot" "item_ammo_ar2_altfire" "item_box_flare_rounds" "weapon_cleaver" "weapon_beretta" "weapon_deagle" "weapon_mp5" "weapon_spas12" "weapon_bizon" "weapon_m16" "weapon_tavor" "weapon_xbow" "weapon_m249" "weapon_overwatch" "weapon_m16acog" "weapon_hkm3" "weapon_dualxm10" "weapon_dualsvi" "weapon_m161a1" "weapon_ak-47" "weapon_oicw" "weapon_laser" "weapon_g36" "weapon_m3super" "weapon_mp7" "weapon_kalash" "weapon_xm8" "weapon_hk23e" "weapon_dualberet" "weapon_pp19" "weapon_m4a1" "weapon_f2000" "weapon_g2a2" "weapon_custom1" "weapon_custom2" "weapon_custom3" "weapon_custom4" "weapon_custom5" "weapon_custom6" "weapon_custom7" "weapon_custom8" "weapon_custom9" "weapon_custom10" "weapon_custom11" "weapon_custom12" "weapon_custom13" "weapon_custom14" "weapon_custom15" "weapon_custom16" "weapon_custom17" "weapon_custom18" "weapon_custom19" "weapon_custom20" "weapon_custom21" "weapon_custom22" "weapon_custom23" "weapon_custom24" "weapon_custom25" "weapon_custom26" "weapon_custom27" "weapon_custom28" "weapon_custom29" "weapon_custom30" "weapon_crowbar" "weapon_physgun" "weapon_physcannon" "weapon_pistol" "weapon_357" "weapon_alyxgun" "weapon_smg1" "weapon_ar2" "weapon_abgun" "weapon_shotgun" "weapon_crossbow" "grenade" "weapon_frag" "weapon_physlauncher" "weapon_rpg" "weapon_bugbait" "weapon_nodemaker" }
Any more advice would be so appreciated! Thank you!
T...
|
|
|
Post by business on Nov 16, 2008 22:41:22 GMT -8
If that is your exact override_class.txt script then you are still missing a closing brace at the very end from what I can tell.
This line is still open
OverrideClasses {
I would suggest you check out a program called Notepad++ if your are going to be doing a bunch of scripting. It will make the braces glow red if you have them closed. It is really useful.
|
|
|
Post by tom on Nov 17, 2008 14:36:48 GMT -8
Thanks business - I added that extra brace but nothing changed. I've no idea what's going wrong. Also I've just realised that weapon_custom9 doesn't work at all - typing it's alternative command or "give weapon_custom9".
T...
|
|
|
Post by business on Nov 17, 2008 19:56:01 GMT -8
I'm gonna make your day tom. I just remembered you need to type in console smod_override_classes 1
|
|
|
Post by tom on Nov 18, 2008 11:10:30 GMT -8
Legend!! Wooohoooo! It works! Thank you so much for that business - brilliant! It's actually "smod_override_classname 1" that came up when I started to type it.
Thank you again - solved!!
T...
|
|