Hello all, I am new in this Forum don't know how to post but i am trying to post don't laugh guys
as you guys see the title i made house in grove street,
Ofcourse Ryder house located in LS Grove.
So Ryder house gives you Crack and Weed you can change the price for it from filterscript.
Crack fill players armour and Weed fills player HP. And it is best for RP server.
Screenshots:
Oppps i don't know how to upload it shit but don't worry guys its preety simple
First of all open this code in Pawno and Complite it, Second Paste it to your server Filterscript folder and set the name RydersDH, Third Goto your server.cfg Type on filter RydersDH and thats it then go in game and test it
I hope You like it guys If you like this post like it and plz someone comment down how to upload screenshot
as you guys see the title i made house in grove street,
Ofcourse Ryder house located in LS Grove.
So Ryder house gives you Crack and Weed you can change the price for it from filterscript.
Crack fill players armour and Weed fills player HP. And it is best for RP server.
Screenshots:
Oppps i don't know how to upload it shit but don't worry guys its preety simple
Code:
// This is a comment
#define FILTERSCRIPT
#include <a_samp>
forward PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z);
#define COLOR_BLUELIGHTER 0x00BFFFAA
#define COLOR_FADE 0xE6E6E6E6
#define COLOR_GREY 0xAFAFAFAA
#define COLOR_WHITE 0xFFFFFFAA
#define COLOR_RED 0xFF0000AA
public OnFilterScriptInit()
{
print("\n--------------------------------------");
print(" Ryder's Drug House by Ali Shan");
print("--------------------------------------");
// RYDERS DRUG HOUSE enter
AddStaticPickup(1254,23,2459.4539,-1690.9188,13.5453);
// RYDERS DRUG HOUSE exit
AddStaticPickup(1254,23, 2454.717041,-1700.871582,1013.515197);
return 1;
}
public OnFilterScriptExit()
{
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/takecrack", cmdtext, true, 10) == 0) {
new Float:PlayersArmour;
GetPlayerArmour(playerid, PlayersArmour);
//Ryder's Drug house near grove
if(PlayerToPoint(30.0, playerid, 2454.717041,-1700.871582,1013.515197)) {
SetPlayerArmour(playerid, PlayersArmour + 10.0);
SendClientMessage(playerid, COLOR_FADE, "Ryder: Ey here's yo crack homie");
ApplyAnimation(playerid,"FOOD","EAT_Burger",4.1,0,0,0,0,0);
SendClientMessage(playerid, COLOR_BLUELIGHTER, "* You have gave $3000 to Ryder, and used the crack.");
GivePlayerMoney(playerid, -3000);
return 1;
}
SendClientMessage(playerid, COLOR_WHITE, "You are not at the drug house ! use /housedrugplace to find it.");
return 1;
}
if (strcmp("/takeweed", cmdtext, true, 10) == 0) {
new Float:PlayersHealth;
GetPlayerHealth(playerid, PlayersHealth);
//Ryder's Drug house near grove
if(PlayerToPoint(30.0, playerid, 2454.717041,-1700.871582,1013.515197)) {
SetPlayerHealth(playerid, PlayersHealth + 10.0);
SendClientMessage(playerid, COLOR_FADE, "Ryder: Ey here's yo weed homie");
ApplyAnimation(playerid,"FOOD","EAT_Burger",4.1,0,0,0,0,0);
SendClientMessage(playerid, COLOR_BLUELIGHTER, "* You have gave $2500 to Ryder, and used the weed.");
GivePlayerMoney(playerid, -2500);
return 1;
}
SendClientMessage(playerid, COLOR_WHITE, "You are not at the drug house ! use /drugplace to find it.");
return 1;
}
if (strcmp("/enter", cmdtext, true, 10) == 0) {
//Ryder's Drug house
if(PlayerToPoint(10.0, playerid, 2459.4539,-1690.9188,13.5453)) {
SendClientMessage(playerid, COLOR_FADE, "Ryder: Who da' fuck in my house !?");
SendClientMessage(playerid, COLOR_RED, "* Ryder grabs his bat");
SendClientMessage(playerid, COLOR_RED, "REMINDER: to exit ryder's drug house use /exit");
SendClientMessage(playerid, COLOR_GREY, "___* * Welcome to Ryder's Drug house you can use crack/pot you'll have to buy it * *___");
SendClientMessage(playerid, COLOR_GREY, "/takecrack(to use ryder's crack) /takeweed(to use ryder's weed)");
SendClientMessage(playerid, COLOR_GREY, "[PRICE] Crack($3000) Weed($2500))");
// Ryder's interior
SetPlayerPos(playerid,2454.717041,-1700.871582,1013.515197);
SetPlayerInterior(playerid, 2);
return 1;
}
}
if (strcmp("/exit", cmdtext, true, 10) == 0) {
//ryder's drug house exit
if(PlayerToPoint(15.0, playerid, 2454.717041,-1700.871582,1013.515197)) {
//Ryder's drug house exit
SetPlayerPos(playerid,2459.4539,-1690.9188,13.5453);
SetPlayerInterior(playerid, 0);
return 1;
}
}
if (strcmp("/drughouse", cmdtext, true, 10) == 0) {
SetPlayerCheckpoint(playerid, 2459.4539,-1690.9188,13.5453, 3.0);
SendClientMessage(playerid, COLOR_BLUELIGHTER, " * * Drug house checkpoint was placed on your map, look on your map for a red blip then follow it * *");
return 1;
}
if (strcmp("/drughelp", cmdtext, true, 10) == 0) {
SendClientMessage(playerid, COLOR_WHITE, "___* * Welcome to Ryder's Drug house you can use crack/pot you'll have to buy it * *___");
SendClientMessage(playerid, COLOR_GREY, "/takecrack(to use ryder's crack) /takeweed(to use ryder's weed)");
SendClientMessage(playerid, COLOR_GREY, "[PRICE] Crack($3000) Weed($2500))");
return 1;
}
return 0;
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
return 1;
}
public OnPlayerExitVehicle(playerid, vehicleid)
{
return 1;
}
public OnPlayerStateChange(playerid, newstate, oldstate)
{
return 1;
}
public OnPlayerEnterCheckpoint(playerid)
{
return 1;
}
public OnPlayerLeaveCheckpoint(playerid)
{
return 1;
}
public OnPlayerEnterRaceCheckpoint(playerid)
{
return 1;
}
public OnPlayerLeaveRaceCheckpoint(playerid)
{
return 1;
}
public OnRconCommand(cmd[])
{
return 1;
}
public OnPlayerRequestSpawn(playerid)
{
return 1;
}
public OnObjectMoved(objectid)
{
return 1;
}
public OnPlayerObjectMoved(playerid, objectid)
{
return 1;
}
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(PlayerToPoint(15.0, playerid, 2459.4539,-1690.9188,13.5453)) {
GameTextForPlayer(playerid, "~b~Ryder's crack house~w~ use /enter to enter", 5000, 3);
return 1;
}
if(PlayerToPoint(15.0, playerid, 2454.717041,-1700.871582,1013.515197)) {
GameTextForPlayer(playerid, "~b~/takecrack~w~ or ~b~/takeweed~w~ for drugs", 5000, 3);
return 1;
}
return 1;
}
public OnVehicleMod(playerid, vehicleid, componentid)
{
return 1;
}
public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
{
return 1;
}
public OnVehicleRespray(playerid, vehicleid, color1, color2)
{
return 1;
}
public OnPlayerSelectedMenuRow(playerid, row)
{
return 1;
}
public OnPlayerExitedMenu(playerid)
{
return 1;
}
public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
{
return 1;
}
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
return 1;
}
public OnRconLoginAttempt(ip[], password[], success)
{
return 1;
}
public OnPlayerUpdate(playerid)
{
return 1;
}
public OnPlayerStreamIn(playerid, forplayerid)
{
return 1;
}
public OnPlayerStreamOut(playerid, forplayerid)
{
return 1;
}
public OnVehicleStreamIn(vehicleid, forplayerid)
{
return 1;
}
public OnVehicleStreamOut(vehicleid, forplayerid)
{
return 1;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
return 1;
}
public OnPlayerClickPlayer(playerid, clickedplayerid, source)
{
return 1;
}
public PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z)
{
new Float:oldposx, Float:oldposy, Float:oldposz;
new Float:tempposx, Float:tempposy, Float:tempposz;
GetPlayerPos(playerid, oldposx, oldposy, oldposz);
tempposx = (oldposx -x);
tempposy = (oldposy -y);
tempposz = (oldposz -z);
if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi))) {
return 1;
}
return 0;
}
First of all open this code in Pawno and Complite it, Second Paste it to your server Filterscript folder and set the name RydersDH, Third Goto your server.cfg Type on filter RydersDH and thats it then go in game and test it
I hope You like it guys If you like this post like it and plz someone comment down how to upload screenshot