1 - Is there any way of editing the files that contain ufopaedia text and mail messages? I've found the .mo files in the i18n directory but it doesn't edit properly with Notepad or Wordpad.
This is something we've been working on improving, but I'm not sure if it's there yet. Currently, all text is uncompiled .po files which are then compiled into .mo files used by the game. You can edit the .po files but you would have to distribute new, compiled .mo files with your mod -- and these contain all the translations as well, so could limit your mod to just English.
We're hoping to make it possible to put this text directly into the script files or allowing you to use .po files for a mod, but I don't think this has been implemented yet.
2 - Is it possible to add new base defence buildings using tweaked, existing models? I tried and had the building showing up no problem but ran into an issue with assigning the weaponry.
Hmm, I suspect this is a more tricky issue because the base buildings are integrated into click commands that open windows and are used in the backend. That said, it looks like it may be possible to add another laser OR missile battery building. The code for the missile battery is:
building building_missile
{
name "_Missile Battery"
image "base/missile"
fixcosts 10000
depends building_command // need to know where to shoot
type "missile"
build_time 3
varcosts 5000
map_name "missile"
tech rs_building_missile
max_count 4
onconstruct "add_battery missile"
onenable "basedef_updatebatteries missile"
ondisable "basedef_updatebatteries missile"
ondestroy "remove_battery missile"
}
Just guessing, but you may be able to add a building like this and just change max_count if you wanted to add more missile batteries per building. But I don't think you could create a new "type" (laser or missile) as that would require changes to the backend.
3 - Are the skills hard-coded or is it possible to change them? I can change the name they appear with but the equipment window still shows Skill: Sniper even after it's been changed to Pistols because it seems to be pulling the information from the weapon script file where the skill type is set for that firedef rather than a string from somewhere else.
Not quite sure if I'm understanding you. The soldier skills -- the possible skills that each soldier has -- are hard coded because they interact with all sorts of things in the battlescape code. I don't think it's possible to create a new skill.
However, you can change which of the existing skills each firemode uses. Here's the sniper weapon and ammo firemodes with comments (/* comment */) to explain a few things:
item sniper
{
name "_Sniper Rifle"
model "weapons/sniper/sniper"
weapon true
/* This type parameter does not effect firemode or skill. It only effects how the weapon will be held by the model in-game. */
type "rifle"
animationindex 1
holdtwohanded false
firetwohanded true
shape "2 0 3 1"
shape "0 1 5 1"
center "9 0 3"
scale 1.05
ammo 8
reload 15
reloadsound "weapons/reload-sniper"
price 1300
size 60
is_primary true
}
item sniper_ammo
{
name "_Sniper Rifle Magazine"
model "weapons/sniper/sniper_clip"
type "ammo"
animationindex 0
shape "0 0 1 2"
center "0 0 0"
scale 1.15
price 85
size 8
is_primary true
dmgtype "normal"
weapon_mod
{
weapon sniper
firedef
{
name "_Snap Shot"
/* This skill parameter is where you would change it to one of the pre-existing weapon skill types */
skill "assault"
projtl bullet_sniper
impact bulletImpact
hitbody null
firesnd "weapons/bullet-sniper"
impsnd "impact/bullet-impact"
bodysnd "impact/bullet-bodyimpact"
speed 3600
spread "2.5 2.5"
crouch 1
range 100
shots 1
ammo 1
time 15
damage "130 20"
dmgweight "normal_medium"
reaction true
throughwall 1
}
firedef
{
name "_Aimed Shot"
/* This skill parameter is where you would change it to one of the pre-existing weapon skill types */
skill "sniper"
projtl bullet_sniper
impact bulletImpact
hitbody null
firesnd "weapons/bullet-sniper"
impsnd "impact/bullet-impact"
bodysnd "impact/bullet-bodyimpact"
speed 3600
spread "0.85 0.85"
crouch 0.6
range 100
shots 1
ammo 1
time 20
damage "130 20"
dmgweight "normal_medium"
reaction true
throughwall 1
}
}
}
You can see many of the
weapon settings defined in our wiki.