bf2 modding

Until this forum becomes busy just include BF2, 2142 or BFV in the title
Post Reply
axemanbfv
Posts: 3
Joined: Sat Feb 27, 2010 6:32 am
Contact:

bf2 modding

Post by axemanbfv »

i'm running bf2 v1.03... everything i try i get ctd... i see most people say to delete the md5 files... where are they... more then one location? maybe i'm not unpacking and repacking the zip file right... i dunno...
LightSpeed///
Posts: 44
Joined: Sun Oct 18, 2009 3:06 pm

Re: bf2 modding

Post by LightSpeed/// »

go through all the directories on the server, and delete the files with .md5 at the end, they should be in the following locations: all the level folders, the mods/bf2 folder and that should be it
AKA WhatThe
axemanbfv
Posts: 3
Joined: Sat Feb 27, 2010 6:32 am
Contact:

Re: bf2 modding

Post by axemanbfv »

i find it in the levels folder but nothing in the mods/bf2 folder

now what can we do in terms of modding... right now i am happy with simple tests to make sure it works...
Player
Posts: 28
Joined: Sat Oct 24, 2009 5:06 pm

Re: bf2 modding

Post by Player »

I found i had more success, by calling all mod's within a python script.

Many changes that seemed to be ignore by modding the files directly were loaded when doing so from a python script.

A simple mod which was part of my SniperWarz server which allows you to use the pistol as transportation or repluse soldiers and vehicles. I call it the PistolExpress©

Code: Select all

import bf2
import host

def init():
	host.registerGameStatusHandler(onGameStatusChanged)

def onGameStatusChanged(status):
	if status == bf2.GameStatus.Playing:

		host.rcon_invoke("""
                ObjectTemplate.activeSafe GenericFireArm USPIS_92FS_silencer
		ObjectTemplate.velocity 939

		ObjectTemplate.createComponent WeaponBasedRecoilComp
		ObjectTemplate.recoil.recoilForce 275
		ObjectTemplate.recoil.hasRecoilForce 1
		ObjectTemplate.recoil.goBackOnRecoil 1
		ObjectTemplate.recoil.recoilForceUp CRD_UNIFORM/0/0/0
		ObjectTemplate.recoil.recoilForceLeftRight CRD_UNIFORM/0/0/0

		ObjectTemplate.activeSafe GenericProjectile USPIS_92FS_silencer_Projectile
		ObjectTemplate.createComponent DefaultDetonationComp
		ObjectTemplate.detonation.explosionMaterial 939
		ObjectTemplate.detonation.explosionRadius 75
		ObjectTemplate.detonation.explosionForce 2750
		ObjectTemplate.detonation.explosionDamage 0
		ObjectTemplate.timeToLive CRD_NONE/10/0/0
                """)
Of course that's not the entire code but you get the idea.

Python grants you a lot of access to the game through various events.. which gives you a lot of control over how the game is played. Create your own custom triggers on common events..
LightSpeed///
Posts: 44
Joined: Sun Oct 18, 2009 3:06 pm

Re: bf2 modding

Post by LightSpeed/// »

If you have ever seen what Awesome A-Train did in BF2142 (which uses the same engine as BF2 only slightly modified, so you should be able to do similar things), then you would be impressed. You can make objects attract heat-seeking missiles, you can also make things fire like a shotgun (ala rocket shotgun), make vehicles fly (flying tanks), and then some
AKA WhatThe
axemanbfv
Posts: 3
Joined: Sat Feb 27, 2010 6:32 am
Contact:

Re: bf2 modding

Post by axemanbfv »

what about adding planes/heli's that aren't already in the map...
Player
Posts: 28
Joined: Sat Oct 24, 2009 5:06 pm

Re: bf2 modding

Post by Player »

axemanbfv wrote:what about adding planes/heli's that aren't already in the map...
Client Side is no problem in demo they pulled over all the retail maps / vehicles etc and provide it as a download..
I've never seen a working SSM.
Post Reply