Jump to content

Recommended Posts

Is there a way to inherit the configuration of the PhysX rope?


I'm trying to create a new class, with the default properties of the rope, but changing the 3d model.

 

class CfgVehicles
{
	class All {};
	class Rope: All {};
	class SCrope: Rope
	{
		access = 0;
		displayName = "";
		simulation = "rope";
		side = 8;
		maxRelLenght = 1.1;
		maxExtraLenght = 10.2;
		alwaysTarget = 0;
		irTarget = 0;
		irScanRangeMin = 0;
		irScanRangeMax = 0;
		irScanToEyeFactor = 1;
		laserTarget = 0;
		laserScanner = 0;
		nvTarget = 0;
		nvScanner = 0;
		artilleryTarget = 0;
		artilleryScanner = 0;
		author = "CheyenneAH56";
		mapSize = 0.03;
		_generalMacro = "Rope";
		scope = 1;
		model = "\SCmod_fire\data\SCrope.p3d";
	};
};

 

I can create a rope, because the attached objects behave like with the original one, but the rope is created invisible. The 3d model does not seem to work.

My goal is to create a pipe, with PhysX properties, for my SCmod.


The Project Life team succeeded in doing the same, except that they replaced the default rope model directly.

I can not contact them, so I rely heavily on the goodness of a BIS programmer. :)

Share this post


Link to post
Share on other sites

DONE !

 

:D

 

simply repack original pbo with your modification.

 

... I'll test to apply personal textures and add hiddensection, to conserv original model look. 

Share this post


Link to post
Share on other sites

for those who are interested, as this post is not known enormously successful, I have the solution.

 

I apply it to the SCmod (for next 1.40 version).

 

You can easily modify the size of the rope (to make a pipe), and if necessary keep its original appearance.

Share this post


Link to post
Share on other sites

Great news, I wanted to use a fuel pipe for a fuel pump on the Nimitz. Can you share with me how to achieve this with your new rope model? Either here or via PM.

 

I also would like to check if the current model wires can be replaced by this rope concept, e.g. two rope models connecting from the tailhook to the anchors. That can be used on the Nimitz and MAAS.

  • Like 1

Share this post


Link to post
Share on other sites

OK, here the method :

 

first

 

  • create a new addon (file) for your rope e.g. /YOUR_rope.

 

  • CPP
////////////////////////////////////////////////////////////////////
//DeRap: Produced from mikero's Dos Tools Dll version 4.39
//Mon Mar 17 00:27:58 2014 : Source 'file' date Mon Mar 17 00:27:58 2014
//http://dev-heaven.net/projects/list_files/mikero-pbodll
////////////////////////////////////////////////////////////////////

#define _ARMA_

//ndefs=13
//Class data_f : hook\config.bin{

class CfgPatches
{
	class YOUR_Rope
	{
		units[] = {};
		weapons[] = {};
		requiredVersion = 0.1;
		requiredAddons[] = {"A3_Data_F"};
	};
};
class CfgVehicles
{
//YOURROPE
	/*extern*/ class All;

	class Rope: All
	{
		model = "\YOUR_rope\proxies\Rope\rope.p3d";
		hiddenSelections[] = {"YOURSELECTION", "ORIGINALSELECTION"};
		hiddenSelectionsTextures[] = {"","a3\data_f\proxies\rope\data\rope_co.paa"};
	};
}
//};

class CfgNonAIVehicles
{
	class RopeSegment
	{
		model = "\YOUR_rope\proxies\Rope\rope.p3d";
		hiddenSelections[] = {"YOURSELECTION", "ORIGINALSELECTION"};
		hiddenSelectionsTextures[] = {"","a3\data_f\proxies\rope\data\rope_co.paa"};
	};
		
	class RopeEnd: RopeSegment
	{
		model = "\A3\Data_f\Hook\Hook_F.p3d";
	};
};

second

 

 

thirdly

 

  • put the dowloaded files in YOUR_rope/proxies/rope/
  • open rope.p3d
  • in LOD 0.000, copy selection (original) without any change.
  • paste it inside LOD 0.000 and change size (diameter only) and name it like you want e.g. YOURSELECTION.
  • select original rope model in LOD 0.000 and name it like you want e.g. ORIGINALSELECTION.

 

  • in shadowvolume 0.000, shadow volume 1000, and geometry, change size (diameter) of original selection.
  • let memory LOD, and save rope.p3d

 

  • model.cfg (in YOUR_rope/proxies/rope/)

 

class CfgSkeletons
{
    class Skeleton
    {
        isDiscrete=0;

        skeletonInherit="";

        skeletonBones[]={};

    };

};

class CfgModels
{
    class rope
    {
        htMin=0;

        htMax=0;

        afMax=0;

        mfMax=0;

        mFact=0;

        tBody=0;

        skeletonName="Skeleton";

        sectionsInherit="";

        sections[]={"YOURSELECTION","ORIGINALSELECTION"};

        class Animations{};
    
    };

};

save all files and use addon builder to make addon.

 

fourth

 

to select the aspect of the rope, simply use script (here I let you decide your creation)

for me it is :

 

ropeX = vehicle player nearObjects ["rope", 20];
ropesegmentX = vehicle player nearObjects ["ropesegment", 20];
{if (typeOf _x == "rope") then {_x setObjectTexture [0, "\scmod_fire\data\pipes.paa"]; _x setObjectTexture [1, ""];};} foreach ropeX;
{if (typeOf _x == "ropesegment") then {_x setObjectTexture [0, "\scmod_fire\data\pipes.paa"]; _x setObjectTexture [1, ""];};} foreach ropesegmentX;

Create the rope first and use this script whenever the length of the string changes.

This method allows to keep the original appearance of the rope, and to create, if necessary, a new appearance, to make pipes, etc.

 

Have fun ! :icon_cool:

Share this post


Link to post
Share on other sites

@CheyenneAH56 All you did was changing the vanilla model of the classes 'RopeSegment' & 'Rope' to the previous one but with hidden selection textures. Right or wrong? 

 

Of course you did some further little changes to allow the hidden selection textures to work.

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

×