Jump to content

timmiej93

Members
  • Posts

    207
  • Joined

  • Last visited

Posts posted by timmiej93

  1. Hey guys,

     

    Sorry for the vague title, but it was the best I could come up with.

    What I'm trying to achieve is having a rollback towtruck backup to a dedicated space, and then unload the loaded vehicle, which then should be placed inside a VO.

    Now I've thought of two methods of achieving this:

     

    1. Unloading directly onto the specific VO from the rollback by editing the unload script.

    I've tried to achieve this by copying parts from the unload script into the script that is doing all the backing up and such, but that didn't work at all.

     

    2. Unloading like normal (which will drop the car in the VO at least partially), then move (or remove/spawn) the car to the center of the VO.

    This probably is the easiest, but I couldn't get that to work either.

    Unfortunately, I so far haven't been able to get either method to work. 

    Could anyone help me with this?

  2. Hey guys,
     
    THVFD and myself are working on a Tech Station to add to freeplay maps. This station will have functions that are similar to the LA Mod Fire Station.

     

    The only problem we are having now is the gates and their animations. We tried using the default Fire Station gates (from the LA Mod), but those are too narrow. So we stretched them to fit our needs, but (of course?) that disabled the animations, and neither of us has any knowledge about animations. 

    We would love some help on this, even if it's just a pointer in the right direction, a tutorial or anything. But since we're both total nitwits regarding animating, it would be a great help if someone could animate the gate for us, or widen the original FS gate while keeping the original animation.

     

    Any tips or help is welcome.

     

    Tim

  3. Well, I believe there are separate models for the walls, floor and roof, but I'm not sure, because I haven't been able to open those files, since I don't have a program for it. I don't even know what program would be able to open those files, that's the biggest problem.

    Oh I just saw Mikey's post. I've tried zmodeler2, but that said the free program wasn't able to import 3vo files because it was the free version

  4. I think this topic definitely has potential, and all are great ideas.

     

    For this one: 

    -During a traffic stop, the officer should have to call in the name to see if the guy is clean

     

    I might be able to help, but not for a week or so, and I think other people here could do a way better job then I can

    • Upvote 1
  5. Alright, to finish this topic of once and for all: It's working, thanks to the great support of everyone on this forum!

     

    The functionality's are as follows:

    - 4 extra parking spaces behind the police station, set parking spots for a LAPD SUV, LASD van and 2 CHP chargers. These all spawn on startup, including personnel, just like the firestation.

    - The 2 parking spaces at the donut store are now set for 2 LAPD crown vics. These also all spawn on startup, including personnel.

    - The 3 front parking spaces are just for dropping off criminals.

     

    So lets call the SUV, van, CHP chargers and LAPD crown vics the "special" cars, all other police vehicles are defaults. When a special car gets the ToPS command it directly goes to it's own set parking space. When one of those special cars has a transport inside, a criminal, it will go to one of the available parking spaces in front of the police station. When no parking space is available, the vehicle will start a patrol and will try going to the police station a minute later again.

    When there is a free spot, the special vehicle will park there, drop off the criminals, wait about 6 seconds and will then drive to it's own personal set parking space.

     

    When a default vehicle gets sent to the station, it will always drive to one of the front 3 parking spaces. This vehicle will also start a patrol and try again when no space is available. When the default vehicle has a criminal in it, it will drop off the criminal and start a patrol after 6 seconds. When it doesn't have transports, it just drives to the police station and starts a patrol 6 seconds later. (I know this is a bit strange, not starting a patrol immediately, but just imagine they have to fill out some paperwork and get some coffee before they hit the road again.

     

    Things I'm still thinking about implementing

    I might make some vehicles start a patrol automatically on startup, so I wouldn't have to start those mysef, but that's for later on.

     

    If enough people are interested in such a police station, I might make a tutorial how to do it yourself. But be warned, it's a lot of work, and it isn't easy.

    Just let me know what you think!

  6. Hey guys,

     

    So I'm trying to add a tech station to my map with some flatbeds and an engineers van etc.

    The scripting in this no problem, I've got that covered myself. The actual problem lies with the model.

    Now I've found a nice garage that is already included in the mod, and which is an open house, so it's accessible. Now there are a few things I could use some advice / help on:

     

    Making the roof visibility toggle-able.

    I know this should be possible, because the roof gets toggled when a person enters or leaves the building too, I just haven't figured out how yet, but I'm afraid that's hardcoded into the game, so I'd have to figure out something else.

     

    Making the gates open. 

    Now this one is a bit trickier. The building has gates, but they're just a solid part of the walls. The best option to get minimal work gates into them would be changing the color of the FS gates, and placing those into the wall, which would have to be cut out.

     

    Now like I said, the scripting is no problem, I'll get through that, but the modeling is almost impossible for me, especially since the mod files don't include a 3D model, but just a prototype (or something) as far as I know. 

     

    So any tips or advice would be a great help :).

     

    Tim

     

    PS. For those interested: The building I'm referring to is the Tirewarehouse 01 (M02) from the LAmod.

  7. Hello Chris,

    Sorry to bother you again, but I'm running into trouble.

     

    I've got a script set up like seen below, but for some reason the game just ignores me when I call the command from the VAN, and it just goes to ChildID 1, straight below this piece of code, instead of ChildID2. Any idea how this can be?

    Or is it just my misunderstanding?

    if (StrCompare(v.GetPrototypeFileName(), OBJ_VAN) == 0 || StrCompare(v.GetPrototypeFileName(), OBJ_SUV == 0) || StrCompare(v.GetPrototypeFileName(), OBJ_CRUISER04) == 0 || StrCompare(v.GetPrototypeFileName(), OBJ_CRUISER01) == 0){		v.PushActionExecuteCommand(ACTION_APPEND, CMD_TOPOLICESTATION, Caller, 2, false);	Mission::PlayHint("1");	return;}else if (v.GetVehicleType() == VT_POLICE_PHC){	v.PushActionExecuteCommand(ACTION_APPEND, CMD_TOPOLICESTATION, Caller, 3, false);	return;}else{	v.PushActionExecuteCommand(ACTION_APPEND, CMD_TOPOLICESTATION, Caller, 1, false);}

    I'm assuming that after a PushAction to ChildID2, the script continues from there right?

    So below script (simplified ofcourse) should give everybody treats and just skip blowing up the vehicle right?

    v.PushActionExecuteCommand(ACTION_APPEND, CMD_TOPOLICESTATION, Caller, 1, false);if(ChildID==0);{    Blow up vehicle}if(ChildID==1);{    Give everybody treats};
  8. Aha. After correcting everything, the cruiser no longer gives an error, but gives the same result as the VAN and SUV, saying L1 == 0, L2 is good.

     

    Edit: Something I just noticed, when I get the L1==0 and L2 is good, the vehicles don't move, but the biggest thing: The bluelights stay on. This must have a hint in it somewhere, but I can't figure out how.

     

    Edit2: Never mind that dumb notice, that's just a scripting error on my behalf  :laugh:

     

    Another thing I found:

    The to policestation script has a command to set Priority to 110 when transporting criminals, and set it to 0 when not. This should't have anything to do with it, but it raised my suspicion. 

     

     

     

    ------------------

     

    Allright, so I've made some changes to the script to test some things, like changing l1 and l2 to l11 and l12, since l1 was already in use.

     

    Here's the new version: Click, or below.

     

    //******************************************************************************************
    // #Version 1.5#
    //
    // Includes: To police station command.
    //
    // - VcmdToPoliceStation
    //
    // Script by Hoppah
    //
    // Usage of this script in other mods is NOT allowed without permission of Hoppah
    //
    //******************************************************************************************

    const char CMD_SIREN[] = "VcmdSiren";
    const char CMD_AUTOSIREN_OFF[] = "VcmdAutoSirenOff";
    const char CMD_WARNINGLIGHTS_OFF[] = "VcmdWarningLightsOff";
    const char CMD_WARNINGLIGHTS_ON[] = "VcmdWarningLightsOn";
    const char CMD_FLOODLIGHTS_OFF[] = "VcmdFloodLightsOff";
    const char CMD_FLOODLIGHTS_ON[] = "VcmdFloodLightsOn";
    const char CMD_GOHOME[] = "GoHome";
    const char CMD_TOPOLICESTATION[] = "VcmdToPoliceStation";
    const char CMD_PATROL[] = "VcmdPatrol";
    const char CMD_STANDBY_ON[] = "VcmdStandbyOn";
    const char CMD_STANDBY_OFF[] = "VcmdStandbyOff";

    const char OBJ_VAN[] = "mod:Prototypes/Vehicles/03 LA Police/lasd_van.e4p";
    const char OBJ_SUV[] = "mod:Prototypes/Vehicles/03 LA Police/suv_lapd.e4p";
    const char OBJ_CRUISER01[] = "mod:Prototypes/Vehicles/03 LA Police/cv_lapd.e4p";
    const char OBJ_CRUISER04[] = "mod:Prototypes/Vehicles/03 LA Police/dodge_charger_chp.e4p";

    const char DUMMY_DISABLE[] = "DummyDisableSiren";
    const char DUMMY_HASSIREN[] = "DummyHasSiren";
    const char DUMMY_GOHOME[] = "DummyGoHome";
    const char DUMMY_PATROL[] = "DummyPatrol";

    const char OBJ_HELIPAD[] = "policestation_helipad";

    const char VO_ENTRY[] = "policestation_entry";
    const char VO_ENTRY_HELIPAD[] = "policestation_entry2";
    const char VO_TURNTO[] = "policestation_turnto";
    const char VO_FRONT01[] = "policestation_park01";
    const char VO_FRONT02[] = "policestation_park02";
    const char VO_FRONT03[] = "policestation_park03";
    const char VO_BACK01[] = "policestation_park04";
    const char VO_BACK02[] = "policestation_park05";
    const char VO_BACK03[] = "policestation_park06";
    const char VO_BACK04[] = "policestation_park07";
    const char VO_DONUT01[] = "policestation_donut01";
    const char VO_DONUT02[] = "policestation_donut02";
    const char VO_HELI[] = "policestation_heli";
    const char VO_SPAWN[] = "policestation_spawn";

    const char VO_SPAWN_FRONT[] = "policestation_spawn";
    const char VO_SPAWN_BACK[] = "spawn_police1";
    const char VO_SPAWN_DONUT[] = "policestation_spawn2";

    const char VO_MOVETO_FRONT[] = "policestation_moveto1";
    const char VO_MOVETO_BACK[] = "spawn_police1r";
    const char VO_MOVETO_DONUT[] = "policestation_moveto2";

    const char VO_SQUAD01[] = "police_squad01";
    const char VO_SQUAD02[] = "police_squad02";
    const char VO_SQUAD03[] = "police_squad03";

    const char VO_BACK01TT[] = "policestation_back04tt";
    const char VO_BACK02TT[] = "policestation_back05tt";
    const char VO_BACK03TT[] = "policestation_back06tt";
    const char VO_BACK04TT[] = "policestation_back07tt";
    const char VO_DONUT01TT[] = "policestation_donut01tt";
    const char VO_DONUT02TT[] = "policestation_donut02tt";

    const char SND_TOSTATION[] = "mod:Audio/FX/radio/1019.wav";

    const char HINT_HELICOPTER[] = "Another helicopter is blocking the helipad! The helicopter will return to base!";
    const char HINT_NOTVALID[] = "This vehicle doesn't belong in the police station!";
    const char HINT_NOSPACE[] = "No space at the police station, vehicle starts a patrol.";

    const char PROTO_CV_LAPD[] = "mod:Prototypes/Vehicles/03 LA Police/cv_lapd.e4p";

    int DummyGroup = 32;

    object VcmdToPoliceStation : CommandScript
    {
    VcmdToPoliceStation()
    {
    SetCursor("topolicestation");
    SetIcon("topolicestation");
    SetGroupID(DummyGroup);
    SetGroupLeader(true);
    SetRestrictions(RESTRICT_SELFEXECUTE);
    }

    bool CheckPossible(GameObject *Caller)
    {
    if (!Caller->IsValid())
    return false;

    if (!Game::IsFreeplay() && !Game::IsMultiplayer())
    return false;

    Vehicle v(Caller);
    if (v.IsCollidingWithVirtualObject(VO_HELI) || v.IsCollidingWithVirtualObject(VO_BACK01) || v.IsCollidingWithVirtualObject(VO_BACK02) || v.IsCollidingWithVirtualObject(VO_BACK03) || v.IsCollidingWithVirtualObject(VO_BACK04))
    return false;

    ActorList l1 = Game::GetActors(VO_FRONT01);
    if (l1.GetNumActors() == 0)
    return false;

    return true;
    }

    bool CheckTarget(GameObject *Caller, Actor *Target, int childID)
    {
    if (!Caller->IsValid() || !Target->IsValid() || (Caller->GetID() != Target->GetID()))
    return false;

    Vehicle v(Caller);
    SetPriority(0);
    if (v.GetNumTransported() > 0)
    SetPriority(110);

    return true;
    }

    void PushActions(GameObject *Caller, Actor *Target, int ChildID)
    {
    Vehicle v(Caller);
    if(ChildID == 0)
    {
    if (v.IsBlueLightEnabled())
    v.EnableBlueLights(false);
    if (v.HasCommand("DummyFollow"))
    v.RemoveCommand("DummyFollow");
    if (v.HasCommand(CMD_STANDBY_OFF))
    {
    v.RemoveCommand(CMD_STANDBY_OFF);
    v.AssignCommand(CMD_STANDBY_ON);
    }
    if (v.HasCommand(CMD_WARNINGLIGHTS_OFF))
    {
    v.EnableBlinker(BLT_NONE);
    v.RemoveCommand(CMD_WARNINGLIGHTS_OFF);
    v.AssignCommand(CMD_WARNINGLIGHTS_ON);
    }
    if (v.HasCommand(CMD_FLOODLIGHTS_OFF))
    {
    v.EnableSpecialLights(false);
    v.RemoveCommand(CMD_FLOODLIGHTS_OFF);
    v.AssignCommand(CMD_FLOODLIGHTS_ON);
    }
    if (v.HasObjectPath(NULL))
    Game::ExecuteCommand(DUMMY_PATROL, &v, &v);
    if (v.HasCommand(DUMMY_HASSIREN) && v.HasCommand(CMD_AUTOSIREN_OFF))
    Game::ExecuteCommand(DUMMY_DISABLE, &v, &v);

    if (v.GetVehicleType() != VT_POLICE_PHC && v.GetPrototypeFileName() != OBJ_VAN && v.GetPrototypeFileName() != OBJ_SUV && v.GetPrototypeFileName() != OBJ_CRUISER04 && v.GetPrototypeFileName() != OBJ_CRUISER01)
    {

    bool ParkinglotFound = false;
    ActorList l1;
    if (!ParkinglotFound)
    {
    GameObjectList l2;
    Game::CollectObstaclesOnVirtualObject(VO_FRONT01, l2, ACTOR_VEHICLE);
    if(l2.GetNumObjects() == 0)
    {
    l1 = Game::GetActors(VO_FRONT01);
    ParkinglotFound = true;
    }
    }
    if (!ParkinglotFound)
    {
    GameObjectList l3;
    Game::CollectObstaclesOnVirtualObject(VO_FRONT02, l3, ACTOR_VEHICLE);
    if(l3.GetNumObjects() == 0)
    {
    l1 = Game::GetActors(VO_FRONT02);
    ParkinglotFound = true;
    }
    }
    if (!ParkinglotFound)
    {
    GameObjectList l4;
    Game::CollectObstaclesOnVirtualObject(VO_FRONT03, l4, ACTOR_VEHICLE);
    if(l4.GetNumObjects() == 0)
    {
    l1 = Game::GetActors(VO_FRONT03);
    ParkinglotFound = true;
    }
    }
    if (!ParkinglotFound)
    {
    v.PushActionExecuteCommand(ACTION_NEWLIST, CMD_PATROL, Caller, 0, false);
    return;
    }
    else
    {
    Vector PD = l1.GetActor(0)->GetPosition();
    Vector PD2 = l1.GetActor(0)->GetPosition() + Vector(280,-280,0);

    ActorList l8 = Game::GetActors(VO_TURNTO);
    Vector TurnTo = l8.GetActor(0)->GetPosition();

    Game::FindFreePosition(Caller, PD);
    Audio::PlaySample3D(SND_TOSTATION, v.GetPosition());

    v.PushActionMove(ACTION_NEWLIST, PD);
    v.PushActionTurnTo(ACTION_APPEND, TurnTo);
    v.PushActionWait(ACTION_APPEND, 1.5f);
    v.PushActionExecuteCommand(ACTION_APPEND, CMD_TOPOLICESTATION, Caller, 2, false);
    PersonList transports = v.GetTransports();
    if (transports.GetNumPersons() > 0)
    v.PushActionExecuteCommand(ACTION_APPEND, CMD_TOPOLICESTATION, Caller, 1, false);
    }
    } else if(StrCompare(v.GetPrototypeFileName(), OBJ_VAN) == 0)
    {
    GameObjectList l99;
    Game::CollectObstaclesOnVirtualObject(VO_BACK03, l99, ACTOR_VEHICLE);
    if(l99.GetNumObjects() > 0)
    {
    v.PushActionExecuteCommand(ACTION_NEWLIST, CMD_PATROL, Caller, 0, false);
    return;
    } else
    {
    ActorList l11 = Game::GetActors(VO_BACK03TT);
    ActorList l12 = Game::GetActors(VO_BACK03);
    }
    }
    else if(StrCompare(v.GetPrototypeFileName(), OBJ_SUV) == 0)
    {
    GameObjectList l99;
    Game::CollectObstaclesOnVirtualObject(VO_BACK04, l99, ACTOR_VEHICLE);
    if(l99.GetNumObjects() > 0)
    {
    v.PushActionExecuteCommand(ACTION_NEWLIST, CMD_PATROL, Caller, 0, false);
    return;
    } else
    {
    ActorList l11 = Game::GetActors(VO_BACK04TT);
    ActorList l12 = Game::GetActors(VO_BACK04);
    }
    }
    else if(StrCompare(v.GetPrototypeFileName(), OBJ_CRUISER01) == 0)
    {
    GameObjectList l99;
    Game::CollectObstaclesOnVirtualObject(VO_DONUT01, l99, ACTOR_VEHICLE);
    if(l99.GetNumObjects() > 0)
    {
    Game::CollectObstaclesOnVirtualObject(VO_DONUT02, l99, ACTOR_VEHICLE);
    if(l99.GetNumObjects() > 0)
    {
    v.PushActionExecuteCommand(ACTION_NEWLIST, CMD_PATROL, Caller, 0, false);
    return;
    }
    else
    {
    ActorList l11 = Game::GetActors(VO_DONUT02TT);
    ActorList l12 = Game::GetActors(VO_DONUT02);
    }
    }
    else
    {
    ActorList l11 = Game::GetActors(VO_DONUT01TT);
    ActorList l12 = Game::GetActors(VO_DONUT01);
    }
    }
    else if(StrCompare(v.GetPrototypeFileName(), OBJ_CRUISER04) == 0)
    {
    GameObjectList l99;
    Game::CollectObstaclesOnVirtualObject(VO_BACK01, l99, ACTOR_VEHICLE);
    if(l99.GetNumObjects() > 0)
    {
    Game::CollectObstaclesOnVirtualObject(VO_BACK02, l99, ACTOR_VEHICLE);
    if(l99.GetNumObjects() > 0)
    {
    v.PushActionExecuteCommand(ACTION_NEWLIST, CMD_PATROL, Caller, 0, false);
    return;
    }
    else
    {
    ActorList l11 = Game::GetActors(VO_BACK02TT);
    ActorList l12 = Game::GetActors(VO_BACK02);
    }
    }
    else
    {
    ActorList l11 = Game::GetActors(VO_BACK01TT);
    ActorList l12 = Game::GetActors(VO_BACK01);
    }
    } else
    {
    Mission::PlayHint(HINT_NOTVALID);
    return;
    }


    if(l11.GetNumActors() > 0)
    {
    Vector TurnTo = l11.GetActor(0)->GetPosition();
    Mission::PlayHint("L11 is good!");
    } else
    {
    Mission::PlayHint("L11 is bad!");
    return;
    }
    if(l12.GetNumActors() > 0)
    {
    Vector Park = l12.GetActor(0)->GetPosition();
    Mission::PlayHint("L12 is good!");
    } else
    {
    Mission::PlayHint("L2 is bad!");
    return;
    }

    Audio::PlaySample3D(SND_TOSTATION, Caller->GetPosition());
    v.PushActionMove(ACTION_NEWLIST, TurnTo);
    v.PushActionTurnTo(ACTION_APPEND, Park);
    v.PushActionWait(ACTION_APPEND, 1.0f);
    v.PushActionMove(ACTION_APPEND, Park);
    v.PushActionTurnTo(ACTION_APPEND, TurnTo);
    Mission::PlayHint("Going to park bitches!")
    }

    if(ChildID == 1)
    {
    if (v.GetVehicleType() != VT_POLICE_PHC)
    {
    ActorList l1 = Game::GetActors(VO_SPAWN_FRONT);
    if (l1.GetNumActors() > 0)
    Vector TargetPos = l1.GetActor(0)->GetPosition();
    PersonList transports = v.GetTransports();
    for(int i = 0; i < transports.GetNumPersons(); i++)
    {
    transports.GetPerson(i)->PushActionLeaveCar(ACTION_NEWLIST, Caller);
    if(transports.GetPerson(i)->GetRole() == ROLE_GANGSTER)
    {
    transports.GetPerson(i)->SetRole(ROLE_CIVILIAN);
    transports.GetPerson(i)->SetBehaviour(BEHAVIOUR_CIVILIAN_NORMAL);
    }
    transports.GetPerson(i)->PushActionWait(ACTION_APPEND, 0.5f);
    transports.GetPerson(i)->PushActionMove(ACTION_APPEND, TargetPos, true);
    transports.GetPerson(i)->PushActionDeleteOwner(ACTION_APPEND);
    }
    } else
    {
    ActorList l1 = Game::GetActors(VO_ENTRY_HELIPAD);
    if (l1.GetNumActors() > 0)
    Vector TargetPos = l1.GetActor(0)->GetPosition();
    PersonList transports = v.GetTransports();
    for(int i = 0; i < transports.GetNumPersons(); i++)
    {
    transports.GetPerson(i)->PushActionLeaveCar(ACTION_NEWLIST, Caller);
    if(transports.GetPerson(i)->GetRole() == ROLE_GANGSTER)
    {
    transports.GetPerson(i)->SetRole(ROLE_CIVILIAN);
    transports.GetPerson(i)->SetBehaviour(BEHAVIOUR_CIVILIAN_NORMAL);
    }
    transports.GetPerson(i)->PushActionWait(ACTION_APPEND, 0.5f);
    transports.GetPerson(i)->PushActionMove(ACTION_APPEND, TargetPos, true);
    transports.GetPerson(i)->PushActionDeleteOwner(ACTION_APPEND);
    }
    }
    }
    if(ChildID == 2)
    {
    Vehicle v(Caller);
    v.EnableBlinker(BLT_NONE);
    bool ToPoliceStation = false;
    if (v.IsCollidingWithVirtualObject(VO_FRONT01))
    return;
    else
    ToPoliceStation = true;
    if (v.IsCollidingWithVirtualObject(VO_FRONT02))
    return;
    else
    ToPoliceStation = true;
    if (v.IsCollidingWithVirtualObject(VO_FRONT03))
    return;
    else
    ToPoliceStation = true;
    if (v.IsCollidingWithVirtualObject(VO_BACK01))
    return;
    else
    ToPoliceStation = true;
    if (v.IsCollidingWithVirtualObject(VO_BACK02))
    return;
    else
    ToPoliceStation = true;
    if (v.IsCollidingWithVirtualObject(VO_BACK03))
    return;
    else
    ToPoliceStation = true;
    if (v.IsCollidingWithVirtualObject(VO_BACK04))
    return;
    else
    ToPoliceStation = true;
    if (v.IsCollidingWithVirtualObject(VO_DONUT01))
    return;
    else
    ToPoliceStation = true;
    if (v.IsCollidingWithVirtualObject(VO_DONUT02))
    return;
    else
    ToPoliceStation = true;

    if(ToPoliceStation)
    v.PushActionExecuteCommand(ACTION_NEWLIST, CMD_TOPOLICESTATION, Caller, 0, false);
    }
    }
    };

     

     

    Of course, with new scripting, there's new errors:

    ?(_LAToPoliceStationa8392): Error: Symbol l11 is not defined in current scope ?(_LAToPoliceStationa8392):  FILE:mod:/scripts/game/command/LAToPoliceStation.scripta8392 LINE:297?(_LAToPoliceStationa8392): Error: Failed to evaluate l11.GetNumActors()?(_LAToPoliceStationa8392): Possible candidates are...?(_LAToPoliceStationa8392): filename       line:size busy function type and name  

    I don't get why symbol l11 wouldn't be defined at that point.. any idea's?

     

     

     

    ---------------------

     

     

    Breaktrough!

     

    The CRUISER01 just parked, in its own parking space, saying l1 and l2 are good! Going to check what's going on!

     

    Edit:

     

    Well, I'm really stumped.

    CRUISER01 works fine, every single time, parks like a charm, but the VAN, SUV and CRUISER04 just don't work. They still give an L11 error.

    The only difference between those point that I can think of, is that the turnto vo's of the CRUISER01 are outside of the "squad" VO that is used in the PSStart script, and the turnto vo's of the other cars are inside their own squad vo.

    Could this be of any influence? I can barely imagine that it would be, but it's all I can think of.

     

    Edit2:

    So I just ran a test.. That's the problem. The turnto VO's inside the other VO.

    Not very logical, since the logic states 'more than 0'. Two is more then zero right?

    But at least I know how to fix it now. Thank god.

     

    ----------------------

     

    Alright, some final questions so I can finish this:

     

    v.PushActionExecuteCommand(ACTION_APPEND, CMD_TOPOLICESTATION, Caller, 1, false);
     
    Above statement should direct to the command ToPoliceStation, ChildID==1 right?
  9. I'm not quite sure I get it right now. You are looking in the script that uses L99 till L96, and not the one with 4 times L99 right?

     

    Should it look like this then?

    			else if(StrCompare(v.GetPrototypeFileName(), OBJ_CRUISER04) == 0)			{				GameObjectlist l97				Game::CollectObstaclesOnVirtualObject(VO_BACK01, l97, ACTOR_VEHICLE);				if(l97.GetNumObjects() > 0)				{					Game::CollectObstaclesOnVirtualObject(VO_BACK02, l99, ACTOR_VEHICLE);					if(l99.GetNumObjects() > 0)					{						v.PushActionExecuteCommand(ACTION_NEWLIST, CMD_PATROL, Caller, 0, false);						return;					}					else					{						ActorList l1 = Game::GetActors(VO_TT_BACK02);						ActorList l2 = Game::GetActors(VO_BACK02);					}				}				else				{					ActorList l1 = Game::GetActors(VO_TT_BACK01);					ActorList l2 = Game::GetActors(VO_BACK01);				}				} else			{				Mission::PlayHint(HINT_NOTVALID);				return;			}
  10. Hmm, weird.

    I found the one you noticed, and i noticed one missing at 245 too. Added those.

    For the VAN and SUV, still the same. L1 == 0, L2 is good.

     

    Although, for the CRUISER04 I get a different error now. It states:

     

    ?(_LAToPoliceStationa8343): Error: Symbol GameObjectlistl97 is not defined in current scope 
    ?(_LAToPoliceStationa8343):  FILE:mod:/scripts/game/command/LAToPoliceStation.scripta8343 LINE:245
     
    Now is this getting weirder with every edit or what?
  11. I've got another script spawning the vehicles that are assigned to the parking spaces in the correct position. I'm testing it using the VAN, but I believe all other cars give the same result. Let me test

     

    ------

     

    So when using the VAN or SUV, I get the error saying L1 is 0, L2 is good.

    While using the CRUISER04 though, I get an error saying: Error: Symbol l97 is not defined in current scope

     

    PS. I slightly modified the script, since all L parameters (gameobjectlists) were l99.

    New link: Click

×
×
  • Create New...