I WOULD LIKE TO THANK Archiemonday,and mrhowdoimod,for teaching me alpha layers!
FIRST lets start with textures,I know when I first started I always wanted to mess with textures but did not know how,so here we go,here is some questions you may have.
#1.what is a texture? (A):A texture is a 2d image that is putt on objects in the game to give them depth and detail.ther is a number of ways texture can be applied ,so don't think that only flat objects have texture ALL objects in bf1942 have a texture,yes including 3d ones.
#2.were is texture? How do I find it? (A):The texture can be found in your bf1942/mods/"whatevermod"/archives,it is the .rfa file simply named texture.rfa
#3.Okay I found the texture but what is a DDS file? How do I open it? (A):A DDS is a flexible image file type,It is can be opened by a DDS converting program the best one is for photoshop (LINK):http://developer.nvidia.com/object/phot ... ugins.html ,if you do not have photoshop you can also find other DDS converters by simply googleing it,My personall favorite is photoshop tho its much easier and integrated.
#4.Okay I have my DDS open now what am i looking at?

#5.How do I save this? (A):This is were it gets tricky the #1 thing to remember is the image has to be the same size "pixels X pixels" as the original image or it will not show ,second you must save the file as a DDS usually you want to save it with no alpha,well get into alpha layers later.
#6.What is a alpha layer? how do I make one? How do I apply it? (A):A alpha layer will allow you to make parts or the entire texture transparent,this is how
First you want to have your texture in the program you are using (photoshop here) As you can see I clocked create new layer and it created a new completely black layer

By adding this new layer the image will be completely transparent ,this channel works in black and white the whiter the more solid the texture is the darker the more transparent,so can you just make 1 part of the texture transparent? YES,you must select what parts of the texture you want to be solid and once you have them selected simply copy and paste them into the alpha layer as white and they will be solid.
ALWAYS MAKE SURE TO BACK UP YOUR FILES
Now these are just the basics of texturing if you have question feel free to pm me.
Now on to some basic coding
We are just going to show you some frequently used lines of code that make up the basis of modding a map.
first if you are adding custom textures to a map you can simply putt your textures in the textures folder already included in the map and go to the init.con,once there "rem" out the original texture line and place this one below it
Code: Select all
textureManager.alternativePath bf1942\levels\MAP_NAME_HERE\Textures
Another possibly one of the most important codes is
Code: Select all
ObjectTemplate.Active (whatever here)
EXAMPLE
Code: Select all
ObjectTemplate.Active HandFireArms M9_beretta
ObjectTemplate.magSize 100
ObjectTemplate.roundOfFire 12
Now we have the one covered another important code is
Code: Select all
rem
Why do I care? because this will enable you to simply rem a code instead of erasing it from the files ,saves time
if you want to rem out a larg body of code that's easy as well simply place above the code you want to remark out the code
Code: Select all
beginrem
Code: Select all
endrem
another code is
Code: Select all
ObjectTemplate.create
lets say I want to take the US_Assault kit and give it a sniper rifle,well I have to create a new kit so we go to our OST and make one!
Code: Select all
ObjectTemplate.create Kit superduperassult <-----new kit name
ObjectTemplate.setType Assault
ObjectTemplate.setKitTeam 2
ObjectTemplate.setHealthBarIcon "Ingame/Healthbar_empty_assault_64x64.tga"
ObjectTemplate.setHealthBarFullIcon "Ingame/Healthbar_full_assault_64x64.tga"
ObjectTemplate.addWeaponIcon "Weapon/Icon_usknife.tga"
ObjectTemplate.addWeaponIcon "Weapon/Icon_m9.tga"
ObjectTemplate.addWeaponIcon "Weapon/Icon_m16.tga"
ObjectTemplate.addWeaponIcon "Weapon/Icon_m61.tga"
ObjectTemplate.addWeaponIcon "Weapon/Icon_binoculars.tga"
ObjectTemplate.addWeaponIcon "Weapon/Icon_m203.tga"
ObjectTemplate.setKitIcon 1 "kits/Icon_assault_allies_selected.tga"
ObjectTemplate.setKitName 1 "RESPAWN_ASSAULT"
ObjectTemplate.setKitActiveName 1 "RESPAWN_ACTIVE_ASSAULT"
ObjectTemplate.geometry Kit_Allies_Assault
ObjectTemplate.setHasCollisionPhysics 1
ObjectTemplate.networkableInfo KitInfo
ObjectTemplate.addTemplate Us_Helmet
ObjectTemplate.addTemplate US_Hip_Pack
rem ObjectTemplate.addTemplate M16 <----remark it out
ObjectTemplate.addTemplate m24 <----new one
ObjectTemplate.addTemplate M9_beretta
ObjectTemplate.addTemplate KnifeAllies
ObjectTemplate.addTemplate GrenadeAllies
ObjectTemplate.addTemplate binoculars
ObjectTemplate.addTemplate M203
ObjectTemplate.aitemplate Assault
Code: Select all
game.setTeamSkin 2 USSoldier
game.setKit 2 0 US_Sniper
game.setKit 2 1 superduperassult <-------NEW KIT
game.setKit 2 2 US_AT
game.setKit 2 3 US_HeavyAssault
game.setKit 2 4 US_Support
Most of the things in this tutorial are CSM client side
THAT'S IT FOR THIS TUT MY FINGERS HURT THANKS FOR READING