Working sprunk
#1

Hi, I would like to add more working sprunk machines, not just an object, I know that I can use
Код:
if (newkeys & KEY_FIRE && IsPlayerInRangeOfPoint(playerid, 1, sprunkX, sprunkY, sprunkZ)) 
{
        // Apply animations, give health, substract money.
        .....
But is there any other way to do that?
Reply
#2

Natively ? no.

But you can use an include
https://sampforum.blast.hk/showthread.php?tid=553952
Reply
#3

PHP код:
if (newkeys KEY_FIRE && IsPlayerInRangeOfPoint(playerid3sprunkXsprunkYsprunkZ)) 
{
        new 
hp;
        
GetPlayerHealth(playeridhp);
        
ApplyAnimation(playerid,"VENDING","VEND_Use",1.4,,1,1,0,2500,1);
        
ApplyAnimation(playerid,"VENDING","VEND_Use",1.4,,1,1,0,2500,1);
        
GameTextForPlayer(playerid"-3"50001);
        if(
GetPlayerHealth(playerid) < 100)
        {        
            
SetPlayerHealth(playeridhp+28);
        } 
        else
        {
            
SetPlayerHealth(playerid100);
        }

Then somewhere up top of your script, make an enum that houses all the Sprunk coordinates.
Reply
#4

Also, check out this:
https://sampforum.blast.hk/showthread.php?tid=553952
Reply
#5

Quote:
Originally Posted by oSAINTo
Посмотреть сообщение
Interesting, thanks !
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)