Jump to content
Sign in to follow this  
edc

Ammo does't exist ingame

Recommended Posts

Edit: Nm, someone replied to my post @ OFPEC. In case anyone else has this problem, here's the thread http://www.ofpec.com/yabbse....d=13877

OK, the ammo from my config, just doesn't show up in game.  It gives me the error message like you get when you misspell the name of a magazine, when you put

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">this addmagazine "edcFLASHRocketHE" in someone's init field and start the mission.

I'm sure I'm not misspelling it.

Also, I get a no entry modelSpecial error when I try to start a mission w/ the M-202 guy defined in the config.

Here's my cpp:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">//M202 FLASH

//By edc-From OFP Forums imemyself-From OFPEC

//olrbengax@cox.net

// Basic def.

#define TEast 0

#define TWest 1

#define TGuerrila 2

#define TCivilian 3

#define TSideUnknown 4

#define TEnemy 5

#define TFriendly 6

#define TLogic 7

#define true 1

#define false 0

// type scope

#define private 0

#define protected 1

#define public 2

class CfgPatches

{

class edcFLASH

{

units[]={edcFLASHSoldier};

weapons[]={edcFLASHLauncher};

requiredVersion=1.91000;

};

};

class CfgModels

{

class Default{};

class Weapon: Default{};

class edcFLASHLauncher: Weapon{};

};

class CfgAmmo

{

class Default {};

class AT3: Default {};

class LAW: AT3 {};

class edcFLASHRocketHE: LAW

 {

hit=200;

indirectHit=125;

indirectHitRange=10;

minRange=30;

midRange=100;

maxRange=150;

simulation="shotRocket";

simulationStep=0.050000;

};

};

class CfgWeapons

{

class Default {};

class LAWLauncher: Default {};

class edcFLASHLauncher: LAWLauncher

{  

   modelOptics="optika_LAW";

   weaponType=16;

   modelSpecial = "";

model="\edcFLASH\m202";

displayName="M-202 FLASH";

displayNameMagazine="M-202 Flash Rocket";

shortNameMagazine="FLASH Round";

ammo="edcFLASHRocketHE";

picture="\edcFLASH\black.paa";

       magazineType="4 * 256";

       count=4;

       reloadTime=0.7500000;

};

};

class CfgVehicles

{

class All{};

class AllVehicles: All{};

class Land: AllVehicles{};

class Man: Land{};

class Soldier: Man{};

class SoldierWB: Soldier{};

class SoldierWLAW: SoldierWB{};

class edcFLASHSoldier: SoldierWLAW

{

   access=2;

displayName="M202 Soldier";

weapons[]={"Throw","Put","edcFLASHLauncher","M16"};

magazines[]={"M16","M16","M16","M16","M16","edcFLASHRocketHE"};

reloadTime=1.000000;

type=0;

vehicleClass = "Men";

};

};

class CfgNonAIVehicles

{

class ProxySecWeapon {};

class ProxyedcFLASHSoldier : ProxySecWeapon {};

};

BTW, I get no errors when starting OFP, and when I add the launcher to someone, there are no errors.  And, I searched for the modelSpecial thing, the only one that looked like it was similar said to put modelSpecial="" in the weapons part.

Share this post


Link to post
Share on other sites

Hello, I saw two mistake but maybe there is more I would see it later but try to correct that and try it again..

First I saw the name of the cfgpatch and cfgmodel are the same "verry good" but you must name the "P3D" model as the same of the cfgmodel or vis-versa*

like this : name of the model is ***mymodel***.p3d

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

class CfgModels

{

class Default{};

class Weapon: Default{};

class ***mymodel***: Weapon{};

};

And remove that from your cfgvehicles dont rememeber exactly where you can modify the reloadtime I think is in cfgweapon or cfgammo for human cfgvehicle. And the type and vehicleclass is inehrit from the previous class of soldier in your case is SoliderWLaw your soldier is in West side and in game he has the picture of Law soldier.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

reloadTime=1.000000;

type=0;

vehicleClass = "Men";

Share this post


Link to post
Share on other sites

OK, I'll do that. It seems to work ingame, but I guess it might cause problems down the road.

BTW, is it possible to have a muzzle flash on a rocket launcher? I have a flame, and it's named zasleh, but it shows up all the time. rock.gif Thx for your help. smile_o.gif

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×