tictaczep / darkrp

Automatically exported from code.google.com/p/darkrp
0 stars 0 forks source link

Sold vehicles count toward vehicle limit + 2 minor issues #878

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What is the problem?

When a player sells a vehicle, that vehicle still counts toward the total # of 
vehicles he can own.

What steps will reproduce the problem?

Set a vehicle limit, reach that limit, sell a vehicle, try to buy another 
vehicle (from f4).

Do you have any errors? serverside or clientside? If you do, which ones?

None

Are you using the downloaded version or an SVN revision (if SVN, which
revision number)?

1194

Please provide any additional information below.

+ PS 1: Selling vehicles 

rp_vehiclecost = 3000

AddCustomVehicle("Airboat", "models/airboat.mdl", 3000)
AddCustomVehicle("GTA4 Hakumai", "models/sickness/hakumaidr.mdl", 5000)

Each of these vehicles will cost the correct price $3000 & $5000. If sold, both 
of these vehicles will sell for $1998 (66% of rp_vehiclescost value). Shouldn't 
the sell price be based on vehicle cost (in AddCustomVehicle)and not 
rp_vehiclecost?

+ PS 2: Purchased vehicles that are later sold (or vehicles spawned by admin) 
are driveable without the player needing to purchase first(like doors can be 
opened without purchasing them first). Players won't pay vehicles if they can 
use for free.

Original issue reported on code.google.com by chaosity...@gmail.com on 5 Jul 2012 at 5:26

GoogleCodeExporter commented 8 years ago
The current behaviour is that the vehicle counter for a player will decrease 
when the vehicle is removed from the game. The reason why I made it this way is 
because people can spam vehicles otherwise:
1. get loadsa money
repeat:
2. spawn vehicle 
3. Sell vehicle
until out of money.

However I understand that a car dealer might want to buy and sell multiple 
vehicles, more than the limit. 

The solution I have in mind is to decrease the vehicle counter when /someone 
else/ buys the vehicle. Spamming will be hard because you have to get other 
people to buy your car, yet when they do buy your car, you can spawn new ones.

What do you think of that idea?

Original comment by fpeijnen...@gmail.com on 5 Jul 2012 at 8:58

GoogleCodeExporter commented 8 years ago
I dont think that vehicle spamming is a problem because spawning vehicles costs 
a lot of money. When i played on some servers their car deapers was usually low 
on money and i needed to pay first to get a vehicle from them.

Original comment by kprokin1@gmail.com on 5 Jul 2012 at 11:27

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
for ps1 I think it's better to let the selling be done manually instead of an 
automatic percentage.

for PS2 I kind of like it, but I think just unlocking the vehicle when not 
owned is better. I don't think people need to be able to lock vehicles they 
don't own.

Original comment by fpeijnen...@gmail.com on 6 Jul 2012 at 6:29

GoogleCodeExporter commented 8 years ago
Decrease the vehicle counter when /someone else/ buys the vehicle. - Sounds 
good!

(Ooops, I just noticed that my PS1 & PS2 read like feature requests, instead of 
the intended "defect")

RE: PS 1

That's the thing. Currently, cars have/can have different prices, but sold 
(after original purchase) for 1 set global price (66.6% of rp_vehiclecost 
value). In some cases a player can make a profit selling a car.

rp_vehiclecost $3000

Car 1 buy price: $1,500
Car 2 buy price: $15,000
Car 3 buy price: $150,000

All 3 car owners will receive $1998 for selling their vehicle regardless of 
what they paid for it.
It would make more sense to have the sell price be based off of the original 
purchase price (whether a set AddCustomVehicle sell price or a percentage).

RE: PS 2

If unowned vehicles that were sold by other players were automatically locked 
to everyone (hopefully still lockpickable) until they were repurchased, players 
wouldn't be able to take them for joy rides and abandon them all over the 
map(ie. into the lake) having not paid for them. Vehicle purchases are probably 
the largest in-game expense and many such purchases don't happen because of the 
"free used vehicle market."

Sorry if it sounds like I'm repeating myself. Thanks for reading and I respect 
your decision! 

Original comment by chaosity...@gmail.com on 6 Jul 2012 at 9:46

GoogleCodeExporter commented 8 years ago
Let's see if you like the new change.

Original comment by fpeijnen...@gmail.com on 6 Jul 2012 at 11:32

GoogleCodeExporter commented 8 years ago
Fuck I did something stupid

Original comment by fpeijnen...@gmail.com on 6 Jul 2012 at 11:32

GoogleCodeExporter commented 8 years ago
yes now it decreases the count when someone else buys it.

Original comment by fpeijnen...@gmail.com on 6 Jul 2012 at 11:57