Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* DDDDD @ GGGGGGGGGG @ TTTTTTTTTTTTTT AAAAAAAA LL AAAAAAAA NN NN GGGGGGGGGG EEEEEEEE LL
- DDDDDDD III GGGGGGGGGG III TTTTTT TTTTTT AAA AAA LL AAA AAA NN NN GGGGGGGGGG EEE LL
- DD DD I I GG I I T T AA AA LL AA AA NN NN GG EE LL
- DD DDD I I GG I I T T AAA AAA LL AAA AAA NNNN NN GG EE LL
- DD DDD I I GG GGGGG I I T T AAAAAAAA LL AAAAAAAA NN NN NN GG GGGGG EEEEEE LL
- DD DD I I GG GG I I T T AA AA LL AA AA NN NNNN GG GG EE LL
- DDDDDDD I I GGGGGGG GG I I T T AA AA LL AA AA NN NN GGGGGGG GG EEE LL
- DDDDD III GGGGGGGGGG III TTTT AA AA LLLLLLLLL AA AA NN NN GGGGGGGGGG EEEEEEEE LLLLLLLLL
- This FS allows you to create Christmas trees in game. The trees won't appear after you type the cmd, but the function fir them will appear in your
- "scriptfiles" folder in "xmastrees.txt". Copy them under OnGameModeInit, compile and then restart your game. Then, enjoy the xmas trees. :P
- */
- #define FILTERSCRIPT
- //______________________________INCLUDES______________________________________________
- #include <a_samp>
- #include <YSI\y_commands>
- #define SCM SendClientMessage
- #define BLUE 0x04FBFBC8
- public OnFilterScriptInit()
- {
- print("\n =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=");
- print(" = DiGitaL Christmas trees creator =");
- print(" = by DiGiTaL_AnGeL =");
- print(" =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n");
- return 1;
- }
- public OnFilterScriptExit()
- {
- print("\n =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=");
- print(" = DiGitaL Christmas trees creator =");
- print(" = by DiGiTaL_AnGeL =");
- print(" =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\n");
- return 1;
- }
- YCMD:xmastree(playerid, params[], help)
- {
- if(IsPlayerAdmin(playerid))
- {
- if(help)
- {
- SCM(playerid, BLUE, "Hello! To build a Christmas tree, just type /xmastree. Create as many trees as you want.");
- SCM(playerid, BLUE, "After that, go to your 'scriptfiles' folder, and open xmastrees.txt Copy the lines there under OnGameModeInit in your GM");
- SCM(playerid, BLUE, "Compile, restart your sv, and the XMas trees will appear where you've created them. FS made by DiGiTaL AnGeL™");
- }
- else
- {
- if(isnull(params))
- {
- SCM(playerid, 0x30401099, "USAGE : /xmastree [comment]");
- }
- else
- {
- if(fexist("xmastrees.txt"))
- {
- SCM(playerid, BLUE, "Christmass tree created! Check scriptfiles\xmastrees.txt!");
- new File:xmastrees = fopen("/xmastrees.txt", io_append);
- new Float:x, Float:y, Float:z;
- new string[115];
- GetPlayerPos(playerid, x, y, z);
- format(string, sizeof(string), "\n CreateObject(19076, %f, %f, %f, 0, 0, 0, 30.0)//%s\r", x, z, y, params);
- fwrite(xmastrees, string);
- fclose(xmastrees);
- }
- }
- return 1;
- }
- return 1;
- }
- else
- {
- SCM(playerid, 0xFF0000FF, "Yiu are not an admin!");
- }
- return 1;
- }
- YCMD:help(playerid, params[], help)
- {
- if (help)
- {
- SendClientMessage(playerid, 0xFF0000AA, "Displays help about a cmd.");
- }
- else
- {
- if (isnull(params))
- {
- new str[128];
- format(str, sizeof (str), "Type \"/%s [command]\" for more help on a command.", Command_GetDisplayNamed("help", playerid));
- SendClientMessage(playerid, 0xFF0000AA, str);
- }
- else
- {
- Command_ReProcess(playerid, params, true);
- }
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement