it must be preached as im precaching it when my perks are registered and the default weapon (if you pass a undefined var in the set weapon it defaults to this one) is precached during pre_init of my perk system
it must be preached as im precaching it when my perks are registered and the default weapon (if you pass a undefined var in the set weapon it defaults to this one) is precached during pre_init of my perk system
I don't know much about script but I think you have to precache them
Yes, like that. However, it shouldn't matter if you use a literal string or a variable as long as the variable is defined and is a string(maybe it isn't defined?).
Yes, like that. However, it shouldn't matter if you use a literal string or a variable as long as the variable is defined and is a string(maybe it isn't defined?).
You should only precache weapons/models once. Also, the second call is AFTER _load, not before(where it should be.
the second call was me moving it there just to check but i moved it back above _load (the first image)
Edit: the reason i have 2 precaches is just incase the weapon passed in maps\wardog\perks\_wardog_perks_util::set_perk_weapon is not the default bottle (set and precached in maps\wardog\perks\_wardog_perks::pre_init)
the second call was me moving it there just to check but i moved it back above _load (the first image)
Edit: the reason i have 2 precaches is just incase the weapon passed in maps\wardog\perks\_wardog_perks_util::set_perk_weapon is not the default bottle (set and precached in maps\wardog\perks\_wardog_perks::pre_init)
Ah, okay.
precacheItem should precache the model by itself. All your doing there is precaching the model itself, which would only be useful if you wanted to spawn the model via script but don't have a weapon with the model precached elsewhere.
Edit: honestly, the only way i'm going to be able to figure this out at this rate is if i had a copy of whatever map your using to test these perks. I could then run developer and developer_script and see if it is indeed not being preached or if the variable isn't defined.
Last Edit: January 20, 2016, 10:20:30 pm by daedra descent
precacheItem should precache the model by itself. All your doing there is precaching the model itself, which would only be useful if you wanted to spawn the model via script but don't have a weapon with the model precached elsewhere.
Edit: honestly, the only way i'm going to be able to figure this out at this rate is if i had a copy of whatever map your using to test these perks. I could then run developer and developer_script and see if it is indeed not being preached or if the variable isn't defined.
i dont mind sending you a compiled version of my map as ive tried everything and cant it to work and just really want this fixed but im not going to send a uncompiled version out ( sorry)
Edit: pm me if you want me to send the compiled map
You really should only use one weapon file. Your taking up a lot of weapon files that way.
For bottles just make sure you Precache the weapon file and add the models and weapon file to a csv your including in the mod (and checked while building mod). Most use the mod.csv. Missing one of those causes the can give in console works but not via script thing. I forget which one off hand. As a matter of fact, usually if you give on console, after that the script will give then for that game. Unless I misunderstood what you said.
Last Edit: January 21, 2016, 12:43:56 am by MakeCents
You really should only use one weapon file. Your taking up a lot of weapon files that way.
For bottles just make sure you Precache the weapon file and add the models and weapon file to a csv your including in the mod (and checked while building mod). Most use the mod.csv. Missing one of those causes the can give in console works but not via script thing. I forget which one off hand. As a matter of fact, usually if you give on console, after that the script will give then for that game. Unless I misunderstood what you said.
i am using 1 weapon file but with all waw, bo1 and bo2 perks that takes up almost all 16 slots in the weapon file so im trying to add the ability to call 1 function and change the weapon file (but for some reason it seems the weapon file isnt been saved even though it should)
Oh, I saw the one comment and all the precaches above and thought you were using more, my bad.
yeah the weapon file im using can be found here dont know if all this can be caused be a mistake in the weapon file (i dont really know how weapon files work i tend to edit them with UGX Weapon editor and add the extra models in Sublime)