You see that topic? That's right. I really do think I've solved it. My tests show that I have.
Setup: 3 PCs. 1 as my own D2 server, and the other 2 as clients.
Time it took: Been trying all sorts of things since Tuesday..
Mission: Met_17PatrolEnemy (found to cause it)
I'm sure some of you spotted the "Luc's Test Server" lately. This is what it was for.. and guess what, I think I fixed it.
Now, pay attention..
Anywhere you have a ship creation like this...
-------------------------------------
mCreateShip(
typeid( tAttackTeamShip ),
shipScriptDescription.fClassName.c_str(),
kStartPosition_W,
shipScriptDescription.fMetaDatabaseID,
gWC.fNWCustID++, 0, 0, -1, -1,
shipScriptDescription.fCustomName.c_str(),
static_cast<eShipOptions>( option | kCanBeCarrier | kStartPositionCanBeOffset ) );
-------------------------------------
.. you gotta find the file that handles the typeid.. (in this case, AttackTeamShip.cpp).
In there, look for the
mSetupState function and change it to something more restrictive:
-------------------------------------
void tAttackTeamShip::mSetupState()
{
tTeamInfo* ti = fMissionInfo->mGetTeamHandle( mGetTeam() );
if (ti)
{
if (! ( (!ti->mIsTeamHumanControlled()) && (!gScriptInterface.mIsHost()) ) )
{ mRegisterState( new tAttackTeamShipInitialState( ) );
mGotoState( typeid( tAttackTeamShipInitialState ) );
}
}}
-------------------------------------
Prevent NON-hosts from setting up the TeamState IF it's also an AI. If it's a player, you need the TeamState for the nonhost.
Now, I'm gonna try to compile as many missions as possible, but can someone get NuclearWessels and Karnak to see this? Thanks.
-- Luc