Thanks very much for your reply and example, i got it to work and it works exactly as you say.
the action menu is the best option, i think when i first tried out the codes and scripts thats probably what i was looking for some radio addition. its perfect.
what i want to do is figure out how to change the class name for the type of crew, as the WW2 mod we have is custom made, all the tanks we have, have custom WW2 crew, we have German and Russian crew but we only play the axis side.
I found the addon that has the crew.
I extracted it and it has a config, can you look at this config and tell me which class i am supposed to use.
I'm assuming this is the class i want:
class rw_crew
{
displayName = "Axis Panzercrew";
};
here is the whole config for the crew addon:
#include "BasicDefines.hpp"
class CfgPatches {
class rw_crew {
units[] = {"rw_crew"};
};
};
class CfgVehicleClasses
{
class rw_crew
{
displayName = "Axis Panzercrew";
};
class rw_crewr
{
displayName = "russian tankcrew";
};
};
class CfgSkeletons
{
class Head
{
isDiscrete = 0;
skeletonInherit = "";
skeletonBones[] =
{
"neck","",
"neck1","neck",
"head","neck1",
"loboci","head",
"soboci","head",
"poboci","head",
"lkoutek","head",
"skoutek","head",
"pkoutek","head",
"vicka","head",
"spodni ret","head"
};
};
class OFP2_ManSkeleton
{
isDiscrete = 0;
skeletonInherit = "Head";
skeletonBones[] =
{
"Weapon","",
"launcher","",
"Camera","",
"Spine","",
"Spine1","",
"Spine2","",
"Spine3","",
"Pelvis","",
//Left upper side
"LeftShoulder","",
"LeftArm","",
"LeftArmRoll","",
"LeftForeArm","",
"LeftForeArmRoll","",
"LeftHand","",
"LeftHandRing","",
"LeftHandRing1","",
"LeftHandRing2","",
"LeftHandRing3","",
"LeftHandPinky1","",
"LeftHandPinky2","",
"LeftHandPinky3","",
"LeftHandMiddle1","",
"LeftHandMiddle2","",
"LeftHandMiddle3","",
"LeftHandIndex1","",
"LeftHandIndex2","",
"LeftHandIndex3","",
"LeftHandThumb1","",
"LeftHandThumb2","",
"LeftHandThumb3","",
//Right upper side
"RightShoulder","",
"RightArm","",
"RightArmRoll","",
"RightForeArm","",
"RightForeArmRoll","",
"RightHand","",
"RightHandRing","",
"RightHandRing1","",
"RightHandRing2","",
"RightHandRing3","",
"RightHandPinky1","",
"RightHandPinky2","",
"RightHandPinky3","",
"RightHandMiddle1","",
"RightHandMiddle2","",
"RightHandMiddle3","",
"RightHandIndex1","",
"RightHandIndex2","",
"RightHandIndex3","",
"RightHandThumb1","",
"RightHandThumb2","",
"RightHandThumb3","",
//Left lower side
"LeftUpLeg","",
"LeftUpLegRoll","",
"LeftLeg","",
"LeftLegRoll","",
"LeftFoot","",
"LeftToeBase","",
//Right lower side
"RightUpLeg","",
"RightUpLegRoll","",
"RightLeg","",
"RightLegRoll","",
"RightFoot","",
"RightToeBase",""
};
};
class default;
class Flag: Default {};
class FlagCarrier: Default
{
skeletonInherit = "Default";
skeletonBones[] =
{
"stozar","",
"vlajka",""
};
};
};
class CfgModels
{
class Default
{
sections[] = {};
sectionsInherit="";
};
class flag_vojak : Default
{
sections[] = {"latka"};
};
class Head: Default
{
sections[] =
{
"osobnost","brejle"
};
skeletonName = "Head";
};
class ArmaMan : Default
{
sections[] =
{
"osobnost","Head_Injury","Body_Injury","l_leg_injury","l_arm_injury","r_arm_injury","r_leg_injury","clan"};
skeletonName = "OFP2_ManSkeleton";
};
class heer1 : ArmaMan
{
sectionsInherit = "ArmaMan";
sections[] =
{};
};
class heer2 : ArmaMan
{
sectionsInherit = "ArmaMan";
sections[] =
{};
};
class heeroff : ArmaMan
{
sectionsInherit = "ArmaMan";
sections[] =
{};
};
class ss1 : ArmaMan
{
sectionsInherit = "ArmaMan";
sections[] =
{};
};
class ss2 : ArmaMan
{
sectionsInherit = "ArmaMan";
sections[] =
{};
};
class ssoff : ArmaMan
{
sectionsInherit = "ArmaMan";
sections[] =
{};
};
class sovcrew : ArmaMan
{
sectionsInherit = "ArmaMan";
sections[] =
{};
};
};
class CfgVehicles {
/*extern*/ class Man;
class CAManBase: Man {
/*extern*/ class TalkTopics;
class HitPoints {
/*extern*/ class HitHead;
/*extern*/ class HitBody;
};
};
class SoldierEB: CAManBase {
class TalkTopics: TalkTopics {
};
};
class SoldierWB: CAManBase {
class TalkTopics: TalkTopics {
};
};
class SoldierGB: CAManBase {
class TalkTopics: TalkTopics {
};
};
/*extern*/ class NonStrategic;
class rw_gcrew1 : SoldierWB
{
vehicleClass = "rw_crew";
side = "1";
faceType = "Man";
genericNames = "EnglishMen";
portrait = "\Ca\characters\data\portraits\comBarHead_usmc_soldier_ca";
picture = "\Ca\characters\data\Ico\i_null_CA.paa";
icon = "\Ca\characters2\data\icon\i_soldier_CA.paa";
cost = 80000;
camouflage = 1.800000;
accuracy = 2.000000;
displayName = "Heer Crew (fieldcap)";
model = "\rwcrew\heer1.p3d";
scope = public;
weapons[] = {"rw_mp401","rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
magazines[] = {"rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
respawnWeapons[] = {"rw_mp401","rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
respawnMagazines[] = {"rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
hiddenSelections[] = {};
class HitPoints: HitPoints {
class HitHead: HitHead {
armor = 0.850000;
};
class HitBody: HitBody {
armor = 1;
passThrough = 0.800000;
};
};
class Wounds {
tex[] = {};
mat[] = {"rwcrew\data\heer_body.rvmat", "rwcrew\data\soldier_captive_body_wound1.rvmat", "rwcrew\data\soldier_captive_body_wound2.rvmat", "rwcrew\data\soldier_captive_hhl.rvmat",
"rwcrew\data\soldier_captive_hhl_wound1.rvmat", "rwcrew\data\soldier_captive_hhl_wound2.rvmat","rwcrew\data\us_rukavy_hhl.rvmat","rwcrew\data\us_rukavy_hhl_wound1.rvmat", "rwcrew\data\us_rukavy_hhl_wound2.rvmat",
"rwcrew\data\emp_body.rvmat", "rwcrew\data\soldier_captive_body_wound1.rvmat", "rwcrew\data\soldier_captive_body_wound2.rvmat",};
};
class TalkTopics: TalkTopics
{
core_en = "Core_Full";
};
languages[] = {"EN"};
};
class rw_gcrew2: rw_gcrew1
{
accuracy = 3.900000;
displayName = "Heer Crew (cap)";
model = "\rwcrew\heer2.p3d";
weapons[] = {"rw_mp401","rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
magazines[] = {"rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
respawnWeapons[] = {"rw_mp401","rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
respawnMagazines[] = {"rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
hiddenSelections[] = {};
};
class rw_gcrew3: rw_gcrew1
{
accuracy = 3.900000;
displayName = "Heer Crew Officer";
model = "\rwcrew\heeroff.p3d";
weapons[] = {"rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch", "Binocular"};
magazines[] = {"rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
respawnWeapons[] = {"rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
respawnMagazines[] = {"rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
hiddenSelections[] = {};
};
class rw_gcrew4: rw_gcrew1
{
accuracy = 3.900000;
displayName = "SS Crew (fieldcap)";
model = "\rwcrew\ss2.p3d";
weapons[] = {"rw_mp401","rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
magazines[] = {"rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
respawnWeapons[] = {"rw_mp401","rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
respawnMagazines[] = {"rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
hiddenSelections[] = {};
};
class rw_gcrew5: rw_gcrew1
{
accuracy = 3.900000;
displayName = "SS Crew (cap)";
model = "\rwcrew\ss2.p3d";
weapons[] = {"rw_mp401","rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
magazines[] = {"rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
respawnWeapons[] = {"rw_mp401","rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
respawnMagazines[] = {"rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_32Rnd_mp","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
hiddenSelections[] = {};
};
class rw_gcrew6: rw_gcrew1
{
accuracy = 3.900000;
displayName = "SS Crew Officer";
model = "\rwcrew\ssoff.p3d";
weapons[] = {"rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch", "Binocular"};
magazines[] = {"rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
respawnWeapons[] = {"rw_p38","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
respawnMagazines[] = {"rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_8Rnd_p38","rw_HandGnaz","rw_HandGnaz"};
hiddenSelections[] = {};
};
class rw_sovcrew1 : SoldierEB
{
vehicleClass = "rw_crewr";
scope = 2;
side = "0";
faceType = "Man";
genericNames = "RussianMen";
identityTypes[] = {"Head_RU", "RU_Glasses"};
portrait = "\Ca\characters\data\portraits\comBarHead_ru_soldier_ca";
picture = "\Ca\characters\data\Ico\i_null_CA.paa";
icon = "\Ca\characters2\data\icon\i_soldier_CA.paa";
cost = 80000;
camouflage = 1.800000;
accuracy = 2.000000;
displayName = "Tank Crew";
model = "\rwcrew\sovcrew.p3d";
weapons[] = {"rw_PPS43","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch", "Binocular"};
magazines[] = {"rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_HandGF1","rw_HandGF1"};
respawnWeapons[] = {"rw_PPS43","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
respawnMagazines[] = {"rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_HandGF1","rw_HandGF1"};
hiddenSelections[] = {};
class HitPoints: HitPoints {
class HitHead: HitHead {
armor = 0.850000;
};
class HitBody: HitBody {
armor = 1;
passThrough = 0.800000;
};
};
class Wounds {
tex[] = {};
mat[] = {"rwcrew\data\redarmy_body.rvmat", "rwcrew\data\soldier_captive_body_wound1.rvmat", "rwcrew\data\soldier_captive_body_wound2.rvmat", "rwcrew\data\soldier_captive_hhl.rvmat","rwcrew\data\soldier_captive_hhl_wound1.rvmat", "rwcrew\data\soldier_captive_hhl_wound2.rvmat",
"rwcrew\data\us_rukavy_hhl.rvmat","rwcrew\data\us_rukavy_hhl_wound1.rvmat", "rwcrew\data\us_rukavy_hhl_wound2.rvmat"};
};
class TalkTopics: TalkTopics
{
core_ru = "Core_Full";
};
core_ru = "Core_Full";
};
class rw_sovcrew2: rw_sovcrew1
{
accuracy = 3.900000;
displayName = "Tank Crew1";
model = "\rwcrew\sovcrew.p3d";
weapons[] = {"rw_PPS43","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
magazines[] = {"rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_HandGF1","rw_HandGF1"};
respawnWeapons[] = {"rw_PPS43","rw_Throw","Throw", "Put", "ItemMap", "ItemCompass", "ItemWatch"};
respawnMagazines[] = {"rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_35Rnd_mp","rw_HandGF1","rw_HandGF1"};
hiddenSelections[] = {};
};
};
Once we figure out the class for the axis crew, how do you integrate it into the SQF, and then
what would the new code look like after the class i want is in the code that i put into the tank's init line?
==========================================================================
Edit:
Wait a minute on what i said above about the class.
I just did a test, i went into the editor, loaded up the latest mission with the request additonal crew in the action menu.
i put down a tiger tank which has 5 positions
commander,driver, gunner, radio operator, and loader.
i got into the tank as a normal modern day crewman and requested crew, i pop out of the cupola and look to my right which is where the depot is where the crew will spawn, and i see the axis crew spawn. so somehowthe code that we put into the tank's initalization line it works in conjunction with the addon that being the tiger tank. thats odd but it works.
so by default when i request a crew i get 3 crewman for ever request, so in the code to put into the tank i just change
"fillcrew.sqf", 4, <---that number 4 to a 5 to get 4 crew correct?
========================================================
Edit:
ok i changed the 4 to a 5 and i respawned 5 crew this time.
the great thing about this script and code is it isn't limited to just MP, it works in SP as well, and not only for just WW2 , but works with any tank!
heres some pic of my crewed tank:
i get in the tank and the request crew action shows up only if my tank is not fully crewed
http://img407.imageshack.us/img407/2760/gd004.jpgheres the tank crewed after i requested it, they respawn at the depot
and you just tell them to mount
http://img142.imageshack.us/img142/3170/gd005.jpgtank fully crewed
http://img689.imageshack.us/img689/7259/gd003.jpgtank fully crewed 2
http://img407.imageshack.us/img407/2231/gd002.jpgHere is a vid i just put together to demostrate this great script
http://www.youtube.com/watch?v=L6fq2dgbKksThank you to TCP for all his help and effort for makign the script, and testing it, very much appreciate it!
Gunter