Jump to content
Sign in to follow this  
Quel

Need help with config

Recommended Posts

Hello, I have a problem with the config of my ship.

The problem is that i cant fire my rockets in game and i cant see the models/proxy of my rockets.

The .pbo file is called "myship", the rocket .p3d "RSM52" and the ship .p3d "ship1". The Proxy is "proxy:\myship\RSM52.p3d.01", in the Brsseb-tutorial they said that i should write "proxy:RSM52.01", but i made that and i got an error massage. The Config is a mix of the Brsseb-tutoial about gunboats and the tutorial about armed airplanes.

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

#define TEast 1

#define TWest 0

#define TGuerrila 2

#define TCivilian 3

#define TSideUnknown 4

#define TEnemy 5

#define TFriendly 6

#define TLogic 7

#define true 1

#define false 0

#define private 0

#define protected 1

#define public 2

class CfgPatches

{

class Ship1

{

units[] = {Ship1};

weapons[] = {};

requiredVersion = 1.75;

};

};

class CfgModels

{

class default{};

class Ship : default{};

class Ship1: Ship{};

class Weapon: default {};

class RSM52: Weapon {};

};

class CfgAmmo

{

class Default {};

class AT3: Default {};

class CarlGustav: AT3 {};

class RSM52 : CarlGustav

{

minRange=100;minRangeProbab=0.8;

midRange=500;midRangeProbab=1.0;

maxRange=2000;maxRangeProbab=1.0;

airLock=1;

irLock=0;

initTime=0.5;

ThrustTime=100;

thrust=1000;

maxspeed=1300;

hit=100;indirectHit=80;indirectHitRange=3;

model = "\myship\RSM52.p3d";

proxyShape="\myship\RSM52.p3d";

manualControl=0;

maxControlRange=2000;

maneuvrability=100.0;

};

};

class CfgWeapons

{

class Default{};

class LAWLauncher: Default {};

class CarlGustavLauncher : LAWLauncher {};

class AT3Launcher: CarlGustavLauncher {};

class HellfireLauncher: AT3Launcher {};

class MaverickLauncher: HellfireLauncher {};

class RSM52_Launcher: MaverickLauncher

{

ammo=RSM52;

displayName="AIM-9L Sidewinder";

displayNameMagazine="SidewinderA";

shortNameMagazine="RSM52";

magazine="RSM52";

count=6;

initspeed=15;

model = "\myship\RSM52.p3d";

proxyShape ="\myship\RSM52.p3d";

canLock=2;

sound[]={Weapons\Missile,db+18,1};

aiRateOfFire=8;

aiRateOfFireDistance=3500;

};

};

class CfgVehicles

{

class All{};

class AllVehicles:All{};

class Land : AllVehicles {};

class Ship: AllVehicles{};

class BigShip: Ship{};

class Ship1: BigShip

{

displayName="Ship1";

accuracy=0.80;

fuelCapacity=500;

model="\myship\Ship1.p3d";

weapons[]= {RSM52_Launcher};

magazines[]= {RSM52_Launcher};

vehicleClass="Armored";

scope=public;

hasDriver=true;

hasGunner=true;

hasCommander=false;

driverIsCommander=true;

getInRadius=40;

driverAction="ManActJeepDriver";

driverInAction="ManActJeepDriver";

gunnerAction="ManActJeepCoDriver";

gunnerInAction="ManActJeepCoDriver";

gunnerOpticsModel="optika_zsu_gunner";

cargoAction[]={"ManActShipCargo"};

irScanRange=4000;

irScanGround=1;

side=TEast;

type=VArmor;

crew="SoldierECrew";

maxSpeed=70;

steerAheadSimul=2;

steerAheadPlan=2;

predictTurnSimul=3;

predictTurnPlan=3;

transportSoldier=4;

transportAmmo=10000;

};

};

class CfgNonAIVehicles

{

class ProxyWeapon {};

class ProxyRSM52: ProxyWeapon

{

model="\myship\RSM52.p3d"; simulation="maverickweapon";

};

};

I tried so much, but it doesnt work.  help.gif

Share this post


Link to post
Share on other sites

I only had a quick scan, but according to the information you gave, your CfgPatches should be:

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

class CfgPatches

{

class myship

{

units[] = {ship1};

weapons[] = {RSM52_Launcher};

requiredVersion = 1.75;

};

};

Try that anyway, I might pop in later and have a better look.

Planck

Share this post


Link to post
Share on other sites

You forget that the only weapons that can be fired from a SHIP class is bullets, not shells, rockets, or bombs.  It takes the MCAR system or create a static vehicle and setpos it regularly to the needed area via scripting in order for you to have a ship that can fire rockets, missiles, or shells.

This is the only way to get around the BIS game engine limitations.

Share this post


Link to post
Share on other sites

Thx guys. So now I should create a new model which can fire rockets. And this model should I include in the ship per script. And this script I have to do define in the config, right?

How I have to define the script in the config, or what could I write in the script? (sry but I am a config and script noob)

Share this post


Link to post
Share on other sites

Can't you just give a missile model to the bullets from this ship weapon and change its speed and initial speed (and rate of fire too) ?

By example, the M202A1 addon from DMA , despite being visually ingame a rocket launcher is in fact a rifle in its config (so the user can fire from the 3 positions : standing, crouching, prone)

What this weapon is launching is not rocket (despite being visually rocket ingame) but in fact bullets using a rocket model with tweaked values to look like a missile in both visual and speed/drop/rate of fire.

With a script attaching smoke and a light to this bullet, it really looks like and behave like a rocket launcher ingame.

So i guess it should be interesting for you to just modifiy the bullets "launched" by your ship into using missiles models and tweaked values to match a missile behaviour.

Share this post


Link to post
Share on other sites
Can't you just give a missile model to the bullets from this ship weapon and change its speed and initial speed (and rate of fire too) ?

But this is an unguided rocket. Most ship launched missiles are guided types.

The only way I've managed to add guided missiles to ships is via the MCAR type "attaching" scripts etc.

BTW, nice addon too Sanctuary smile_o.gif .... I hadnt played with it til now.

Share this post


Link to post
Share on other sites

Oops, yes you are totally right, i didn't thought about the guided feature.

thanks for the reminder

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  

×