SA-MP Forums

SA-MP Forums (
-   Help Archive (
-   -   Sm like an optional Parameter (

Rauminator 06/02/2010 05:38 PM

Sm like an optional Parameter
Hey Guys
I want to realize a Reallife Mode but I stack at the Carsystem.
My idea: A Optional Parameter to AddStaticVehicle but I know its not realizable without changing the corefiles.

Anyone with an idea?

DeathOnaStick 06/02/2010 06:37 PM

Re: Sm like an optional Parameter
What do you mean? I don't understand neither, what you want to effect with it, nor, what you want to do with it. Please explain a bit further.

Correlli 06/02/2010 06:40 PM

Re: Sm like an optional Parameter
You don't need to change the core files.

pawn Code:
stock AddVehicle(modelid, Float:spawn_x, Float:spawn_y, Float:spawn_z, Float:angle, color1, color2, my_param)
      vehicleID = AddStaticVehicle(modelid, spawn_x, spawn_y, spawn_z, angle, color1, color2);
  myVariable[vehicleID] = my_param;
  return vehicleID;

I haven't tested this, i guess you'll need to that.

If this is what you want?

All times are GMT. The time now is 07:29 PM.

Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.