Jump to content

sfc.itzhak

Member
  • Content Count

    155
  • Joined

  • Last visited

  • Medals

Posts posted by sfc.itzhak


  1. i really dont see what you are complaining..

    you can make human solders just take slx_pepole as refrance..

    god know i did it and my soilder works with all the animations..

    do a little research and you will see that you can make everyting without the tools..

    sfc


  2. ok.

    i looked in the bulletcam script and this is what i ended up with

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

    ? isNull _Missile : exit

    _Type= typeOf _Missile

    #loop

    ? isNull _Missile : end

    _dis2=_Missile distance player

    _dis1 = round _dis2

    _str = format["%1 meters",(_dis1)]

    ? ctrlvisible 100 : goto "loop"

    #End

    titleText [_str, "PLAIN"];

    setAccTime 1

    exit

    but still the maximum distance i get is 80 meters..

    any ideas?


  3. You're getting that number because when the bullet impacts it is deleted. 0.1 seconds is by no means an accurate way to determine when the bullet impacts anyway. It could take less time than that and when it does impact you'll lose the _round variable since the bullet will no longer exist. You need to use a loop that constantly records the bullet's position and exits when the bullet no longer exists, that will give you the most accurate impact position.

    thanks for the fast reply.

    any chance you can give me an example of how to do that?

    or even help with this small part?

    thanks sfc.itzhak


  4. hi..

    i am trying to make an addon that whan it fires the ammunition the script will calculate the distance between the object and the bulit impact point..

    i use this script

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

    _mg = _this select 0;

    _ammo = _this select 1;

    _round = nearestobject [_this select 0,_this select 4];

    ~0.1

    _dist = _mg distance _round;

    _intdest = round _dist

    _a1 = (_intdest - _intdest mod 10000) / 10000

    _a2 = (_intdest mod 10000 - _intdest mod 1000) / 1000

    _a3 = (_intdest mod 1000 - _intdest mod 100) / 100

    _a4 = (_intdest mod 100 - _intdest mod 10) / 10

    _a5 = (_intdest mod 10)

    _str = format["Distance: %1%2%3%4%5", _a1, _a2, _a3, _a4, _a5];

    titleText [_str, "PLAIN"];

    and sometimes i get numbers that look ok but most of the time i get this value ..

    assault_bridge.jpg

    dunno why it dose this ..

    any idea.

    p.s

    this is the weapon and ammo sitting if you need it.

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

    {

    class BulletBase;

    class LaserRangeFinderAmmo : BulletBase

    {

    hit = 0;

    indirectHit = 0;

    indirectHitRange = 0;

    model = "";

    soundFly[] = {};

    hitGround[] = {};

    hitMan[] = {};

    hitArmor[] = {};

    hitBuilding[] = {};

    cartridge = "";

    cost = 0.0;

    deflecting = 0;

    visibleFire = 1; // how much is visible when this weapon is fired

    audibleFire = 0;

    visibleFireTime = 20; // how long is it visible

    timeToLive = 20;

    typicalSpeed = 10;

    };

    };

    class CfgMagazines

    {

    /*

    class VehicleMagazine;

    class 1000Rnd_127x99_M2 : VehicleMagazine

    {

    scope = public;

    displayName = $STR_DN_M2_MG;

    ammo = "B_127x99_Ball";

    count = 1000;

    initSpeed = 930;

    };

    */

    class CA_Magazine;

    class LaserRangeFinderCharge : CA_Magazine

    {

    scope = public;

    displayName = "Laser range finder charges";

    ammo = "LaserRangeFinderAmmo";

    count = 1000;

    initSpeed = 1000;

    }

    };

    class CfgWeapons

    {

    class MGun;

    class LaserRangerFinder : MGun

    {

    scope = protected;

    displayName = "Laser ranger finder";

    autoFire = true;

    magazines[] = {"LaserRangeFinderCharge"};

    sound[] = {};

    soundServo[] = {};

    reloadTime = 0.11;

    magazineReloadTime = 15;

    dispersion = 0;

    canLock = LockNo;

    minRange = 1;

    minRangeProbab = 1;

    midRange = 5000;

    midRangeProbab = 0;

    maxRange = 10000;

    maxRangeProbab = 0;

    aiDispersionCoefY = 7.0;

    aiDispersionCoefX = 7.0;

    };

    };

    thanks

    sfc.itzhak


  5. so the solution to this unneeded comments like this one

    Quote[/b] ]Very nice to see that people who post actual ingame WIP pictures are blamed for that huh.gif

    is to make anyone that wants to post here to give a wip??

    i really don't see the purpose of this commants..

    and so my post wont be spam ..

    ch46.

    ch463.jpg

    ch461.jpg

    and stop with this nonsense!

    good day

    sfc..itzhak


  6. well said nephilim.

    and i will add 1 more thing..

    all vbs2 stuff are encrypted and cannot be used ...

    AND like vbs1 it uses a usb key...

    so if you want to see vbs2 stuff you can always buy them..

    OR make them yourself.

    have a good week

    sfc.itzhak


  7. hey..

    i have a watch tower with an my created optics.

    i have add 4 section in the optics so they will be used as hidden selctions for the lasing.

    i use this script to get the distance from the watch tower to the bullt..

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

    _mg = _this select 0

    _ammo = _this select 1;

    _basename = "\gaza_obj\hud\n"

    _type = _this select 4

    _shell = nearestobject [_this select 0,_this select 4];

    ~2

    _return =_mg distance _shell;

    ~.1

    ; Break the altitude into integers

    _alt =_return

    _a1 = (_alt - _alt mod 10000) / 10000

    _a2 = (_alt mod 10000 - _alt mod 1000) / 1000

    _a3 = (_alt mod 1000 - _alt mod 100) / 100

    _a4 = (_alt mod 100 - _alt mod 10) / 10

    _a5 = ((_alt mod 10) - _alt % 1)

    _str = format["%1%2.pac", _basename, _a1]

    _mg setobjecttexture[0, _str]

    _str = format["%1%2.pac", _basename, _a2]

    _mg setobjecttexture[1, _str]

    _str = format["%1%2.pac", _basename, _a3]

    _mg setobjecttexture[2, _str]

    _str = format["%1%2.pac", _basename, _a4]

    _mg setobjecttexture[3, _str]

    _str = format["%1%2.pac", _basename, _a5]

    _mg setobjecttexture[4, _str]

    ~4

    #HudOFF

    _mg setobjecttexture[0, ""]

    _mg setobjecttexture[1, ""]

    _mg setobjecttexture[2, ""]

    _mg setobjecttexture[3, ""]

    _mg setobjecttexture[4, ""]

    now my q is how do i aplly those hidden selction on the optics?

    if i missed a detail tell me...

    thanks in advance

    sfc


  8. hey

    i am making an apc and for some reason it shows under car in the editor and non of the animation work even the gunners ows wont work or fire...

    my tank uses almost the same config and it works great...

    the config..

    <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">#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 achzrit

    {

    units[] = {};

    requiredVersion = 1.0;

    };

    };

    #include <CfgSkeletons.h>

    class CfgVehicles {

    class Land; // External class reference

    class LandVehicle : Land {

    class NewTurret; // External class reference

    class ViewOptics; // External class reference

    };

    class Tank : LandVehicle {

    driverOpticsModel = "\ca\Tracked\optika_tank_driver";

    commanderCanSee = 30;

    gunnerCanSee = 30;

    class HitHull {

    armor = 1;

    material = 55;

    name = "telo";

    visual = "telo";

    passThrough = 1;

    };

    class HitLTrack {

    armor = 0.15;

    material = 55;

    name = "pas_L";

    visual = "pas_L";

    passThrough = 1;

    };

    class HitRTrack {

    armor = 0.15;

    material = 55;

    name = "pas_P";

    visual = "pas_P";

    passThrough = 1;

    };

    class HitEngine {

    armor = 0.4;

    material = 60;

    name = "motor";

    visual = "motor";

    passThrough = 1;

    };

    weapons[] = {};

    magazines[] = {};

    class Turrets {

    class MainTurret : NewTurret {

    gunnerAction = "ManActTestDriverOut";

    gunnerOpticsModel = "\ca\Tracked\optika_tank_gunner";

    gunnerOutOpticsModel = "\ca\Weapons\optika_empty";

    gunBeg = "usti hlavne";

    gunEnd = "konec hlavne";

    memoryPointsGetInGunner = "pos driver";

    memoryPointsGetInGunnerDir = "pos driver dir";

    class HitTurret {

    armor = 0.8;

    material = 55;

    name = "vez";

    visual = "vez";

    passThrough = 1;

    };

    class HitGun {

    armor = 0.4;

    material = 55;

    name = "zbran";

    visual = "zbran";

    passThrough = 1;

    };

    class Turrets {

    class CommanderOptics : NewTurret {

    proxyType = "CPCommander";

    proxyIndex = 1;

    gunnerName = $STR_POSITION_COMMANDER;

    primaryGunner = 0;

    primaryObserver = 1;

    body = "obsTurret";

    gun = "obsGun";

    animationSourceBody = "obsTurret";

    animationSourceGun = "obsGun";

    animationSourceHatch = "hatchCommander";

    soundServo[] = {"", 0.00316228, 1.0};

    gunBeg = "";

    gunEnd = "";

    minElev = -4;

    maxElev = 20;

    initElev = 0;

    minTurn = -360;

    maxTurn = 360;

    initTurn = 0;

    commanding = 2;

    outGunnerMayFire = 1;

    inGunnerMayFire = 1;

    gunnerOpticsModel = "\ca\Tracked\optika_tank_driver";

    gunnerOutOpticsModel = "\ca\Weapons\optika_empty";

    gunnerOutOpticsColor[] = {0, 0, 0, 1};

    gunnerOutForceOptics = 0;

    gunnerOutOpticsShowCursor = 0;

    memoryPointGunnerOutOptics = "commander_weapon_view";

    memoryPointGunnerOptics = "commanderview";

    memoryPointsGetInGunner = "pos driver";

    memoryPointsGetInGunnerDir = "pos driver dir";

    memoryPointGun = "gun_muzzle";

    selectionFireAnim = "zasleh_1";

    class ViewOptics {

    initAngleX = 0;

    minAngleX = -30;

    maxAngleX = 30;

    initAngleY = 0;

    minAngleY = -100;

    maxAngleY = 100;

    initFov = 0.6;

    minFov = 0.6;

    maxFov = 0.6;

    };

    class ViewGunner {

    initAngleX = 5;

    minAngleX = -30;

    maxAngleX = 30;

    initAngleY = 0;

    minAngleY = 0;

    maxAngleY = 0;

    initFov = 0.7;

    minFov = 0.6;

    maxFov = 0.7;

    };

    };

    };

    };

    };

    soundEnviron[] = {"\ca\Tracked\Data\Sound\OldRolling_Treads1", 7.94328, 0.8};

    soundEngine[] = {"\ca\Tracked\Data\Sound\OldIdle1", 10.0, 1};

    soundCrash[] = {"\ca\Tracked\Data\Sound\crash2", 31.6228, 1};

    soundGear[] = {"\ca\Tracked\Data\Sound\Gear_Trans1", 0.01, 1};

    soundDammage[] = {"\ca\Tracked\Data\Sound\alarm_loop1", 1.0, 1};

    getInAction = "GetInmedium";

    getOutAction = "GetOutmediun";

    supplyRadius = 1.5;

    simulation = "tank";

    class ViewOptics : ViewOptics {

    initAngleX = 0;

    minAngleX = -30;

    maxAngleX = 30;

    initAngleY = 0;

    minAngleY = -100;

    maxAngleY = 100;

    initFov = 0.9;

    minFov = 0.9;

    maxFov = 0.9;

    };

    };

    class achzrit : tank

    {

    displayName = "achzrit";

    model = "\achzrit\achzrit.p3d";

    selectionLeftOffset = "pasanimL";

    selectionRightOffset = "pasanimP";

    scope=2;

    side = 1;

    accuracy = 0.8;

    picture = "\ca\tracked\Data\ico\M1_abrams_CA.paa";

    Icon = "\Ca\tracked\Data\map_ico\icomap_m1a1_CA.paa";

    mapSize = 7;

    armor = 900;

    nameSound = "APC";

    maxSpeed = 60;

    hiddenSelections[] = {""};

    hiddenSelectionsTextures[] = {""};

    transportSoldier = 7;

    hasCommander = false;

    unloadInCombat = true;

    crew = "SoldierWB";

    class TransportMagazines {};

    transportAmmo = 0;

    supplyRadius = 1.7;

    cost = 150000;

    canFloat = 0;

    typicalCargo[] = {"SoldierwCrew", "SoldierwCrew"};

    viewCargoShadow = 1;

    threat[] = {0.7, 1.0, 0.3};

    soundGetIn[] = {"\ca\Tracked\Data\Sound\metal_door2", 0.01, 1};

    soundGetOut[] = {"\ca\Tracked\Data\Sound\metal_door2", 0.00316228, 1};

    soundEnviron[] = {"\ca\Tracked\Data\Sound\M1A2_track_v2", 5.01187, 1};

    soundEngine[] = {"\ca\Tracked\Data\Sound\Brdm_engine_3", 7.94328, 0.9};

    driverAction = "BMP2_DriverOut";

    driverInAction = "BMP2_Driver";

    memoryPointTrack1L = "Stopa ll";

    memoryPointTrack1R = "Stopa lr";

    memoryPointTrack2L = "Stopa rl";

    memoryPointTrack2R = "Stopa rr";

    cargoIsCoDriver[] = {0};

    cargoAction[] ={"Stryker_Cargo01","Stryker_Cargo01","Stryker_Cargo01","Stryker_Cargo01","Stryker_Cargo01","Stryker_Cargo01","Stryker_Cargo01","BMP2_Commander"};

    driverForceOptics = 0;

    class Turrets

    {

    class MainTurret : NewTurret

    {

    body = "OtocVez";

    gun = "OtocHlaven";

    animationSourceBody = "mainTurret";

    animationSourceGun = "mainGun";

    animationSourceHatch = "hatchGunner";

    class HitTurret

    {

    armor = 0.8;

    material = 55;

    name = "vez";

    visual = "vez";

    passThrough = true;

    };

    class HitGun

    {

    armor = 0.4;

    material = 55;

    name = "zbran";

    visual = "zbran";

    passThrough = true;

    };

    weapons[] = {M240_veh};

    magazines[] = {"1200Rnd_762x51_M240"};

    soundServo[] = {"\ca\Weapons\Data\Sound\gun_elevate", 0.001, 1.0};

    minElev = -4;

    maxElev = 33;

    minTurn = -360;

    maxTurn = 360;

    gunnerAction = "BMP2_GunnerOut";

    gunnerInAction = "BMP2_Gunner";

    forceHideGunner = 0;

    gunnerOpticsModel = "\ca\Tracked\optika_M1A1_gunner";

    gunnerForceOptics = false;

    gunnerOutOpticsModel = "\ca\weapons\optika_empty";

    };

    };

    };

    };

    the CfgSkeletons.h

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

    {

    class Tank; //Define base class.

    class achzritBones : tank

    {

    isDiscrete=1;

    skeletonInherit = ""; //Inherit all bones from class Car.

    skeletonBones[]=

    {

    "levy predni","",

    "levy dalsi","",

    "levy prostredni","",

    "levy zadni","",

    "pravy predni","",

    "pravy dalsi","",

    "pravy prostredni","",

    "pravy zadni","",

    "OtocVez","",

    "OtocHlaven","OtocVez",

    "kolol1","",

    "kolol2","",

    "kolol3","",

    "kolol4","",

    "kolol5","",

    "kolol6","",

    "koll1","",

    "koll2","",

    "kolop1","",

    "kolop2","",

    "kolop3","",

    "kolop4","",

    "kolop5","",

    "kolop6","",

    "kolp1","",

    "kolp2",""

    };

    };

    };

    class CfgModels

    {

    class Tank; //Declare base class.

    class achzrit: tank

    {

    sectionsInherit = "";

    sections[] ={"pas_P","koll1","koll2","kolp1","kolp2","koloL1","koloL2","koloL3","koloL4","koloL5","koloL6","kolP1","koloP1","koloP2","koloP3","koloP4","koloP5","koloP6","pravy zadni","pasanimL","pasanimP","levy zadni","L svetlo", "P svetlo"};

    skeletonName = "achzritBones";

    class Animations

    {

    class OtocVez

    {

    type = "rotationY";

    source = "mainTurret";

    selection = "OtocVez";

    axis = "OsaVeze";

    memory = true;

    sourceAddress = "loop";

    minValue = rad -360;

    maxValue = rad +360;

    angle0 = rad -360;

    angle1 = "rad 360";

    };

    class OtocHlaven

    {

    type = "rotationX";

    source = "mainGun";

    selection = "OtocHlaven";

    axis = "OsaHlavne";

    memory = true;

    sourceAddress = "clamp";

    minValue = "rad -4.5";

    maxValue = "rad 35";

    angle0 = "rad -5.5";

    angle1 = "rad 35";

    };

    class achkoloL1

    {

    type = "rotationX";

    source = "wheelL";

    selection = "kolol1";

    axis = "";

    memory = true;

    sourceAddress = "loop";

    minValue = 0;

    maxValue = 1;

    angle0 = 0;

    angle1 = "rad -360";

    };

    class achkoloL2 :achkoloL1

    {

    selection = "kolol2";

    };

    class achkoloL3 :achkoloL1

    {

    selection = "kolol3";

    };

    class achkoloL4 :achkoloL1

    {

    selection = "kolol4";

    };

    class achkoloL5 :achkoloL1

    {

    selection = "kolol5";

    };

    class achkoloL6 :achkoloL1

    {

    selection = "kolol6";

    };

    class achkoll1 :achkoloL1

    {

    selection = "koll1";

    };

    class achkoll2 :achkoloL1

    {

    selection = "koll2";

    };

    class achkolop1

    {

    type = "rotationX";

    source = "wheelr";

    selection = "kolop1";

    axis = "";

    memory = true;

    sourceAddress = "loop";

    minValue = 0;

    maxValue = 1;

    angle0 = 0;

    angle1 = "rad -360";

    };

    class achkolop2 :achkolop1

    {

    selection = "kolop2";

    };

    class achkolop3 :achkolop1

    {

    selection = "kolop3";

    };

    class achkolop4 :achkolop1

    {

    selection = "kolop4";

    };

    class achkolop5 :achkolop1

    {

    selection = "kolop5";

    };

    class achkolop6 :achkolop1

    {

    selection = "kolop6";

    };

    class achkolop7 :achkolop1

    {

    selection = "kolop7";

    };

    class achkolop8 :achkolop1

    {

    selection = "kolop8";

    };

    class achkolop9 :achkolop1

    {

    selection = "kolop9";

    };

    class achkolp1 :achkolop1

    {

    selection = "kolp1";

    };

    class achkolp2 :achkolop1

    {

    selection = "kolp2";

    };

    class mkDrivingWheel

    {

    type = "rotationZ";

    source = "drivingWheel";

    selection = "volant";

    axis = "osavolantkon";

    memory = true;

    sourceAddress = "mirror";

    minValue = -1;

    maxValue = 1;

    angle0 = "rad -35";

    angle1 = "rad 35";

    };

    };

    };

    };

    thanks in advance..


  9. i want to simulate the tracks goes off its place

    i will explain..

    if a atank turns in the spot he will "loose" his track because it can slip out of place

    so i want to calculate how meny degrees did the tanks hull did without moving 1 meter

    so is it possible?

    thanks

    sfc


  10. is it possible to calculate who many degrees did the tank (not the turret) did??

    like a script that will calculate how many degrees did the tank hull did and how meny meter did he move in that time..

    i know it seems impossible but is there a way??

    thanks

    sfc.itzhak

×