Get diving
#1

Hi. I have one question. Is there in Pawn a function somthing like "GetPlayerHealth()" just for diving?(It's a blue bar in
the game)...Thanks from God;p
Reply
#2

Nope there isnt, but the bar just represents how far away you are from the ground, isnt it ?
So you could use the Z value from GetPlayerPos ?
Reply
#3

I think he means the o2 bar. But this also cant be accessed by samp.
Reply
#4

Yes I mean the o2 bar....I'd like to create a textdraw with breath level...For example if I'm diving the o2 is going down...you know 100 then 99.98.97 during that i'm diving...
Reply
#5

Quote:
Originally Posted by imosek
Посмотреть сообщение
Yes I mean the o2 bar....I'd like to create a textdraw with breath level...For example if I'm diving the o2 is going down...you know 100 then 99.98.97 during that i'm diving...
If so, then check the interval between o2 level and create a textdraw on top of the bar showing the value which depends on the interval between o2 level.
Reply
#6

Yes, but how to create a function when a player is below the water? And when is he diving?
Reply
#7

This include may help you. http://forum.sa-mp.com/showthread.ph...PlayerSwimming
Reply
#8

But this swimming concerns swimming on the water? For example the crawl..?
Reply
#9

Quote:
Originally Posted by imosek
Посмотреть сообщение
But this swimming concerns swimming on the water? For example the crawl..?
Yes, but when you go under water, your GetPlayerPos is generally inferior to 0, therefore you can also determine it from that.
Reply
#10

I'm beginner I don't undestand a lot...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)