MACK, Modern Soldier, Adam - which will work in T3D?
by ChrisG · in Torque 3D Professional · 10/05/2010 (7:03 am) · 17 replies
I have 3 character packs
- Tridinaut Soldier Pack
- Adam
- MACK Pack
I'd really like to use the MACK pack and Adam in T3D, but I've read that MACK won't work out of the box.
I've had a go with the MACK but haven't been able to get past the crucifix position, ie. the animations aren't working.
Should I persevere looking for script errors with the MACK pack?
Should the MACK pack work without having to edit the model or animations?
Will any of these packs work in T3D even with some script fiddling?
Are there any threads that explain how to get them working?
- Tridinaut Soldier Pack
- Adam
- MACK Pack
I'd really like to use the MACK pack and Adam in T3D, but I've read that MACK won't work out of the box.
I've had a go with the MACK but haven't been able to get past the crucifix position, ie. the animations aren't working.
Should I persevere looking for script errors with the MACK pack?
Should the MACK pack work without having to edit the model or animations?
Will any of these packs work in T3D even with some script fiddling?
Are there any threads that explain how to get them working?
About the author
Currently working on ZDay: www.zdaygame.com
#2
Just to let you know I've made some progress. I've manage to get the animations working, except that the player has his weapon by his side, not pointed in front of him.
10/05/2010 (9:51 am)
Thanks for the quick reply Andy. Just to let you know I've made some progress. I've manage to get the animations working, except that the player has his weapon by his side, not pointed in front of him.
#3
Glad you got the animations working. What you need to do for the weapon to point forward is to use one of the LOOK animations. These are arm blend animations and the stock engine wants one to be called "look". You could use lookMG or lookSMG that comes with the pack. Name it "look" in the shape editor (or just edit the .cs file).
This should make MACK hold his gun out in front of him. The t3D port of this pack is not done yet, but the art assets should all work (with some minor wrenching).
Jondo
10/05/2010 (3:46 pm)
Hi,Glad you got the animations working. What you need to do for the weapon to point forward is to use one of the LOOK animations. These are arm blend animations and the stock engine wants one to be called "look". You could use lookMG or lookSMG that comes with the pack. Name it "look" in the shape editor (or just edit the .cs file).
This should make MACK hold his gun out in front of him. The t3D port of this pack is not done yet, but the art assets should all work (with some minor wrenching).
Jondo
#4
After making sure that all the directory names in the MACK files are correct...
At the top of scripts/server/player.cs add
At the bottom of scripts/server/player.cs add
In shapes/actors/ACK/player.cs
change datablock to singleton (very important) ie
and change sequence4 to
I think that's it, hopefully I haven't forgotten anything.

10/09/2010 (12:30 am)
Managed to get it working. The following assumes that the MACK pack contents are in shapes/actors/ACK.After making sure that all the directory names in the MACK files are correct...
At the top of scripts/server/player.cs add
exec("art/shapes/actors/ACK/player.cs");
exec("art/shapes/actors/ACK/advancedmale.cs");
exec("art/shapes/actors/ACK/casualmale.cs");
exec("art/shapes/actors/ACK/medievalmale.cs");
exec("art/shapes/actors/ACK/militarymale.cs");
exec("art/shapes/actors/ACK/nudemale.cs");
exec("art/shapes/actors/ACK/postapocmale.cs");At the bottom of scripts/server/player.cs add
datablock PlayerData(AdvancedMaleBody : PlayerBody)
{
shapeFile = "art/shapes/actors/ACK/male/advanced.dts";
};
datablock PlayerData(CasualMaleBody : PlayerBody)
{
shapeFile = "art/shapes/actors/ACK/male/casual.dts";
};
datablock PlayerData(MedievalMaleBody : PlayerBody)
{
shapeFile = "art/shapes/actors/ACK/male/medieval.dts";
};
datablock PlayerData(MilitaryMaleBody : PlayerBody)
{
shapeFile = "art/shapes/actors/ACK/male/military.dts";
};
datablock PlayerData(NudeMaleBody : PlayerBody)
{
shapeFile = "art/shapes/actors/ACK/male/nude.dts";
};
datablock PlayerData(PostApocMaleBody : PlayerBody)
{
shapeFile = "art/shapes/actors/ACK/male/postapoc.dts";
};
//BAG Advanced Character Kit
function PlayerGetNaked(%obj)
{
%obj.meshoff("all");
%obj.meshon("base_head_one");
%obj.meshon("base_eyes_one");
%obj.meshon("base_mouth_one");
%obj.meshon("base_neck_one");
%obj.meshon("base_collar_one");
%obj.meshon("base_chest_one");
%obj.meshon("base_chest2_one");
%obj.meshon("base_abdomen_one");
%obj.meshon("base_abdomen2_one");
%obj.meshon("base_abdomen3_one");
%obj.meshon("base_hip_one");
%obj.meshon("base_hip2_one");
%obj.meshon("base_thighs_one");
%obj.meshon("base_knees_one");
%obj.meshon("base_shins_one");
%obj.meshon("base_shins2_one");
%obj.meshon("base_ankles_one");
%obj.meshon("base_soles_one");
%obj.meshon("base_heels_one");
%obj.meshon("base_feet_one");
%obj.meshon("base_toes_one");
%obj.meshon("base_shoulders_one");
%obj.meshon("base_biceps_one");
%obj.meshon("base_elbows_one");
%obj.meshon("base_forearms_one");
%obj.meshon("base_wrists_one");
%obj.meshon("base_hands_one");
%obj.meshon("base_fingers_one");
%obj.meshon("base_hip_one");
}
function SetBodySkin(%obj, %skin)
{
%obj.setSkinName(%skin @ ".body");
%obj.setSkinName(%skin @ ".eyes");
%obj.setSkinName(%skin @ ".head");
%obj.setSkinName(%skin @ ".mouth");
if(%obj.getDatablock().getname() $= "CasualMaleBody")
{
%obj.schedule(100, "setskinname", "jeans.uniformpants1");
}
}In shapes/actors/ACK/player.cs
change datablock to singleton (very important) ie
singleton TSShapeConstructor(PlayerDts)
and change sequence4 to
sequence4 = "./animations/player_lookMG.dsq look";
I think that's it, hopefully I haven't forgotten anything.

#5
change the player datablock
10/09/2010 (1:44 am)
oh, and also in scripts/server/player.cschange the player datablock
//BAG Advanced Character Kit
datablock PlayerData(PlayerBody)
{
renderFirstPerson = false;
emap = true;
className = Armor;
shapeFile = "art/shapes/actors/ACK/male/casual.dts";
cameraMaxDist = 3;
computeCRC = true;
canObserve = true;
cmdCategory = "Clients";
cameraDefaultFov = 90.0;
cameraMinFov = 5.0;
cameraMaxFov = 120.0;
debrisShapeName = "art/shapes/actors/common/debris_player.dts";
debris = playerDebris;
aiAvoidThis = true;
minLookAngle = -1.4;
maxLookAngle = 1.4;
maxFreelookAngle = 3.0;
mass = 90;
drag = 0.3;
maxdrag = 0.4;
density = 10;
maxDamage = 100;
maxEnergy = 60;
repairRate = 0.33;
energyPerDamagePoint = 75.0;
rechargeRate = 0.256;
runForce = 48 * 90;
runEnergyDrain = 0;
minRunEnergy = 0;
maxForwardSpeed = 14;
maxBackwardSpeed = 13;
maxSideSpeed = 13;
maxUnderwaterForwardSpeed = 8.4;
maxUnderwaterBackwardSpeed = 7.8;
maxUnderwaterSideSpeed = 7.8;
jumpForce = 8.3 * 90;
jumpEnergyDrain = 0;
minJumpEnergy = 0;
jumpDelay = 15;
recoverDelay = 9;
recoverRunForceScale = 1.2;
minImpactSpeed = 45;
speedDamageScale = 0.4;
boundingBox = "1.2 1.2 2.3";
pickupRadius = 0.75;
// Damage location details
boxNormalHeadPercentage = 0.83;
boxNormalTorsoPercentage = 0.49;
boxHeadLeftPercentage = 0;
boxHeadRightPercentage = 1;
boxHeadBackPercentage = 0;
boxHeadFrontPercentage = 1;
// Foot Prints
decalData = PlayerFootprint;
decalOffset = 0.25;
footPuffEmitter = LightPuffEmitter;
footPuffNumParts = 10;
footPuffRadius = 0.25;
dustEmitter = LiftoffDustEmitter;
splash = PlayerSplash;
splashVelocity = 4.0;
splashAngle = 67.0;
splashFreqMod = 300.0;
splashVelEpsilon = 0.60;
bubbleEmitTime = 0.4;
splashEmitter[0] = PlayerFoamDropletsEmitter;
splashEmitter[1] = PlayerFoamEmitter;
splashEmitter[2] = PlayerBubbleEmitter;
mediumSplashSoundVelocity = 10.0;
hardSplashSoundVelocity = 20.0;
exitSplashSoundVelocity = 5.0;
// Controls over slope of runnable/jumpable surfaces
runSurfaceAngle = 70;
jumpSurfaceAngle = 80;
minJumpSpeed = 20;
maxJumpSpeed = 30;
horizMaxSpeed = 68;
horizResistSpeed = 33;
horizResistFactor = 0.35;
upMaxSpeed = 80;
upResistSpeed = 25;
upResistFactor = 0.3;
footstepSplashHeight = 0.35;
//NOTE: some sounds commented out until wav's are available
// Footstep Sounds
FootSoftSound = FootLightSoftSound;
FootHardSound = FootLightHardSound;
FootMetalSound = FootLightMetalSound;
FootSnowSound = FootLightSnowSound;
FootShallowSound = FootLightShallowSplashSound;
FootWadingSound = FootLightWadingSound;
FootUnderwaterSound = FootLightUnderwaterSound;
//FootBubblesSound = FootLightBubblesSound;
//movingBubblesSound = ArmorMoveBubblesSound;
//waterBreathSound = WaterBreathMaleSound;
//impactSoftSound = ImpactLightSoftSound;
//impactHardSound = ImpactLightHardSound;
//impactMetalSound = ImpactLightMetalSound;
//impactSnowSound = ImpactLightSnowSound;
//impactWaterEasy = ImpactLightWaterEasySound;
//impactWaterMedium = ImpactLightWaterMediumSound;
//impactWaterHard = ImpactLightWaterHardSound;
groundImpactMinSpeed = 10.0;
groundImpactShakeFreq = "4.0 4.0 4.0";
groundImpactShakeAmp = "1.0 1.0 1.0";
groundImpactShakeDuration = 0.8;
groundImpactShakeFalloff = 10.0;
//exitingWater = ExitingWaterLightSound;
observeParameters = "0.5 4.5 4.5";
// Allowable Inventory Items
maxInv[BulletAmmo] = 20;
maxInv[HealthKit] = 1;
maxInv[RifleAmmo] = 100;
maxInv[CrossbowAmmo] = 50;
maxInv[Crossbow] = 1;
maxInv[Rifle] = 1;
maxInv[Sword] = 1;
};
#6
11/01/2010 (8:29 pm)
So if it's this easy? What's taking so long to get the new full release from BA games?
#7
So another solution needs to be developed. It could either be an entirely new way to swapping textures, a custom shader or say a new material feature to have the best control of how to work alongside other features. Each of these require some time to develop.
The problem is, most likely all of these also require a source change. Well, maybe the shader approach doesn't, but it would have to be much simpler than what it used to be in the TGEA version to keep it on the script only side. That probably wouldn't be good enough for the current licensees as it would not be compatible with the TGEA version.
So I guess BAG are still looking for the best answer, and I wouldn't be surprised if they would be waiting for a final 1.1 release to see where that goes with custom materials.
11/02/2010 (12:54 am)
Because custom materials - the way skin swapping was done for the MACK and FACK kits - is not anymore supported to a sufficient degree by the engine. It has the same functionality, but requires a different approach.So another solution needs to be developed. It could either be an entirely new way to swapping textures, a custom shader or say a new material feature to have the best control of how to work alongside other features. Each of these require some time to develop.
The problem is, most likely all of these also require a source change. Well, maybe the shader approach doesn't, but it would have to be much simpler than what it used to be in the TGEA version to keep it on the script only side. That probably wouldn't be good enough for the current licensees as it would not be compatible with the TGEA version.
So I guess BAG are still looking for the best answer, and I wouldn't be surprised if they would be waiting for a final 1.1 release to see where that goes with custom materials.
#8
A few things have caused the "official" port take longer than we wished. I can't give away too much yet, but we did a complete overhaul/modernization of the ACK system and I think it will blow your socks off!
We took nearly 2 years of user feedback, and looked at what requirements we felt were still missing from the system, and tried to reflect as much of that as possible in this update.
The new build is being cleaned up, still some work there... but it is looking/running SWEET!
A few of the highlights include:
Networked skin swapping
Enhanced animation systems
Numerous new clothing/armor meshes
More LODs
Just a bit longer now...
Thanks
Jondo
11/02/2010 (1:46 am)
Hi,A few things have caused the "official" port take longer than we wished. I can't give away too much yet, but we did a complete overhaul/modernization of the ACK system and I think it will blow your socks off!
We took nearly 2 years of user feedback, and looked at what requirements we felt were still missing from the system, and tried to reflect as much of that as possible in this update.
The new build is being cleaned up, still some work there... but it is looking/running SWEET!
A few of the highlights include:
Networked skin swapping
Enhanced animation systems
Numerous new clothing/armor meshes
More LODs
Just a bit longer now...
Thanks
Jondo
#9
11/03/2010 (4:34 pm)
Great to hear! Are we talking days, weeks, Christmas, shortly after the New Year? I'm definitely at a point where this would come in handy now. Having never owned it or worked with it in previous versions I'm anxious to see how it will fit in with what I have in mind.
#10
I have been wrong predicting this release for about a year now... With that in mind, before xmas is very likely.
Jondo
11/03/2010 (5:16 pm)
@ScotI have been wrong predicting this release for about a year now... With that in mind, before xmas is very likely.
Jondo
#11
11/13/2010 (9:06 pm)
So...now that Torque may be in dire straits and no longer supported or finished...what's the likelihood of ever getting a finished MACK/FACK?
#12
11/13/2010 (9:22 pm)
http://www.torquepowered.com/community/blogs/view/20517
#13
11/29/2010 (5:44 am)
shapes/actors/ACK/player.cs? I'm looking but can't find it :(
#14
Anyway the player.cs is basically a copy of one of the character .cs files from "MaleAdvancedCharacterKit\BAG_ACK_MALE\example\starter.fps\data\shapes\ACK"
eg: advancedmale.cs, casualmale.cs etc.
here's the code that I have:
11/29/2010 (6:04 am)
I've changed the player character that many times - he has been kork, modern soldier guy, adam and a mack pack character, so I'm not sure what's come from where anymore.Anyway the player.cs is basically a copy of one of the character .cs files from "MaleAdvancedCharacterKit\BAG_ACK_MALE\example\starter.fps\data\shapes\ACK"
eg: advancedmale.cs, casualmale.cs etc.
here's the code that I have:
//-----------------------------------------------------------------------------
// Torque Game Engine
// Copyright (C) GarageGames.com, Inc.
//-----------------------------------------------------------------------------
//datablock TSShapeConstructor(PlayerDts)
singleton TSShapeConstructor(PlayerDts)
{
baseShape = "./male/casual.dts";
sequence0 = "./animations/player_root.dsq root";
sequence1 = "./animations/player_run.dsq run";
sequence2 = "./animations/player_back.dsq back";
sequence3 = "./animations/player_side.dsq side";
//sequence4 = "./animations/player_lookde.dsq look";
sequence4 = "./animations/player_lookMG.dsq look";
sequence5 = "./animations/player_head.dsq head";
sequence6 = "./animations/player_fall.dsq fall";
sequence7 = "./animations/player_land.dsq land";
sequence8 = "./animations/player_jump.dsq jump";
sequence9 = "./animations/player_diehead.dsq death1";
sequence10 = "./animations/player_diechest.dsq death2";
sequence11 = "./animations/player_dieback.dsq death3";
sequence12 = "./animations/player_diesidelf.dsq death4";
sequence13 = "./animations/player_diesidert.dsq death5";
sequence14 = "./animations/player_dieleglf.dsq death6";
sequence15 = "./animations/player_dielegrt.dsq death7";
sequence16 = "./animations/player_dieslump.dsq death8";
sequence17 = "./animations/player_dieknees.dsq death9";
sequence18 = "./animations/player_dieforward.dsq death10";
sequence19 = "./animations/player_diespin.dsq death11";
sequence20 = "./animations/player_looksn.dsq looksn";
sequence21 = "./animations/player_lookms.dsq lookms";
sequence22 = "./animations/player_scoutroot.dsq scoutroot";
sequence23 = "./animations/player_headside.dsq headside";
sequence24 = "./animations/player_recoilde.dsq light_recoil";
sequence25 = "./animations/player_sitting.dsq sitting";
sequence26 = "./animations/player_celsalute.dsq celsalute";
sequence27 = "./animations/player_celwave.dsq celwave";
sequence28 = "./animations/player_standjump.dsq standjump";
sequence29 = "./animations/player_looknw.dsq looknw";
};
#15
void ShapeBase::getMeshVisibility()
{
if ( !mShapeInstance )
return;
const Vector<TSShapeInstance::MeshObjectInstance> &meshes = mShapeInstance->mMeshObjects;
for ( U32 i = 0; i < meshes.size(); i++)
{
const TSShapeInstance::MeshObjectInstance &mesh = meshes[i];
const String &meshName = mDataBlock->mShape->getMeshName( i );
char scriptCommand[2048];
//dSprintf(scriptCommand, sizeof(scriptCommand), "%s.meshlist.%s = %s;%s.meshlist.numMeshes = %d;",scriptThis(),meshName.c_str(),mesh.forceHidden ? "true" : "false",scriptThis(),i + 1);
dSprintf(scriptCommand, sizeof(scriptCommand), "%s.meshlist.%s = %s;%s.meshlist.numMeshes = %d;%s.meshlist.mesh[%d] = %s;",scriptThis(),meshName.c_str(),mesh.forceHidden ? "true" : "false",scriptThis(),i + 1,scriptThis(), i, meshName.c_str());
//dSprintf(scriptCommand, sizeof(scriptCommand), "%s.meshlist.mesh[%d] = %s;",scriptThis(), i, meshName.c_str());
Con::evaluate(scriptCommand);
//Con::printf(scriptCommand);
}
}
ConsoleMethod( ShapeBase, getMeshVisibility, void, 2, 2, "makes a script array of hidden meshes." )
{
object->getMeshVisibility();
}
That's all fine and good, but what is this "scriptThis()" reference? Can't find the string scriptThis at all in MACK except for when it is attempting to call it.
04/07/2013 (4:13 pm)
there is either some unmarked MACK modifications, or this has otherwise been deprecated in 2.0.void ShapeBase::getMeshVisibility()
{
if ( !mShapeInstance )
return;
const Vector<TSShapeInstance::MeshObjectInstance> &meshes = mShapeInstance->mMeshObjects;
for ( U32 i = 0; i < meshes.size(); i++)
{
const TSShapeInstance::MeshObjectInstance &mesh = meshes[i];
const String &meshName = mDataBlock->mShape->getMeshName( i );
char scriptCommand[2048];
//dSprintf(scriptCommand, sizeof(scriptCommand), "%s.meshlist.%s = %s;%s.meshlist.numMeshes = %d;",scriptThis(),meshName.c_str(),mesh.forceHidden ? "true" : "false",scriptThis(),i + 1);
dSprintf(scriptCommand, sizeof(scriptCommand), "%s.meshlist.%s = %s;%s.meshlist.numMeshes = %d;%s.meshlist.mesh[%d] = %s;",scriptThis(),meshName.c_str(),mesh.forceHidden ? "true" : "false",scriptThis(),i + 1,scriptThis(), i, meshName.c_str());
//dSprintf(scriptCommand, sizeof(scriptCommand), "%s.meshlist.mesh[%d] = %s;",scriptThis(), i, meshName.c_str());
Con::evaluate(scriptCommand);
//Con::printf(scriptCommand);
}
}
ConsoleMethod( ShapeBase, getMeshVisibility, void, 2, 2, "makes a script array of hidden meshes." )
{
object->getMeshVisibility();
}
That's all fine and good, but what is this "scriptThis()" reference? Can't find the string scriptThis at all in MACK except for when it is attempting to call it.
#16
05/10/2013 (11:31 pm)
I'm pretty sure scriptThis() was the old equivalent of the getId() function. Basically just getting the object's script SimObjID (4738, etc). I vaguely remember that causing a bit of hassle when it was originally changed.
#17
05/31/2013 (1:38 am)
hello chric am new to the forum can you please tell me what is going on
Torque 3D Owner Andy Wright
BrokeAss Games
I'll get this thread over to Jondo, but there should be a MACK release for T3D some point soon. Im not sure when, as its not something I work on, but I know that its being done.
Andy.