SA-MP Forums Archive
Script Request Thread #5 - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Script Request Thread #5 (/showthread.php?tid=187229)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34


Re: Script Request Thread #5 - Zonoya - 10.09.2011

ok do you have a server ill come in it and we can make the saves together


Re: Script Request Thread #5 - Ehab1911 - 11.09.2011

Quote:
Originally Posted by Zonoya
Посмотреть сообщение
ok do you have a server ill come in it and we can make the saves together
Yeah , I'll PM you my E-Mail ^_^


Re: Script Request Thread #5 - kodiak - 11.09.2011

Quote:
Originally Posted by Darnell
Посмотреть сообщение
May I know the enum for the faction, which is CNN ?
....................9........................



Re: Script Request Thread #5 - Gh0sT_ - 11.09.2011

Quote:
Originally Posted by Gh0sT_
Посмотреть сообщение
TimestampToDate

it would convert mktime value to date(e.g: 2011-09-02 12:12:12)

I have one function, but its outdated I think, created in 2009

mktime function:

pawn Код:
stock mktime(hour, minute, second, day, month, year) // By: Y_Less
{
    static const days_of_month[12] =
    {
        0 * 86400, 31 * 86400, 59 * 86400,
        90 * 86400, 120 * 86400, 151 * 86400,
        181 * 86400, 212 * 86400, 243 * 86400,
        273 * 86400, 304 * 86400, 334 * 86400
    };
    static
        lMonth, lYear, lMonthS, lYearS;
    if (year != lYear)
    {
        year -= 1970;
        lYearS = year * 31536000;
        lYearS += 86400 * (year / 4);
        year += 70;
        lYearS -= (year / 100) * 86400;
        year += 300;
        lYearS += (year / 400) * 86400;
        year += 1600;
        lYear = year;
    }
    if (month != lMonth)
    {
        --month;
        lMonthS = days_of_month[month];
        if (IsLeapYear(year) && month >= 2)
        {
            lMonthS += 86400;
        }
        lMonth = month + 1;
    }
    day = (day - 1) * 86400;
    hour = (hour - (0 TIME_ZONE)) * 3600;
    minute = minute * 60;
    return lYearS + lMonthS + day + hour + minute + second;
}
anyone?


Re: Script Request Thread #5 - kodiak - 11.09.2011

I'm need command for CNN "/live" in zcmd. Can Anyone make me this command please.

ID of organisaton (CNN) is 9


Re: Script Request Thread #5 - wouter0100 - 11.09.2011

I have 2 Idea's.

Quote:

A nice vehicle system.
Commands
/v (help command)
/v buy [modelid] [color 1] [color 2] (the buy command and when no modelid,color it shows the list.(the vehicles that he can buy))
/v buypark (a park place you need to buy, now everything saves, car color, paintjob etc., with the spawned vehicle)
/v park (parks the car, destroyvehicle, need to be on his parking place, when he isnt there a redmarker sets on it.)
/v get [carid] (the vehicle spawns on his parking place)
/v find (a red marker on the spawned car)
/v plate [plate] (change the plate of the spawned car)
/v lock (locks/unlocks when you are at the car.)
/v list (shows all your vehicles: carid - name - sellprice)
/v sell ( sells the spawned car for the price/2 ore something)
/v sellto [id/name] [price] (sells a car to a player /accept vehicle to accept.)

Details;
Unlimited vehicles (A player can own unlimited vehicles)
Carid is starts by 0 (its not the spawn id of the vehicle just the how much cars you have in a count.)
Max 1 car spawned
Saves every thing (Paintjob etc.).
Mysql

Quote:

One function
GetSecondsTimer(timer);
That gives how much seconds the timer need to finish.
example
a player type /timer, then starts a timer of 10 seconds, and after the 10 seconds, it sends a message to the player like ''Timer finished'
When the player type /time the player see how much seconds he need to wait before the player get the message. (Timer finished)




Re: Script Request Thread #5 - kodiak - 11.09.2011

Quote:
Originally Posted by [HLF]Southclaw
Посмотреть сообщение
How do you expect people to know what you are talking about?
And how do you expect someone to write a command to implement into your script, without giving them any information on variables and symbols you use in your script.
And what is the command supposed to do?
You don't see in any script command /live for CNN :O


Re: Script Request Thread #5 - persia_gamer - 11.09.2011

is there any script that when you type /tele a dialog open and it teleports to someplaces like LS,LV,AA air?


Re: Script Request Thread #5 - SpaMaster - 11.09.2011

I need Boat OwnerShip. If someone have it ?


Re: Script Request Thread #5 - Saw® - 11.09.2011

Hi , i want to creat the command /changepass [old pass] [New pass] with dutils+dudb

and i have no kind of idea how to do it , so if someone can help me, and explain to me each line(what does each line do)

Thank you for Helping me .


Re: Script Request Thread #5 - GTA-Roleplay - 12.09.2011

I want a quiz when one joins the server, you get to answer questions as they answer wrong you get kickad.typ which is what Meta Gaming Means. someone who has it who can provide it?
plz help me ?


Re: Script Request Thread #5 - Ecstacy - 13.09.2011

hey guys any one can delete the registration system from my gamemode? i have lux admin and i dont need gamemodes registration system tell me to send you the script to remove it


Re: Script Request Thread #5 - Jafet_Macario - 13.09.2011

Quote:
Originally Posted by GTA-Roleplay
Посмотреть сообщение
I want a quiz when one joins the server, you get to answer questions as they answer wrong you get kickad.typ which is what Meta Gaming Means. someone who has it who can provide it?
plz help me ?
Here you go: http://pastebin.com/WBEmWz9s


Re: Script Request Thread #5 - Ecstacy - 13.09.2011

Quote:
Originally Posted by Ecstacy
Посмотреть сообщение
hey guys any one can delete the registration system from my gamemode? i have lux admin and i dont need gamemodes registration system tell me to send you the script to remove it
nobody can help?! (

+ that,im looking for 1 other thing... is there any vehicle dialog? that when we type /v in game a dialog pop up to select a vehicle?


Re: Script Request Thread #5 - knackworst - 13.09.2011

Can anyone makE a callback :
OnGameTextTimeEnds
Wich is called when a gametext timer hits 0 , I think its very usefull tbh :/


Re: Script Request Thread #5 - KoczkaHUN - 13.09.2011

pawn Код:
public OGTTE_GameTextForPlayer(playerid, const string[], time, style)
{
    SetTimerEx("OnGameTextTimeEndsForPlayer", time, 0, "i", playerid);
    return GameTextForPlayer(playerid, string, time, style);
}
public OGTTE_GameTextForAll(const string[], time, style)
{
    SetTimer("OnGameTextTimeEnds", time, 0);
    return GameTextForPlayer(string, time, style);
}
#if defined _ALS_GameTextForPlayer
    #undef GameTextForPlayer
#else
    #define _ALS_GameTextForPlayer
#endif
#if defined _ALS_GameTextForAll
    #undef GameTextForAll
#else
    #define _ALS_GameTextForAll
#endif

forward OGTTE_GameTextForPlayer(playerid, const string[], time, style);
forward OGTTE_GameTextForAll(const string[], time, style);
forward OnGameTextTimeEndsForPlayer(playerid);
forward OnGameTextTimeEnds();

public OnGameTextTimeEndsForPlayer(playerid)
{
    // gets called if a GameTextForPlayer timeouts
    return 1;
}

public OnGameTextTimeEnds()
{
    // gets called if a GameTextForAll timeouts
    return 1;
}



Re: Script Request Thread #5 - knackworst - 13.09.2011

Wow thats amazing! You shud make an include and post on the forums
But what are the defines for?


Re: Script Request Thread #5 - KoczkaHUN - 13.09.2011

I don't think it is useful at all, but you can release it if you want.

those defines are part of the Advanced Library System. Don't edit them, or they will not work.
If you want to make an include of it, remove the two "public" functions at the bottom and copy-paste the rest into a file in your includes folder.


Re: Script Request Thread #5 - Ecstacy - 13.09.2011

Quote:
Originally Posted by Ecstacy
Посмотреть сообщение
nobody can help?! (

+ that,im looking for 1 other thing... is there any vehicle dialog? that when we type /v in game a dialog pop up to select a vehicle?
please somebody answer me


Re: Script Request Thread #5 - knackworst - 13.09.2011

For me i is very usefull :P anyways is it possible to do with textdraw?
Like:
TextdrawSetTimerString(playerid,text:text,time)
Wich sets a timer for a textdraw string to change into " "
And OnTextDrawSetStringTimerEnd
Wich gets called when the timer from the first funct hits 0
this way its easy to make handy td's