shortylaforge 0 Posted January 18, 2003 I have built a Tie Fighter up to 99%, but I need some help to configure my new Bullet Model in the Config.CPP. Here's the Weapons Part of my CPP: ///////////////////////////////////////////////////////////////////////////////// class CfgPatches { class Tie_Fighter { units[] = {Tie_Fighter}; weapons[] = {}; requiredVersion = 1.40; }; class lasergun { units[] = {}; weapons[] = {lasergun}; requiredVersion = 1.40; }; }; class CfgAmmo { class Default {}; class BulletSingle: default { model = "\Tie_Fighter\laser_ammo"; Â Â }; class ExplosiveBullet: BulletSingle {}; class Bullet30: ExplosiveBullet {}; class laserbullet: Bullet30 { hit=30; indirectHit=10; explosive=0; soundFly[]={\Tie_Fighter\blaster.wav,1,1}; soundEngine[]={\Tie_Fighter\blaster.wav,1,1}; soundHit[]={}; }; }; class CfgWeapons { class Default {}; class MGun: Default {}; class MachineGun7_6: MGun {}; class MachineGun30: MachineGun7_6 {}; class lasergun: MachineGun30 { proxyShape="\Tie_Fighter\laser_ammo"; displayName="Laser Gun"; displayNameMagazine="20mm canon"; shortNameMagazine="20mm mag"; ammo=laserbullet; count=3000; reloadTime=0.090000; initSpeed=700; sound[]={"\Tie_Fighter\blaster.wav",3.162278,1}; soundContinuous=0; flashSize=0.000000; maxLeadSpeed=450; optics=1; // model = "\Tie_Fighter\laser_ammo"; }; }; //////////////////////////////////////////////////////////////////////////////// If i define a Weapon proxy (Look @ Bold text) for my Laser Cannon OFP searches the modell in /data3d/... and not in my Addon Folder !!! ==> OFP crashes.... If i define a known proxy in OË› and config.cpp like proxy:Mav.1 it works fine, but not with my 3D Model.... ***AAaaarrrgghhh*** Is this really normal in OFP ?? How should i define my own Weapon Proxy with its own model ? PS: The Config in OË› isn't my Problem i think. Can U help me?? Share this post Link to post Share on other sites
AXE 0 Posted January 18, 2003 the proxy is supposed to be loaded in the cfg ammo section, not the cfgweapons section. Also, you need to remove the // from the line: // model = "\Tie_Fighter\laser_ammo"; because this defines the FIRED ammunition. Proxies aren't the fired ammuntion, they actually just disappear and are replaced with the fired ammunition model when the weapon is fired. Hope this helps Share this post Link to post Share on other sites
Rastavovich 0 Posted January 18, 2003 BTW: take out the model = ... of the class BulletSingle. Those classes are the original ones and they are read only, so you cannot change them. Plcae the model line in your Laserammo class instead. Share this post Link to post Share on other sites
shortylaforge 0 Posted January 19, 2003 Now Ive changed the entry like this: //////////////////////////////////////////////////////////////////// class CfgAmmo { class Default {}; class BulletSingle: default {}; class ExplosiveBullet: BulletSingle {}; class Bullet30: ExplosiveBullet {}; class laserbullet: Bullet30 { hit=30; indirectHit=10; proxyShape="\Tie_Fighter\LaserAmmo"; explosive=0; soundFly[]={\Tie_Fighter\blaster.wav,1,1}; soundEngine[]={\Tie_Fighter\blaster.wav,1,1}; soundHit[]={}; }; }; class CfgWeapons { class Default {}; class MGun: Default {}; class MachineGun7_6: MGun {}; class MachineGun30: MachineGun7_6 {}; class lasergun: MachineGun30 { displayName="Laser Gun"; displayNameMagazine="20mm canon"; shortNameMagazine="20mm mag"; ammo=laserbullet; count=3000; reloadTime=0.120000; initSpeed=700; sound[]={"\Tie_Fighter\blaster.wav",3.162278,1}; soundContinuous=0; flashSize=0.000000; maxLeadSpeed=450; optics=1; model="\Tie_Fighter\LaserAmmo"; }; }; //////////////////////////////////////////////////////////////////// And the OFP Engine told me this: Cannot open object: data3d\laserammo.p3d Whats the Problem? PS: I don't find any Addon that uses its own Proxys. Nothing like proxyshape=myproxy !!!! Only the naming BIS use !! Share this post Link to post Share on other sites
Rastavovich 0 Posted January 19, 2003 </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE">Code from official commented config: class Maverick: Hellfire // A10 AT { hit=1900;indirectHit=800;indirectHitRange=2.5; model = Maverik; minRange=200;minRangeProbab=0.30; midRange=600;midRangeProbab=0.80; maxRange=2000;maxRangeProbab=0.50; thrust=700; laserLock=false; proxyShape = Maverik_proxy; };<span id='postcolor'> the model needs to be defined in the cfgammo, not in the cfgweapon. Share this post Link to post Share on other sites
der bastler 0 Posted January 19, 2003 Perhaps you should remove the model-entry in class lasergun: </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE"> class lasergun: MachineGun30 { Â displayName = "Laser Gun"; Â displayNameMagazine = "20mm canon"; Â shortNameMagazine = "20mm mag"; Â ammo = laserbullet; Â count = 3000; Â reloadTime = 0.120000; Â initSpeed = 700; Â sound[] = {"\Tie_Fighter\blaster.wav",3.162278,1}; Â soundContinuous = 0; Â flashSize = 0.000000; Â maxLeadSpeed = 450; Â optics = 1; Â <s>model = "\Tie_Fighter\LaserAmmo";</s> }; <span id='postcolor'> Or does the laser cannon look like the ammo? Share this post Link to post Share on other sites
shortylaforge 0 Posted January 19, 2003 Ive got the solution for this mess: ///////////////////////////////////////////////////////////////////// class CfgNonAIVehicles { class ProxyWeapon {}; class ProxyLaserAmmo : ProxyWeapon {model = "\Tie_Fighter\LaserAmmo.p3d"; simulation = "alwaysshow";} }; ///////////////////////////////////////////////////////////////// after Class CfgVehicles and it works fine.. Thx for all help... Share this post Link to post Share on other sites
shortylaforge 0 Posted January 20, 2003 If i changed the Class from bullet to rocket thy fly backwards out of my vehicle (center). LOL I define a proxyshape for my Quanten-Torpedos.. and the first one looks fine. But if i press the Fire Button they come out of my back ;p==)) //////////////////////////////////////////////////////////////////// class CfgAmmo { class Default {}; class AT3: Default {}; class CarlGustav: AT3 {}; class AA : CarlGustav {}; class LaserAmmo : AA { proxyShape="\Tie_Fighter\LaserAmmo"; reloadTime=0.05; maneuvrability=15.0; irLock=false; airLock=false; laserLock=false; initTime=0.05; maxleadspeed=4000; ThrustTime=0.01; visibleFire=0; audibleFire=0; visibleFireTime=0; minRange=1;minRangeProbab=0.30; midRange=600;midRangeProbab=0.80; maxRange=2000;maxRangeProbab=0.50; maxControlRange=2000; thrust=7000; maxSpeed=700; hit=1900;indirectHit=800;indirectHitRange=2.5; model="\Tie_Fighter\LaserAmmo"; }; }; class CfgWeapons { class Default {}; class MGun: Default {}; class MachineGun7_6: MGun {}; class MachineGun30: MachineGun7_6 {}; class lasergun: MachineGun30 { displayName="Laser Gun"; displayNameMagazine="20mm canon"; shortNameMagazine="20mm mag"; ammo=LaserAmmo; count=3000; reloadTime=0.120000; initSpeed=700; sound[]={"\Tie_Fighter\blaster.wav",3.162278,1}; soundContinuous=0; flashSize=0.000000; maxLeadSpeed=450; optics=1; model="\Tie_Fighter\LaserAmmo"; }; }; class CfgNonAIVehicles { class ProxyWeapon {}; class ProxyLaserAmmo : ProxyWeapon {model = "\Tie_Fighter\LaserAmmo.p3d"; simulation = "maverickweapon";} }; ///////////////////////////////////////////////////////////////////7 And the define of weapon and magazines in the vehicle section.. Whats wrong?? Share this post Link to post Share on other sites
shortylaforge 0 Posted January 26, 2003 No one who can give a sample Config.cpp and simple p3d to see how it works? I also cannot change the MODEL in any Bullet type ammo, why? The only class which isn't Creatable is the Default class in cfgammo section. I create something like this: ///////////////////////////////////////////////////////////////////// class CfgAmmo { class Default {}; class LaserAmmo: default { model=\deltaflyer\deltaflyer; hit=1600;indirectHit=1000;indirectHitRange=5; explosive=1; visibleFire=16; audibleFire=16; visibleFireTime=3; // how long is it visible minRange=10;minRangeProbab=0.10; midRange=50;midRangeProbab=0.38; maxRange=200;maxRangeProbab=0.04; cartridge="FxCartridge"; cost = 0.7; soundFly[]={\deltaflyer\blaster.wav,1,1}; soundEngine[]={\deltaflyer\blaster.wav,1,1}; soundHit[]={\deltaflyer\blaster.wav,1,1}; simulation=shotBullet; simulationStep=0.05; }; }; //// And it works. But i can't change the ammo Model. The entry model=... doesn't works here. SH.... ;p( Share this post Link to post Share on other sites