Class Editor
-
- Posts: 15
- Joined: Wed Jul 30, 2014 12:10 pm
Re: Class Editor
Is there a section that you want to point me to or is that for me to explore ?
Re: Class Editor
It would benefit you a lot more if you explored. You might catch some great ideas or learn more than just what you are looking for. :]
(Forum Thread|Download) Swaffy'sMod v0.34 | Download link to come Soon™
- Vilespring
- Posts: 740
- Joined: Sat Nov 24, 2012 5:47 am
- Location: Somewere in the United States
Re: Class Editor
Swaffy is very right. You learn the most by finding things by accident, and breaking the game.
Let's just say, BF doesn't like you if your vehicle has no camera...
Let's just say, BF doesn't like you if your vehicle has no camera...
A picture is worth a thousand words, but takes up three thousand times the memory.
Area 51: http://battlefieldarea51mod.weebly.com/
"I didn't steal your pizza"
Area 51: http://battlefieldarea51mod.weebly.com/
"I didn't steal your pizza"
-
- Posts: 15
- Joined: Wed Jul 30, 2014 12:10 pm
Re: Class Editor
Hello.
I've had an idea .
I've seen the pattern of most mods (at least for BF1942), and I have an idea of how I might be able to create this mod.
Ok, so we have a "Mods" folder. Then we have all the mods, including vanilla BF1942. My theory is (remember, you might laugh, but I'm relatively new) that
if I copy the vanilla "bf1942" in the "Mods" folder, I can replace the "Objects.rfa" with my edit of it, rename the folder, and hey presto.
Hopefully this will display as a custom game that I can use, right?
I've had an idea .
I've seen the pattern of most mods (at least for BF1942), and I have an idea of how I might be able to create this mod.
Ok, so we have a "Mods" folder. Then we have all the mods, including vanilla BF1942. My theory is (remember, you might laugh, but I'm relatively new) that
if I copy the vanilla "bf1942" in the "Mods" folder, I can replace the "Objects.rfa" with my edit of it, rename the folder, and hey presto.
Hopefully this will display as a custom game that I can use, right?
Re: Class Editor
Don't do it like that, your file size will be very large. Instead make the file structure only containing the structure that you will be using.rubberduck23 wrote:Hello.
I've had an idea .
I've seen the pattern of most mods (at least for BF1942), and I have an idea of how I might be able to create this mod.
Ok, so we have a "Mods" folder. Then we have all the mods, including vanilla BF1942. My theory is (remember, you might laugh, but I'm relatively new) that
if I copy the vanilla "bf1942" in the "Mods" folder, I can replace the "Objects.rfa" with my edit of it, rename the folder, and hey presto.
Hopefully this will display as a custom game that I can use, right?
If you only have an Objects.rfa, then only make a Mods/ModName/Archives/Objects.rfa structure with nothing else in it. And in Mods/ModName you need your init.con file properly set up.
(Forum Thread|Download) Swaffy'sMod v0.34 | Download link to come Soon™
-
- Posts: 15
- Joined: Wed Jul 30, 2014 12:10 pm
Re: Class Editor
Oh, ok.
So once I have the Objects.rfa ready for test: Battlefield1942\Mods\"MyMod"\Archives\"MyObjects.rfa"
What is "init.con"? Do you mean setting up the Objects file correctly or else?
So once I have the Objects.rfa ready for test: Battlefield1942\Mods\"MyMod"\Archives\"MyObjects.rfa"
What is "init.con"? Do you mean setting up the Objects file correctly or else?
-
- Posts: 15
- Joined: Wed Jul 30, 2014 12:10 pm
Re: Class Editor
Ah. I see what you mean. I've found the "Init.con" and will (try) to edit it accordingly. So just that and The Objects and then done, right?rubberduck23 wrote:Oh, ok.
So once I have the Objects.rfa ready for test: Battlefield1942\Mods\"MyMod"\Archives\"MyObjects.rfa"
What is "init.con"? Do you mean setting up the Objects file correctly or else?
Re: Class Editor
How do you get the AI to use the bazooka or panzershrek when changing the kit like this? Is there a file I have to edit somewhere?
Vilespring wrote: ↑Sun Sep 07, 2014 8:58 pm Now, the code you found adds the picture of the weapon in the weapon selector, thingy. (I really don't know what that's called!) When you change that, you need to change that AND this!
ObjectTemplate.addTemplate <weapon name>
Edit: I'll give you an example with my mod!
Vanilla 1942 US AT classMy US AT kitCode: Select all
ObjectTemplate.create Kit Us_AT ObjectTemplate.setType AT ObjectTemplate.setKitTeam 2 ObjectTemplate.geometry Kit_Allies_Antitank ObjectTemplate.setHasCollisionPhysics 1 ObjectTemplate.networkableInfo KitInfo ObjectTemplate.setHealthBarIcon "Ingame/Healthbar_empty_at_64x64.tga" ObjectTemplate.setHealthBarFullIcon "Ingame/Healthbar_full_at_64x64.tga" ObjectTemplate.addWeaponIcon "Weapon/Icon_alliesKnife.tga" ObjectTemplate.addWeaponIcon "Weapon/Icon_colt.tga" ObjectTemplate.addWeaponIcon "Weapon/Icon_bazooka.tga" ObjectTemplate.addWeaponIcon "Weapon/Icon_grenadeallies.tga" ObjectTemplate.setKitIcon 2 "kits/Icon_antitank_allies_selected.tga" ObjectTemplate.setKitName 2 "RESPAWN_AT" ObjectTemplate.setKitActiveName 2 "RESPAWN_ACTIVE_AT" ObjectTemplate.addTemplate Us_Helmet ObjectTemplate.addTemplate US_Britt_Bacpac ObjectTemplate.addTemplate US_Hip_Pack ObjectTemplate.addTemplate Bazooka ObjectTemplate.addTemplate KnifeAllies ObjectTemplate.addTemplate Colt ObjectTemplate.addTemplate GrenadeAllies ObjectTemplate.aitemplate AT
NOTE! Unlike BF Vietnam, where weapons go into the kit in the order they are added, in BF 1942, the weapon has an ID on it, and will always take that slot. I changed the Bazooka to slot 4 to allow the rifle. The kit icons do get added in the order they are added in the code. Do not add more than 1 weapon with the same ID, or BF won't like you!Code: Select all
ObjectTemplate.create Kit Us_AT ObjectTemplate.setType AT ObjectTemplate.setKitTeam 2 ObjectTemplate.geometry Kit_Allies_Antitank ObjectTemplate.setHasCollisionPhysics 1 ObjectTemplate.networkableInfo KitInfo ObjectTemplate.setHealthBarIcon "Ingame/Healthbar_empty_at_64x64.tga" ObjectTemplate.setHealthBarFullIcon "Ingame/Healthbar_full_at_64x64.tga" ObjectTemplate.addWeaponIcon "Weapon/Icon_alliesKnife.tga" ObjectTemplate.addWeaponIcon "Weapon/Icon_colt.tga" ObjectTemplate.addWeaponIcon "Weapon/icon_m1_garand.tga" ObjectTemplate.addWeaponIcon "Weapon/Icon_bazooka.tga" ObjectTemplate.setKitIcon 2 "kits/Icon_antitank_allies_selected.tga" ObjectTemplate.setKitName 2 "RESPAWN_AT" ObjectTemplate.setKitActiveName 2 "RESPAWN_ACTIVE_AT" ObjectTemplate.addTemplate Us_Helmet ObjectTemplate.addTemplate US_Britt_Bacpac ObjectTemplate.addTemplate US_Hip_Pack ObjectTemplate.addTemplate Bazooka ObjectTemplate.addTemplate KnifeAllies ObjectTemplate.addTemplate Colt ObjectTemplate.addTemplate M1Garand ObjectTemplate.aitemplate AT