[GameMode] [GM] The Godfather
#1

This script is not recommended for new scripters!!

First Thread: http://forum.sa-mp.com/index.php?topic=81410.0


Intro:
As some of you readers might have witnessed that the Godfather server is no longer running my script, as they were trying to trash me as soon a different script would be out since i wasn't active to much anymore.
Because of that i made some drastic actions, that might have been to harsh actually, but what done is done.

Now since alot of people still think i have left so much of PEN1 inside my script, you are about to witness that i've created way to many features that will silence those people once and for all.
This is not a desperate decision of the actions i have taken on the Godfather server, it's just that i'm done with scripting for SA-MP and i hope other people can enjoy of what i've created.
Also some of the people of the Godfather community might read this, and said Brando has worked with me on this script...which is not true.
Brando's only thing he has done ever in the script, was to make a simple call function, he never had his hands on the source (last 3 versions).

Before we begin with the rest of the information about the mode, first some backside information:
Code:
Just to begin with, i've never taken any credit of parts that were created by Astro (Denver) aka
Denver the creator of PEN1.
Valhalla Gaming Comunity has indeed paid me for this very script you are about to read, where they
only paid for the systems and parts that were created by me.
They received this script a few months ago, and their server owner is trying to rip me off.
Due to this fact + i'm not scripting anymore, i release this script so that everyone can use it.

Credits to Astro.
Credits to Tratulla for his 2 .ini Functions.
Credits to the Fuel System creator on SA-MP forums.
Credits to Morph for the Name Showing timer.
As i have made alot of Godfather versions, this is the last version i stopped with, and i wanted most systems to work dynamically, as you will find out.
I can point out already, that some systems look big when you take a look in the source, that's because my knowledge in this scripting grown more lately on then when i began with scripting and then used more arrays as only 1 enum for big system as you will see eventually.
Also stuff that was created in Godfather v1, might still have some stuff in there that might look like a piece of Noob code .
I have to warn you though, since the Godfather Server worked with a Registration script (PHP) i don't have a registration system in the mode, but i'm sure you scripters around here can make one, as it only takes 5 - 10 mins :P.

Now that's all taken care of, let's start with the mode systems & functions.

(Credits to: Antonio_Morelli, For a look on ALL commands: http://www.randombrando.com/gta_foru...ead.php?t=3105)

Mode information:

Static Factions:
- Police Department
- FBI/ATF Team.
- National Guard.
- Medical Department (Ambulances & Firemen).
- La Cosa Nostra.
- Yakuza.
- Mayor.
- Hitman Agency.
- CNN Studio.
- Taxi Cab Company.
- School Instructors (License system).

Tutorial:
- Will react only if you registered a new account.
- You must fill in your <censored> (Male / Female).
- You must fill in your birthdate (Will automaticly calculate what age you are).
- You must fill in your Origin (Based on this, you will spawn somewhere in SA).
- After all the filling in options, you will get a tutorial containing rules etc..

Leader System (Dynamic):
- Admin can appoint a player that will then Lead a Faction (of above).
- Leader can invite Civilians (With faulty check system in it).
- Leader can kick players out.
- Leader can assign Ranks to his Members.
- As soon a Leader invites a Civilian, it will check what that Civilian will become and teleports him somewhere, where the Civilian can choose a skin that comes with that Faction.

Family System (Dynamic):
- This is done by the 2 Organisation Leader (La Cosa Nostra & Yakuza).
- Both the Organisations can recruit 5 families.
- Both the Organisations can delete their own Families.
- Players can check which families are created, and who's the Leader of it.
- Players can check which players are in a family.
- Leaders of a Family can adjust anything they like (Name / MOTD / Color / Spawn).
- Leaders can Invite / Uninvite players or give them a Rank.

Turf System (Needs some tweaks..) (Dynamic):
- There are several turfs that can be given to Families by Organistaion Leaders.
- As soon a Family get's a Turf, it will become their Color (Not fully working i think as they keep being grey).

House System:
- Still in because it was so nicely created by Astro.

Business System (Looks like Astro's, but is rewritten plus different functions):
- Uses products instead of Components & Products.
- Owner name will be shown when entering the icon.
- Extortioner name will be shown when entering the icon.
- Coordinates of going in and out will be saved.
- Level requirement active aswell.
- Basicly some of the stuff that Astro had, only i reduced it and went to Products and added Extortion.

Extortion System:
- Owners of a Business can assign a player as the business's extortioner.
- Owners of a Business can also delete the extortioner of their business.
- As soon a Business earns money, and it has an extortioner it will check if the extortioner is online and will give him 10% of the earnings the Business is about to get.

Karting System (Business):
- Located at the docks, and as soon 2 players or more are in a kart, there will be a message after 15 seconds that a race will start (Message will only be send who is in a kart).
- Automatictly ends the Kart Round after 4 minutes (Just some extra security).
- Checks whoever gets 1st / 2nd / 3rd.
- Checks if more then 2 people are still racing during a Kart Round, if not, the Round will be ended.

Paintball System (Business):
- Located at San Fierro, and as soon 2 players or more are in the Painball Arena, there will be a message after 15 seconds that a fight will start (Message will only be send who is in the area).
- Automatictly ends the Paintball Round after 4 minutes and will announce the Winner.

IRC System (NO not real, just for private channels) (Dynamic):
- Admins can assign a Channel to any player, and that player will then lead that Channel.
- Leader of a channel can set the MOTD / Set a Password / Set if a a Password is needed to come in or not / Lock the Channel / Kick someone.
- As soon you try to join a Channel, it will check if you need a Password or not.
- If you join or leave, everyone in that Channel will receive a message.
- Players can check how many players are in a Channel, and who the leader is of a Channel.
- Players use /i to talk in their Channel.

Mayor System:
- Only 1 mayor, assigned by an Admin.
- Mayor can set the Tax, that will be paid by every player online at PayDay.
- Mayor can give some of the Tax away to every online Cop / FBI / National Guard automaticly (Since Cops etc... have a bad income).

Prison System (Area51):
- Cops / FBI / National Guard can "deliver" players to Fort Demorgan (Area51) and that players is in jail for 1 hour at least.
- Players can't leave the Fort (Should be adjusted perhaps for more fun).
- National Guard (they were guarding the Fort in Godfather Server) can use the Security Building and use 6 cameras for activity.

Marriage System:
- Players can marry each other and share their House & Business.
- Players can divorce each other (One of them will have no House & Business).
- Players can propose to other players.
- Players need a witness in order to Marry.
- Players marry at the church in San Fierro.

Newpaper System (Dynamic):
- A maximum of 10 papers can be created.
- The Newspaper Faction can create a title and lines as a newspaper and it will be saved automaticly.
- Paper Boys can deliver created Newspapers at the Paper Building to players.
- Paper Boys & Newspaper Faction can check if there are any Newspapers.
- Players can read a Newspaper.

Skill System:

Job System:
- Scatterd around LS and SF their are several locations where Civilians can get a job.
- The Job information and name will be shown as soon you walk into the icon.
- You can only get a job if you don't have one yet, and are not in a Family / Faction.
- As soon you accept the job, you get a Job Contract, which you have to forfill for at least 5 hours (ingame time) untill you can quit it.
- When you have a Job, you have access to several commands.
Detective: /find.
Lawyer: /free.
Whore: /<censored>.
Drugs Dealer: /selldrugs.
Car Jacker: Jack any car & /dropcar (sell a car).
Car Mechanic: /repair /refill /duty.
Bodyguard: /guard.
Arms Dealer: /materials /sellgun.
Car Dealer: /sellcar.
Boxer: /boxstats /fight.
Paperboy: /papers /bring /deliver.

CK (Character Kill) System (Dynamic):
- There are only 10 spaces available, if full the CK can't be requested.
- Players can request a Character Kill on someone else, and must be accepted by an Admin.
- Admins can delete the CK out of the list if they don't agree.
- As soon an Admin allows a CK, the system will check if both those players are online.
- If the player kills the other player that he / she wanted to CK, that player is CK'd and can't login on that account anymore.
- If the player that is about to be CK'd, but kills the player that requested the CK, that player instead is CK'd and got pwned and has same result as above.

License System (An idea by someone on the Godfather Forum, thats why it's created this way, noy my own way):
- License Faction can RP their lessons, and eventually give one of the Licenses available (Driving / Flying / Sailing / Fishing / Weapon).
- License Faction can start a lesson (Car / Plane) with a player so he / she can enter that vehicle (Else that vehicle is locked).
- License Faction can easily stop the lesson.
- Cops / FBI / National Guard can take away players Licenses.
- Players can show their Licenses to other players.

Drinking System:
- Players can drink at several pubs and special places.
- Players can choose several things to drink.
- Drinks that contain alcohol can eventually get you drunk for a while.
- If a player is drunk, he will walk drunk every xx seconds (Can be adjusted if you like).
- If a player is drunk and drives the car will change position every xx seconds.

Boxing System:
- Players that have the Boxing job can fight against each other.
- It checks if the ring is not taken at the moment.
- If players win, they will earn Points in their Boxing Skill.
- Players can get several titles the more they fight (Can be adjusted if you like).
- Players can check how many fights they won & lost, and see who is the current champion.
- If a player beats the current champion, there will be a News Message that he's the new champion.
- As soon the champion will fight, the fight will be announced in a News Message and the waiting time for the round to begin will be 60 seconds (normally it's 20 seconds).

Service System:
- Players can call for a Taxi / Bus / Medic / Mechanic to help them out.
- System checks if the Faction that is being called, if anyone is on duty.
- Those Factions that can be called, can choose if they accept the call or not.
- As soon a call get's accepted, the accepter get's a checkpoint to the caller untill he reached that player.

Tie & Tazer System:
- Only Family Members / Leaders can use the Tie and Untie functions.
- You can only Tie someone while both the players are in a car (Just RP the player in, point a gun or something).
- If the player that's being tied is tied for 3 minutes, the rope will get lose and the player is free.
- Only Cops / FBI / National Guard can use the Tazing function.
- If a player get's tazed he will be stunned for x seconds + after effect (bit weird walking).

Taxi & Bus System:
- Check if you are in one of the 2 factions and are in a Taxi or a Bus.
- Busses can only use a static fare, that will be paid immediately when a player enters the bus.
- Bus Driver and the passenger will both get a message they paid, and how much.
- Taxi's can set a fare, that will be paid every xx seconds, since taxi's use a taxi meter in real life too.
- Fare and new fare increasing time will be shown on top of the screen.
- The total fare amount will be paid to the Taxi Driver as soon the passenger steps out.

Hit Contract System:
- Hitman Agency faction can use a portable computer to: See news / Get a contract / Assign a contract to a hitman (Rank needed) / Order a weapon package / Check the ranks of online Hitmen.
- Before a contract can be given to a Hitman, there needs to be searched for a contract (automaticly search).

Weapon Creation System:
- The Arms Dealer job can gather packages, that can later be transformed into Materials.
- With Materials Arms Dealers can create weapons, and sell them to players.

Fishing (An idea of Cops & Robbers):
- Checks if you have a fishing License or not, or you will commit a crime.
- Checks if you have caught to many fishes in to little time, since you can sell the fishes and players will do this all the time to get rich.
- Checks what Level your Fishing Skill is, based on this you can catch better fishes.
- You can see how many fishes you have caught and which.
- You can throw back your last caught fish.
- You can throw all your caught fishes away.
- You can release your last caught fish.

Cooking:
- You can cook several things, like fishes and stuff from the 24/7.
- You can see what you have cooked and how many space you have left.
- You can eat whatever you have cooked.

Ingame Mission Creating System (Dynamic):
- Works only if you are an Admin.
- Admins can easily save and load a new Mission.
- You can create text messages & Game text messages.
- You can save the coordinates where players need to go to.
- You can give a title to your Mission.
- You can give a reward to your Mission if a player succeeds to finish it.
- You can choose if the players will receive checkpoints, or not (If not then they really have to search and it's all based on RP).
- Players can only do a mission once, even if the mission get's reloaded, since the number of the mission get's saved into the players account.
- When a new Mission get's loaded, players can go to the Mission Building and start their Mission.

Premium Account System (Bonus Features for players):
- Your Interest Rate (for each PayDay payment) goes up.
- Your Gas Can (from /get fuel) will be saved into your account.
- You can block Whispers.
- You can turn your Phone on / off.
- You spawn with full health.
- You can quit a job at 1 hour played, instead of 5.
- You are able to get better house cars.
- You will receive your saved weapons on login and after using /tv.
- Every 5 PayDay's you have you'll get an extra Respect Point.
- If you use /buylevel and you have more Respect Points then the level costs, you will get them back to advance youself to the process of the next level.
- On every PayDay, you will get your normal PayCheck, plus half of it as a Bonus.


Perhaps i've forgotten a few things, but you'll see soon enough when you look in the source.
Hope you enjoy the mode as i loved playing untill i got bored of it

Regards,
Fear.

Server Map (Contains all map information, business / houses etc..., credits to someone on the Godfather Community)

Download The Godfather
Reply
#2

1 error cant read from utils!!
Reply
#3

Quote:
Originally Posted by wanTedh
1 error cant read from utils!!
Put the utils.inc into your include folder.
Reply
#4

Quote:
Originally Posted by Seif_
Wasn't such a good idea to make a new one though. The same questions will be asked again. Most won't search in the first thread.
You're so right Seif, just look at this post:
Quote:
Originally Posted by wanTedh
1 error cant read from utils!!
How many times have that been asked? Hundreds!

Reply
#5

Quote:
Originally Posted by wanTedh
1 error cant read from utils!!
Download units.inc include..........
Reply
#6

Hello,

My paytime is not working... It is original paytime from godfather but after paytime when you get rpoint, I get rpoint but after I relog i lost it... I don't know what is problem... It worked on 2.2 samp server but on 2.x it don't work.

Regards,
Borna
Reply
#7

Is it your own GM? or regular GF?
Reply
#8

Quote:
Originally Posted by MenaceX^
Is it your own GM? or regular GF?
No... Its GF script but edited by me... But I put same paytime like in original GF and it wont work again
Reply
#9

Have you renamed OnPlayerUpdate?
Reply
#10

Quote:
Originally Posted by [XG
Tez ]
Quote:
Originally Posted by Borna
Hello,

My paytime is not working... It is original paytime from godfather but after paytime when you get rpoint, I get rpoint but after I relog i lost it... I don't know what is problem... It worked on 2.2 samp server but on 2.x it don't work.

Regards,
Borna
What do you expect us to do without seeing your code, hm?

Here it is:


Code:
public PayDay()
{
	new string[128];
	new account,interest;
	new rent = 0;
	new playerid;
	for(new i = 0; i < MAX_PLAYERS; i++)
	{
		if(IsPlayerConnected(i))
		{
		  if(PlayerInfo[i][pLevel] > 0)
		  {
			  if(MoneyMessage[i]==1)
				{
				  SendClientMessage(i, COLOR_RED, "You failed to pay your debt and you was sended to jail");
				  GameTextForPlayer(i, "~r~Busted!", 2000, 1);
				  SetPlayerInterior(playerid, 3);
			    SetPlayerPos(playerid,198.4892,162.0331,1003.0300);
		      PlayerInfo[i][pJailed] = 1;
		      ResetPlayerWeapons(i);
					WantedPoints[i] = 0;
					PlayerInfo[i][pJailTime] = 240;
					format(string, sizeof(string), "You are jailed for %d seconds. - Bail: Unable", PlayerInfo[i][pJailTime]);
					SendClientMessage(i, COLOR_LIGHTGREEN, string);
				}
				new playername2[MAX_PLAYER_NAME];
				GetPlayerName(i, playername2, sizeof(playername2));
				account = PlayerInfo[i][pAccount];
				new key = PlayerInfo[i][pPhousekey];
				if(key != 255)
				{
					rent = HouseInfo[key][hRent];
					if(strcmp(playername2, HouseInfo[key][hOwner], true) == 0)
					{
						rent = 0;
					}
					else if(rent > GetPlayerMoney(i))
					{
						PlayerInfo[i][pPhousekey] = 255;
						SendClientMessage(i, COLOR_WHITE, "You have been evicted.");
						rent = 0;
					}
					HouseInfo[key][hTakings] = HouseInfo[key][hTakings]+rent;
				}
				new tmpintrate;
				if (key != 255 && strcmp(playername2, HouseInfo[key][hOwner], true) == 0)
				{
				  if(PlayerInfo[i][pDonateRank] > 0) { tmpintrate = intrate+4; }
					else { tmpintrate = intrate+2; }//HouseInfo[key][hLevel]
				}
				else
				{
				  if(PlayerInfo[i][pDonateRank] > 0) { tmpintrate = 3; }
					else { tmpintrate = 1; }
				}
				if(PlayerInfo[i][pPayDay] >= 5)
				{
				  Tax += TaxValue;//Should work for every player online
				  PlayerInfo[i][pAccount] -= TaxValue;
				  if(PlayerInfo[i][pDonateRank] > 0)
					{
					  new bonus = PlayerInfo[i][pPayCheck] / 2;
					  PlayerInfo[i][pPayCheck] += bonus;
					}
					new checks = PlayerInfo[i][pPayCheck];
				  new ebill = (PlayerInfo[i][pAccount]/1000)*(PlayerInfo[i][pLevel]);
				  ConsumingMoney[i] = 1;
				  GivePlayerMoney(i, checks);
				  if(PlayerInfo[i][pAccount] > 0)
				  {
				  	PlayerInfo[i][pAccount] -= ebill;
				  	SBizzInfo[4][sbTill] += ebill;
					}
					else
					{
					  ebill = 0;
					}
					interest = (PlayerInfo[i][pAccount]/1000)*(tmpintrate);
					PlayerInfo[i][pExp]++;
					PlayerPlayMusic(i);
					PlayerInfo[i][pAccount] = account+interest;
					SendClientMessage(i, COLOR_LIGHTGREEN, "------------ PAYTIME ------------");
					format(string, sizeof(string), ".: Earned: %d$ - Tax Money: -%d$ :.", checks, TaxValue);
					SendClientMessage(i, COLOR_WHITE, string);
					if(PlayerInfo[i][pPhousekey] != 255 || PlayerInfo[i][pPbiskey] != 255)
					{
					  format(string, sizeof(string), ".: Electricity Bill: -%d$ :.", ebill);
						SendClientMessage(i, COLOR_GRAD1, string);
					}
					format(string, sizeof(string), ".: Bank Balance: %d$ :.", account);
					SendClientMessage(i, COLOR_WHITE, string);
					format(string, sizeof(string), ".: Interests: %d$ :.", interest);
					SendClientMessage(i, COLOR_WHITE, string);
					SendClientMessage(i, COLOR_LIGHTGREEN, "--------------------------------");
					format(string, sizeof(string), ".: New Balance: %d$ :.", PlayerInfo[i][pAccount]);
					SendClientMessage(i, COLOR_WHITE, string);
					format(string, sizeof(string), ".: Rent: -%d$ :.", rent);
					SendClientMessage(i, COLOR_WHITE, string);
					format(string, sizeof(string), "~w~Pay~p~Time", checks);
					GameTextForPlayer(i, string, 5000, 1);
					PlayerPlaySound(i, 1085, 0.0, 0.0, 0.0);
					rent = 0;
					PlayerInfo[i][pPayDay] = 0;
					PlayerInfo[i][pPayCheck] = 0;
					PlayerInfo[i][pConnectTime] += 1;
					if(PlayerInfo[i][pDonateRank] > 0)
					{
					  PlayerInfo[i][pPayDayHad] += 1;
					  if(PlayerInfo[i][pPayDayHad] >= 5)
					  {
					    PlayerInfo[i][pExp]++;
					    PlayerInfo[i][pPayDayHad] = 0;
					  }
					}
				}
				else
				{
				  SendClientMessage(i, COLOR_RED, "[PAYTIME] You haven't played long enough to obtain a paytime!");
				}
			}
		}
	}
	Checkprop();
	return 1;
}
EDIT:

Quote:
Originally Posted by Brendan_Thomson
Have you renamed OnPlayerUpdate?
No...
Reply
#11

Change OnPlayerUpdate to something else. Like OnPlayerUpdateX or something. I use OnPlayerUpdated but it doesn't really matter.
Reply
#12

Why If I put /setstat to make a player DonateRank if the player reenter to the server didn't have the donaterank?


Help me please! All help is welcome!!
Reply
#13

Code:
public ShowStats(playerid,targetid)
{
Code:
 
    if(PlayerInfo[targetid][pJob] == 1) { jtext = "Detective"; }
    else if(PlayerInfo[targetid][pJob] == 2) { jtext = "Lawyer"; }
    else if(PlayerInfo[targetid][pJob] == 3) { jtext = "Whore"; }
    else if(PlayerInfo[targetid][pJob] == 4) { jtext = "Drugs Dealer"; }
    else if(PlayerInfo[targetid][pJob] == 5) { jtext = "Car Jacker"; }
    else if(PlayerInfo[targetid][pJob] == 6) { jtext = "News Reporter"; }
    else if(PlayerInfo[targetid][pJob] == 7) { jtext = "Car Mechanic"; }
    else if(PlayerInfo[targetid][pJob] == 8) { jtext = "Bodyguard"; }
    else if(PlayerInfo[targetid][pJob] == 9) { jtext = "Arms Dealer"; }
    else if(PlayerInfo[targetid][pJob] == 10) { jtext = "Car Dealer"; }
    else if(PlayerInfo[targetid][pJob] == 12) { jtext = "Boxer"; }
    else if(PlayerInfo[targetid][pJob] == 14) { jtext = "Bus Driver"; }
    else if(PlayerInfo[targetid][pJob] == 15) { jtext = "Paper Boy"; }
    else if(PlayerInfo[targetid][pJob] == 16) { jtext = "Trucker"; }
Reply
#14

thanks alot man

now, how about the other problem?
What do you think?
Reply
#15

I have never tried it before

Change the line
Code:
PlayerInfo[playerid][pModel] = 256
to
Code:
PlayerInfo[playerid][pModel] = Peds[playerid][0];
Reply
#16

I need help about yakuza gang cars and i want to make that only users in the yakuza gang can enter those cars plss help
Reply
#17

Quote:
Originally Posted by LightFight™
I have never tried it before

Change the line
Code:
PlayerInfo[playerid][pModel] = 256
to
Code:
PlayerInfo[playerid][pModel] = Peds[playerid][0];
the one under OnPlayerRequestClass?

because if so, its already there :

Code:
public OnPlayerRequestClass(playerid, classid)
{
	new string[128];
	PlayerPlaySound(playerid, 1183, 0.0, 0.0, 0.0);
	PlayerInfo[playerid][pModel] = Peds[classid][0];
	SetPlayerTeamFromClass(playerid,classid);
	SetupPlayerForClassSelection(playerid);
	
	if (classid == 1)
	{
	format(string, sizeof(string), " ~w~]]Unemployed]]~n~~r~]]Civilian]]");
	GameTextForPlayer(playerid,string,3500,5);
	}
	else
	{
	format(string, sizeof(string), "~w~]]Unemployed]]~n~~r~]]Civilian]]");
	GameTextForPlayer(playerid,string,3500,5);
	}
	return 1;
}But do i have to put every skinid in peds there?
Reply
#18

Quote:
Originally Posted by vortexxx
I need help about yakuza gang cars and i want to make that only users in the yakuza gang can enter those cars plss help
Hey Vortexxx

Code:
public IsAYakuzaCar(carid)
{
  if (PlayerInfo[playerid][pMember] == 6 || PlayerInfo[playerid][pLeader] == 6) //Yakuza
  {
	new tmpcar = GetVehicleModel(carid);
	if(tmpcar==596 || tmpcar==598) <-- Change those Numbers to the Cars that yakuza can use only.
	{

		return 1;
	}
  }
  else
  {
  SendClientMessage(playerid, COLOR_YELLOW, "You are not member of the Yakuza Organisation!");
  RemovePlayerFromVehicle(playerid);
  }
	return 0;
}
It's late so i haven't even bothered to try compile it, but it should work!
put that code anywhere you want.
Also the
Code:
if(tmpcar==596 || tmpcar==598) <-- Change those Numbers to the Cars that yakuza can use only.
Will change all the vehicles that are the model ids: 596 and 598! so if you want to only assign 3 or 4 vehicles of those models you choose, you will have to use the "Newcar" function instead of tmpcar.
if you still don't understand PM me and i'll try to help ya out!

Now my problem:

Quote:

Hey everyone, i have a kind of a slight problem at the moment, my /rentcars command doesn't seem to work anymore, but it did before.
The problem is that when i enter a rentcar(yes i have edited IsARentCar[Huh?] to 91-109) i can drive it without using /rentcars to trigger the SetPlayerControllable.

Look this is my setup for the Rentcars

Code:
Code:
		if(newcar >= 91 && newcar <= 98)
		{
			if (HireCar[playerid] != newcar)
			{
				format(string, sizeof(string), "~w~You can Rent this car~n~Cost:~g~$%d~n~~w~To rent type ~g~/rentcar~w~~n~to get out type ~r~/exit",SBizzInfo[0][sbEntranceCost]);
				TogglePlayerControllable(playerid, 0);
				GameTextForPlayer(playerid, string, 5000, 3);
			}
		}
		if(newcar >= 99 && newcar <= 109)
		{
			if (HireCar[playerid] != newcar)
			{
				format(string, sizeof(string), "~w~You can Rent this car~n~Cost:~g~$%d~n~~w~To rent type ~g~/rentcar~w~~n~to get out type ~r~/exit",SBizzInfo[1][sbEntranceCost]);
				TogglePlayerControllable(playerid, 0);
				GameTextForPlayer(playerid, string, 5000, 3);
			}
		}
And the /rentcar command.

Code:
	if(strcmp(cmd, "/rentcar", true) == 0)
	{
    if(IsPlayerConnected(playerid))
		{
			if(GetPlayerVehicleID(playerid) >= 91 && GetPlayerVehicleID(playerid) <= 109)
			{
				new hirefee = HireCost(GetPlayerVehicleID(playerid));
				if(GetPlayerVehicleID(playerid) >= 91 && GetPlayerVehicleID(playerid) <= 98)
				{
					if(SBizzInfo[0][sbProducts] == 0)
					{
						GameTextForPlayer(playerid, "~r~Out Of Stock", 5000, 1);
						return 1;
					}
					if(PlayerInfo[playerid][pSFPbiskey] == 0)
					{
						GameTextForPlayer(playerid, "~w~No charge for the boss", 5000, 3);
						TogglePlayerControllable(playerid, 1);
						return 1;
					}
					if (GetPlayerMoney(playerid) < SBizzInfo[0][sbEntranceCost])
					{
						SendClientMessage(playerid, COLOR_GRAD2, "  You dont have that much cash !");
						return 1;
					}
					GivePlayerMoney(playerid,-SBizzInfo[0][sbEntranceCost]);
					SBizzInfo[0][sbTill] += SBizzInfo[0][sbEntranceCost];
					ExtortionSBiz(0, SBizzInfo[0][sbEntranceCost]);
					SBizzInfo[0][sbProducts]--;
				}
				if(GetPlayerVehicleID(playerid) >= 99 && GetPlayerVehicleID(playerid) <= 109)
				{
					if(SBizzInfo[1][sbProducts] == 0)
					{
						GameTextForPlayer(playerid, "~r~Out Of Stock", 5000, 1);
						return 1;
					}
					if(PlayerInfo[playerid][pSFPbiskey] == 1)
					{
						GameTextForPlayer(playerid, "~w~No charge for the boss", 5000, 3);
						TogglePlayerControllable(playerid, 1);
						return 1;
					}
					if (GetPlayerMoney(playerid) < SBizzInfo[1][sbEntranceCost])
					{
						SendClientMessage(playerid, COLOR_GRAD2, "  You dont have that much cash !");
						return 1;
					}
					GivePlayerMoney(playerid,-SBizzInfo[1][sbEntranceCost]);
					SBizzInfo[1][sbTill] += SBizzInfo[1][sbEntranceCost];
					ExtortionSBiz(1, SBizzInfo[1][sbEntranceCost]);
					SBizzInfo[1][sbProducts]--;
				}
				if(HireCar[playerid] != 299)
				{
					gCarLock[HireCar[playerid]] = 0;
					UnLockCar(HireCar[playerid]);
				}
				HireCar[playerid] = GetPlayerVehicleID(playerid);
				OnPropUpdate();
				PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
				format(string, sizeof(string), "~w~We hope you enjoy ~n~the use of this car~n~To lock or unlock your car~n~type ~g~/lock~n~~w~please drive safely",hirefee);
				TogglePlayerControllable(playerid, 1);
				GameTextForPlayer(playerid, string, 5000, 3);
			}
		}
		return 1;
	}
anyone here that seems to know this problem or have a solution?
The problem appeared when i started to edit the whole gamemode from Las Venturas to San Fierro.
Please i really need some help, it's soon a new year and i promised the players that plays on it, that i'll solve the problem before 31.January! Tongue

Thanks!

Kind Regards,
Sinces Smiley

Reply
#19

anyone have an answer to my question?
Reply
#20

/makeleader /makeadmin doesntwork

please pm me if you no how to fix
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)