/linject? -
Hitman-97- - 30.05.2013
Hi there, I've seen this command in many servers,
All what it does is to inject someone in your vehicle (/linject [id]). for example, if you are in a hydra, you can do /linject and inject the chosen player.
Can someone help me with it? Thanks
Re: /linject? -
mahdi499 - 30.05.2013
What does it do exactly,and hydra's can have 1 player in it as i know
Re: /linject? -
Hitman-97- - 30.05.2013
The hydra has a maximum of 2 slots.
Re: /linject? -
Basssiiie - 30.05.2013
A Hydra has only
one seat. The only planes with multiple seats are the Beagle, the Skimmer and the Dodo.
Re: /linject? -
Strier - 30.05.2013
Get the player's state... if the target is on foot and the playerid is on a hydra, Set the player state to PLAYER_STATE_PASSENGER
Re: /linject? -
Hitman-97- - 31.05.2013
Can you give me an example? I've tried to do it, but doesn't work
Re: /linject? -
Scenario - 31.05.2013
It's not linject/inject, it's eject.
You'll need to make a command that uses
GetPlayerState and
RemovePlayerFromVehicle to remove a player from a vehicle. Search for one.
Re: /linject? -
Hitman-97- - 31.05.2013
Quote:
Originally Posted by RealCop228
|
I don't mean like that, I mean like when you want to set a player as a passenger in your hydra.
Re: /linject? -
DobbysGamertag - 31.05.2013
Are you wanting it to put the target player in the vehicle with you? I've got a command that teleports you into a players vehicle if you want to play around with it?
EDIT:
not sure if this is what you want. I can't test as i cant get anyone online to test with me.
pawn Код:
CMD:getincar(playerid,params[])
{
new target;
if(sscanf(params,"u",target))return SendClientMessage(playerid,-1,"SYNTAX: /getincar [id]");
if(!IsPlayerConnected(playerid))return SendClientMessage(playerid,-1,"Player not connected");
else
{
GetPlayerVehicleID(playerid);
PutPlayerInVehicle(target,playerid,1);
}
return 1;
}
Re: /linject? -
mahdi499 - 31.05.2013
I m using Sscanf and ZCMD
pawn Код:
CMD:inject(playerid, params[])
{
new targetid, sid;
if(sscanf(params, "ui", targetid, sid)) return SendClientMessage(playerid, -1, " USAGE:/inject (targetid) (seatid)");
if(targetid == playerid) return SendClientMessage(playierd, -1, "You can't inject yourself");
{
new Vehid = GetPlayerVehicleID(playerid);
PutPlayerInVehicle(targetid, Vehid, sid);
SendClientMessage(playerid, -1, "You have Placed Your target in the car!");
return 1;
}
}