Game Development Community

Wheeled vehicle and onLeaveMissionArea

by Very Interactive Person · in Torque Game Engine · 06/02/2004 (4:21 am) · 6 replies

Am I right when saying that a wheeled vehicle doesn't make an onLeaveMission area callback to the scripts? I tought this wouldn't be a problem, but none of the functions I tried are being called.

Here's what I did:

function GameConnection::onLeaveMissionArea(%this)
{
   echo("left mission area");
}

function GameConnection::onEnterMissionArea(%this)
{
   echo("entered mission area");
}

didn't work, so I tried this:

function WheeledVehicleData::onLeaveMissionArea(%this)
{
   echo("left mission area");
}

function WheeledVehicleData::onEnterMissionArea(%this)
{
   echo("entered mission area");
}

#1
06/02/2004 (4:22 am)
The first should work, but it doesn't, would there be an easy way to fix this?
#2
06/02/2004 (9:04 am)
Anyone? It should work right? I mean its checking if the control object of the gameconnection is leaving the mission area. It shouldn't matter if its a player or a vehicle object, right?
#3
06/02/2004 (10:22 am)
I tested both. But changed WheeledVehicleData to FlyingVehicleData ( my case ).

None worked.

I would be interested in knowing how to handle this too.

Bruno
#4
06/02/2004 (2:28 pm)
No I think it will only work for a player , but , if it did you would need %obj in like this.

function WheeledVehicleData::onLeaveMissionArea(%this, %obj)
{
echo("left mission area");
}
#5
06/05/2004 (11:00 am)
Hmm.. anyone who knows how this can be "fixed"?
#6
06/06/2004 (1:34 pm)
Ive never done it but I guess you would have to add C++ function to vehicle.cc that would be very similar to the void checkMissionArea in player.cc.