Eating machines,
#1

Hey, is there any way to check if the player is using those snack machines?
Reply
#2

OnPlayerKeyStateChange + IsPlayerInRangeOfPoint ??
Reply
#3

Quote:
Originally Posted by iTorran
Посмотреть сообщение
OnPlayerKeyStateChange + IsPlayerInRangeOfPoint ??
but then I will have to know EVERY single eating machine in Los Santos, which is quite a lot I guess.
Reply
#4

It shouldnt be too much work, 40/50 of them :P make an array or something
Reply
#5

Or you can just delete in Jerneljs map editor.
Reply
#6

You could check if the player is using the vending machine animation.
Reply
#7

https://sampwiki.blast.hk/wiki/VendingMachines

All the vending machines in the world.
Reply
#8

The list above is really useful!

If you want to try another way, you can detect the amount of health added to player when he is eating.
But it could be hard to accurate, because there are so many things you need to check, for example when he is eating and he has 90% health, the amount of health added should be 10% instead of the amount that added when eating.

So, without any complications, use a list of positions and IsPlayerInRangeOfPoint
Reply
#9

Ok, that list is usefull, Now im not that good with lists, so do I really have to check like IsPlayerInRangeOfPoint(thing 1||thing2||ting3 etc... untill like 70?

or is there a better way
Reply
#10

Arrays?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)