Jump to content
EmergencyFan97

Removing Vehicles/Changing Models

Recommended Posts

If I wanted to remove a vehicle from a station, how would I go about doing that?  Simply delete the box-thingy (prototype?) in the editor?  And if I wanted to change the model of a truck, would I simply replace the model with the one of the same name and ensure it had a skin?

Link to comment
Share on other sites

  On 9/13/2014 at 4:49 PM, EmergencyFan97 said:

If I wanted to remove a vehicle from a station, how would I go about doing that?  Simply delete the box-thingy (prototype?) in the editor?  And if I wanted to change the model of a truck, would I simply replace the model with the one of the same name and ensure it had a skin?

To remove a vehicle, simply remove the part in the script that calls the ingame function to spawn the vehicle. This is in LAFireStationStart.script

You are correct about how to change the model of a truck. Lights, physics and commands are another problem you will face afterwards.

Link to comment
Share on other sites

  On 9/13/2014 at 4:54 PM, EmergencyFan97 said:

What about physics?  I can handle the lights and commands.

Nothing too serious. Just set it up so that the yellow box fits the model perfectly. This is to make sure the vehicle's collision is correct and it can go around obstacles properly. Be sure to check "always use physics geom". This little tick box nearly killed my mod by making it unplayable because I forgot to actually set the game to use the custom collision boxes.

Link to comment
Share on other sites

OK.  And the part I am looking for in LAFireStationStart, is this it?

const char VO_ALS5[]     = "fs_als5";

Edit:  Also, I am looking to re-insert a changeclothes command to where SCBA FF can change to regular FF.  I gave the commands to each person, but they disappear when I execute the command in-game.  What am I doing wrong?

Link to comment
Share on other sites

  On 9/13/2014 at 5:01 PM, EmergencyFan97 said:

OK.  And the part I am looking for in LAFireStationStart, is this it?

const char VO_ALS5[]     = "fs_als5";

Edit:  Also, I am looking to re-insert a changeclothes command to where SCBA FF can change to regular FF.  I gave the commands to each person, but they disappear when I execute the command in-game.  What am I doing wrong?

 

Not really. You would be looking for this:

ActorList l19 = Game::GetActors(VO_HAZMAT);for(int i=0; i < l19.GetNumActors(); i++){	Vector Hazmat = l19.GetActor(0)->GetPosition();	Vehicle m = Game::CreateVehicle(OBJ_HAZMATSQUAD, UNNAMED);	m.EnableBlueLights(false);	m.EnableHeadLights(false);	m.SetChildEnabled("exhaust", false);	m.SetPosition(Hazmat);	m.SetRotation(gate6);	m.UpdatePlacement();	m.SetMaxPassengers(4);	m.SetMaxTransports(2);	m.SetSpeed(8.0f);	m.PushActionWait(ACTION_NEWLIST, 1.0f);	m.PushActionExecuteCommand(ACTION_APPEND, CMD_COMMANDS, Caller, 0, false);	m.PushActionExecuteCommand(ACTION_APPEND, CMD_NORMAL, Caller, 0, false);}

Simply comment it out with this:

//

for every line or /* at the beginning of that section and */ at the end.

Or you could just delete it, but then you might have a change of mind and want to bring it back. Its up to you really.

Has your changeclothes script been modified?

Link to comment
Share on other sites

OK, thanks for the help on that.  And I have no idea if it's been modified, it's from Manchester Mod, not base LA mod.

 

Edit:  I looked through the script, but as I have very minor scripting experience, I'm not sure what's wrong with it.  Script in its entirety is found below.

 

 

  Reveal hidden contents
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...