SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 30/06/2020, 08:55 PM   #1
MarianImmortalGod
Big Clucker
 
Join Date: Mar 2018
Posts: 106
Reputation: 1
Default About coords and verification

Hello.

Can someone help me about a thing that i wanna do.

I want to check every payday that players that have a house in a turf should pay a debt.

Any ideas how ?

I know i need to check if player has a house then what, how can i check if in above a house is a turf.
MarianImmortalGod is offline   Reply With Quote
Old 30/06/2020, 09:14 PM   #2
josh
Big Clucker
 
Join Date: Jul 2019
Posts: 74
Reputation: 3
Default Re: About coords and verification

Quote:
Originally Posted by MarianImmortalGod View Post
Hello.

Can someone help me about a thing that i wanna do.

I want to check every payday that players that have a house in a turf should pay a debt.

Any ideas how ?

I know i need to check if player has a house then what, how can i check if in above a house is a turf.
idkk
josh is offline   Reply With Quote
Old 30/06/2020, 10:24 PM   #3
MarianImmortalGod
Big Clucker
 
Join Date: Mar 2018
Posts: 106
Reputation: 1
Default Re: About coords and verification

Thanks man, but don't answear if you don't know .. i mean like cmon.


Someone else ?
MarianImmortalGod is offline   Reply With Quote
Old 30/06/2020, 10:42 PM   #4
xRadical3
Gangsta
 
xRadical3's Avatar
 
Join Date: May 2017
Location: Iran
Posts: 565
Reputation: 20
Default Re: About coords and verification

You just can detect it normal if a house in a special area.
Example:
pawn Code:
IsPointInArea(Float:X, Float:Y, Float:Z, Float:MaxX, Float:MaxY, Float:MinX, Float:MinY)
{
    if(X >= MinX && X <= MaxX && Y >= MinY && Y <= MaxY) return 1;
    return 0;
}
//put house position in X, Y, Z
//put the turf area coords in MaxX, MaxY, MinX, MinY
//If the value of return is 1, it means that the house is on the turf
xRadical3 is offline   Reply With Quote
Old 30/06/2020, 11:59 PM   #5
MarianImmortalGod
Big Clucker
 
Join Date: Mar 2018
Posts: 106
Reputation: 1
Default Re: About coords and verification

Quote:
Originally Posted by xRadical3 View Post
You just can detect it normal if a house in a special area.
Example:
pawn Code:
IsPointInArea(Float:X, Float:Y, Float:Z, Float:MaxX, Float:MaxY, Float:MinX, Float:MinY)
{
    if(X >= MinX && X <= MaxX && Y >= MinY && Y <= MaxY) return 1;
    return 0;
}
//put house position in X, Y, Z
//put the turf area coords in MaxX, MaxY, MinX, MinY
//If the value of return is 1, it means that the house is on the turf
It works, thanks verry much dude.
MarianImmortalGod is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[request] Verification SukMathcuck Scripting Help 2 26/06/2015 05:14 PM
Email verification osman2571 Scripting Help 17 13/11/2014 11:48 PM
Admin verification xdarren Scripting Help 4 28/09/2013 10:42 PM
Verification Age cristip Scripting Help 8 17/04/2013 11:30 AM


All times are GMT. The time now is 05:03 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.