SA-MP Forums

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

Reply
 
Thread Tools Display Modes
Old 12/06/2019, 12:48 AM   #1
SeeNN
Big Clucker
 
SeeNN's Avatar
 
Join Date: Sep 2017
Location: Craiova
Posts: 115
Reputation: 1
Default Help [Double Amount]

Hi,when a player win the event dm,server doubles the amount,and should not.

Code:
HTML Code:
if(IsPlayerConnected(killerid))
	{
	    if(ServerInfo[WhoMakeMostKillsStarted] == 1)
	    {
		   if(ServerInfo[WhoMakeMostKillsType] == 1) //ServerInfo[WhoMakesMostKillsAmmount][1] WhoMakeMostKillsType
		   {
			 if(CosminInfo[killerid][InMinigun] == 1)
			 {
               CosminInfo[killerid][MinigunKills] += 1;
			 }
			 if(CosminInfo[killerid][MinigunKills] == ServerInfo[WhoMakesMostKillsAmmount][1])
			 {
				  //------------------------------------------------------------
				  foreach(new i: Player)
				  {
				   FormatMSG(i, COLOR_ULTRARED, "[EVENT-INFO]: {43CA00}%s {00FFBF}has won the death match event!", PlayerName(killerid), CosminInfo[killerid][Coins] += ServerInfo[DMEventPrize]);
				   format(eString, sizeof(eString), "~r~~h~%s ~y~won the event!", PlayerName(killerid)), Announce(i, eString, 5000, 1), CosminInfo[i][MinigunKills] = 0;
				  }
				  //------------------------------------------------------------
                  format(ServerInfo[DMEventPrize], 15, "");
	              ServerInfo[WhoMakeMostKillsStarted] = 0;
	              ServerInfo[WhoMakeMostKillsType] = 0;
	              //------------------------------------------------------------
			  }
		    }
that is the amount
HTML Code:
 CosminInfo[killerid][Coins] += ServerInfo[DMEventPrize]
SeeNN is offline   Reply With Quote
Old 12/06/2019, 04:48 AM   #2
Koreadars
Big Clucker
 
Join Date: Mar 2019
Location: Czech Republic, Prdelákov.
Posts: 123
Reputation: 6
Default Re: Help [Double Amount]

Then give him a half of what you want to give him. If there's gonna be still 25% more, the function is used elsewhere.
Koreadars is offline   Reply With Quote
Old 13/06/2019, 12:39 AM   #3
SeeNN
Big Clucker
 
SeeNN's Avatar
 
Join Date: Sep 2017
Location: Craiova
Posts: 115
Reputation: 1
Default Re: Help [Double Amount]

Thank you. But I solved.
SeeNN 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
Same amount! Man43 Scripting Help 4 25/07/2018 12:21 PM
/td [amount] AIMigboboy Scripting Help 3 26/08/2013 12:14 AM
how to get the amount? Sascha Scripting Help 6 04/11/2011 09:28 PM
How Do I Do This? On Screen Amount Of Kills And amount Of Deaths HayZatic Help Archive 1 01/07/2011 02:26 PM
Exp amount juuleman Help Archive 11 23/11/2009 03:35 PM


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


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