#1

How I Can Make A Shop in My Script?
Reply
#2

I Wanted to To Ask This Question too , Can Anyone Help me ?
Reply
#3

There are many, many ways to make a shop.
Give us more information.
Reply
#4

You can Map a shop, and create a checkpoint where you'll find all your needs.

Or, use some Filterscripts, they are so useful.

KillerDVX,
Reply
#5

Try this for weapon shop : https://sampforum.blast.hk/showthread.php?tid=475089
and check this : https://sampforum.blast.hk/showthread.php?tid=455022
Reply
#6

Код:
CMD:givewep(playerid, params[])
{
        static
  	    weaponid,
	    ammo;

	if (sscanf(params, "udI(500)", weaponid, ammo))
	    return SendSyntaxMessage(playerid, "/buywep [weapon id] [ammo] [This operation requires $25000!");

	if (weaponid <= 0 || weaponid > 46 || (weaponid >= 19 && weaponid <= 21))
		return SendErrorMessage(playerid, "You have specified an invalid weapon.");

	GiveWeaponToPlayer(userid, weaponid, ammo);
	SendClientMessage(playerid, 0xD0AEEBFF, "%s! You bought a %s with %d ammo for $25000! .", ReturnName(userid, 0), ReturnWeaponName(weaponid), ammo);
        GivePlayerMoney(playerid, -25000);
	return 1;
}
Simply.
Reply
#7

ok thanks , But i want to know how to make a checkpoint that when i enter it , teleport me into the interior of the shop
Reply
#8

To create a checkpoint :

PHP код:
SetPlayerCheckpoint(playeridxyzsize); 
And to call when the player's entering the checkpoint :

PHP код:
public OnPlayerEnterCheckpoint(playerid)
{
    
SetPlayerPos(playeridx,y,z);
    
SetPlayerInterior(playeridinteriorid)
    return 
1;

Or you can just use a stream checkpoint. ^^

KillerDVX,
Reply
#9

Quote:
Originally Posted by KillerDVX
Посмотреть сообщение
To create a checkpoint :

PHP код:
SetPlayerCheckpoint(playeridxyzsize); 
And to call when the player's entering the checkpoint :

PHP код:
public OnPlayerEnterCheckpoint(playerid)
{
    
SetPlayerPos(playeridx,y,z);
    
SetPlayerInterior(playeridinteriorid)
    return 
1;

Or you can just use a stream checkpoint. ^^

KillerDVX,
Thanks ^_^
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)