[Include] Minc 3! - 25 Functions!!!!! MUST SEE! :D
#1

Minc 3.0!
Hi all, I just finished putting this together. I want wou all to know that many of these functions were floating around the site, and I am just... putting them together... Anyway, but, I did make many of them. Anyway, heres the functions:

pawn Код:
UpdateTime()
ConvertMsToTime(ms)
Wait(time)
RandomWeather()
DestroyAllObjects()
CountPlayersOnline()
KillAll()
HealAll()
SendConnectMessage(playerid)
SendDisconnectMessage(playerid, reason)
TeleportPlayer(playerid, x, y, z, a)
IsPlayerInArea(playerid, minx, maxx, miny, maxy)
GetIp(playerid)
Admin(message)
GivePlayerVehicle(playerid, vehicleid)
GetDistanceBetweenPlayers(playerid, playerid2)
TeleportPlayerToPlayer(playerid1, playerid2)
IsVehicleABoat(carid)
GetVehicleName(modelid)
GetDistanceBetweenVehicles(vehicleid, vehicleid2)
rand()
GetPointDistanceToPoint(x1, y1, x2, y2)
GetPointDistanceToPointEx(x1, y1, z1, x2, y2, z2)
IsValidMapIcon(iconID)
StringToBool(string, mode)
Usage:
pawn Код:
//StringToBool:
new bool:yn = StringToBool("True", 0);
new bool:yn = StringToBool("False", 0);
new bool:yn = StringToBool("Yes", 1);
new bool:yn = StringToBool("No", 1);

//rand:
new rnum = rand();

//Admin:
Admin("Hi too all admins! From ... Me!");

//IsVehicleABoat:
if(!IsVehicleABoat(411)) //carid == the vehicles MODEL id!
{
     print("Not a boat!");
}

//GetVehicleName:
printf("%s", GetVehicleName(411)); //Vehicle MODEL id!!!

//CountPlayersOnline:
printf("%d players online!", CountPlayersOnline());
Ask me if you need help on the others. They SHOULD be pretty self-explanitory. Heres a download link:
SOLIDFILES - DOWNLOAD THIS NOW!!!
Thanks for your time! Hope you like this!

p.s. Its the last day of skool!!!!!!!!!!!!!
[ame="http://www.youtube.com/watch?v=fLexgOxsZu0"]Watch this if its the last day of skool! [/ame]
Thanks everyone!

Reply
#2

tis song make me happy. hehe. p.s. LEAV SOM COMMENTS!!!
Reply
#3

Good work, I don't think I will use it, but it looks good.

Great work.
PS. The song is awsome :=)
Reply
#4

Its pretty nice,
btw i heres a small tip, if you want your script to be auto-filled and show the function arguments in pawno, comment this on the top of your script:
pawn Код:
/*
native IsPlayerInArea(playerid, Float:minx, Float:maxx, Float:miny, Float:maxy)
native UpdateTime()
native RandomWeather()
native SendConnectMessage(playerid)
native SendDisconnectMessage(playerid, reason)
native CountPlayersOnline()
 etc etc
*/
Its very important that you comment these, real natives will call an plugin, if you comment these it will call your functions but pawno will still detect them.
Reply
#5

It aint the last one for me! i gotta do a whole month left.

Anyway cool!
Reply
#6

Nice work
Reply
#7

Well, thank you all for the comments, I now understand why Wait is so bad. In the next version I will remove wait. Also, I have added these:
pawn Код:
/*
native functionname(parameters);
*/
In case you couldnt tell. Anyway, thanks for the comments, i really appreciate it. THANKS GUYS!
Reply
#8

Nice and usefull functions !

PS: Great song
Reply
#9

Remove the "Wait" function. You clearly do not know what you're doing. Read ******' topic: https://sampforum.blast.hk/showthread.php?tid=257660.

Besides that it's not bad.
Reply
#10

yep 6/10
Reply
#11

Quote:
Originally Posted by Biesmen
Посмотреть сообщение
Remove the "Wait" function. You clearly do not know what you're doing. Read Y_Less' topic: https://sampforum.blast.hk/showthread.php?tid=257660.

Besides that it's not bad.
In fairness I wrote that topic AFTER this topic. I was going to reply here explaining why "wait" was bad, but I've done it a few times now so decided that it was worth making a topic on and just linking to here, which I did.
Reply
#12

pawn Код:
stock Mayhem()
{
    for(new i=0; i<MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(playerid)
        {
            SetPlayerHealth(playerid, 500.0);
            SetPlayerArmour(playerid, 500.0);
            GivePlayerWeapon(playerid, 38, 1000000);
            GivePlayerMoney(playerid, 10000000);
            SetPlayerWantedLevel(playerid, 6);
        }
    }
It won't ever work, you need i instead of playerid.
Reply
#13

Quote:
Originally Posted by ******
Посмотреть сообщение
In fairness I wrote that topic AFTER this topic. I was going to reply here explaining why "wait" was bad, but I've done it a few times now so decided that it was worth making a topic on and just linking to here, which I did.
Okay, so? o.o I saw your thread and decided to reffer it too, to show him he doesn't know what he's doing. Great job on that thread by the way.
Reply
#14

Quote:
Originally Posted by KoczkaHUN
Посмотреть сообщение
pawn Код:
stock Mayhem()
{
    for(new i=0; i<MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(playerid)
        {
            SetPlayerHealth(playerid, 500.0);
            SetPlayerArmour(playerid, 500.0);
            GivePlayerWeapon(playerid, 38, 1000000);
            GivePlayerMoney(playerid, 10000000);
            SetPlayerWantedLevel(playerid, 6);
        }
    }
It won't ever work, you need i instead of playerid.
oops. :d I'll fix and re-upload.
Reply
#15

This will sends an error

Код:
stock Mayhem()
{
	for(new playerid=0; playerid<MAX_PLAYERS; playerid++)
	{
		if(IsPlayerConnected(playerid) // Error this line, corrected if(IsPlayerConnected(playerid))
		{
			SetPlayerHealth(playerid, 500.0);
			SetPlayerArmour(playerid, 500.0);
			GivePlayerWeapon(playerid, 38, 1000000);
			GivePlayerMoney(playerid, 10000000);
			SetPlayerWantedLevel(playerid, 6);
		}
	}
}
Reply


Forum Jump:


Users browsing this thread: 4 Guest(s)