hello, I understand that this is a bit illogical given the main function of the plugin, but I did not find a solution on umod, so I suggest adding a block function to push someone else's vehicle without a lock. So far I have taken part of your code and added VehicleLicence, it would be more logical to add this to that plugin, but it does not have a developer, thanks.
Push lock without lockers optionSuggestion
I don't mind writing a small standalone plugin to block pushing of vehicles under certain circumstances. I just need a bit of information.
- If the vehicle has no lock, nobody should be able to push it?
- If the vehicle has a lock, but that lock is unlocked, who should be able to push it?
- If the vehicle has a lock which is locked, who should be able to push it? Authorized players, unauthorized players, or both (according to lock authorization).
- Does it matter where the vehicle came from (e.g., whether it was spawned by a plugin and the vehicle is owned)?
- Also, what problem are you solving exactly?
can u make config for it?
1) everyone / nobody / team
2) everyone / nobody / team (if 1 - everyone -> 2 - everyone , if 1 - nobody -> 2 - nobody)
3) from VehicleDeployedLockes / everyone
4) only owned (claimed)
5) I want the purchased vehicle in the VehicleLicence plugin to have a push setting - everyone / nobody / team
like it:
private object OnVehiclePush(BaseVehicle vehicle, BasePlayer player)
{
return OnVehiclePush2(player, vehicle);
}
private object OnVehiclePush2(BasePlayer friend, BaseEntity parentEntity)
{
Vehicle vehicle;
if (!TryGetVehicle(parentEntity, out vehicle))
{
return null;
}
if (HasAdminPermission(friend))
{
return null;
}
SendCantUseMessage(friend, vehicle);
return _false;
} That sounds a bit more complicated than I want to take on. What original problem are you trying to solve with this? One player pushed another player's vehicle and that caused a disruption somehow? How often does that happen? Does it happen in particular locations such as monuments or zones? There may be a simpler solution than making this highly configurable.
as such, there is no problem, I just wanted the players to not be able to push other people's vehicles, then I just answered your questions :) at the moment with the code above in the VehicleLicence plugin, only the owner's team can push vehicles. it's just that I don't like the fact that I made changes to the plugin, as if a ready-made solution for this situation would not interfere. thanks