Raised This Month: $ Target: $400
 0% 

need help! i wanna if i choose day in /daysmenu the cells open automicaly


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
wizz
Member
Join Date: Mar 2010
Old 02-24-2013 , 15:40   need help! i wanna if i choose day in /daysmenu the cells open automicaly
Reply With Quote #1

what i need to put my .sma
If i start in /daysmenu day and the cells automicaly opening
i have jailbreak server and i wanna if day starts the cells automicaly opening

HELP PLEASE

Heres the day.sma
_____________________________________________ __________
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <fun>
#pragma tabsize 0

// Plugin Vers
new const VERSION[] = "3.4";

// PREFIX
new const PREFIX[] = "[Jailbreak]";
// If you type your name below is like me typing your name on your parent's house owning document
new const AUTHOR[] = "wIzz";
// Stop Prefix
const CountSeconds = 60;
new g_iCountTime;
new day = 0;
public plugin_init()
{
register_plugin("Jailbreak DaysMenu", VERSION, AUTHOR);
register_logevent("eRoundEnd", 2, "1=Round_End");
register_logevent( "eRoundStart", 2, "1=Round_Start" );
register_clcmd( "say /day", "fwdSpawnPlayer" )
register_clcmd( "say /daysmenu", "fwdSpawnPlayer" )
}
public eRoundStart()
{
day = 0; //F*KIN script,be sure that day == 0
}
public eRoundEnd()
{
day = 0;
remove_task()
}
public ResModel(id)
{
new iPlayers[32], iNum, iPid;
get_players( iPlayers, iNum, "a" );

for( new i; i < iNum; i++ )
{
iPid = iPlayers[i];
cs_reset_user_model(iPid)
}
}
native get_simon()
public fwdSpawnPlayer(id) {
if (cs_get_user_team(id) == CS_TEAM_CT && id == get_simon()) {
if(is_user_alive(id)) {
if(day == 0) {
JBDay(id);
}
else {
client_print(id, print_chat, "Paev on juba valitud se round!");
}
}
}
else {
client_print(id, print_chat, "Sa pead olema Simon et kasutada /daysmenu!");
}
}
public Count()
{
set_hudmessage( 0 , 255 , 0 , -1.0 , 0.28 , 2 , 1.1 , 1.1 , 0.01 , 0.01 );
show_hudmessage( 0 , "Vangidel on %d sekundit aega peita (Tapa ei tohi 60 sekunudit)!" , g_iCountTime-- );
}

public JBDay(id)
{
new menu1 = menu_create("6ika Daysmenu", "menu_handler");

menu_additem(menu1, "NightCrawleri paev", "1", 0);
menu_additem(menu1, "Noa paev", "2", 0);
menu_additem(menu1, "HnS-i paev", "3", 0);
menu_additem(menu1, "Hai paev", "4", 0);

menu_setprop(menu1, MPROP_EXIT, MEXIT_ALL);
menu_display(id, menu1, 0);
}

public menu_handler(id, menu, item)
{

if( item == MENU_EXIT )
{
menu_destroy(menu);
return PLUGIN_HANDLED;
}

new data[6], iName[64];
new access, callback;

menu_item_getinfo(menu, item, access, data,5, iName, 63, callback);

new key = str_to_num(data);

switch(key)
{
case 1:
{
NightDay(id)
day = 1;
}
case 2:
{
KnifeDay(id)
day = 1;
}
case 3:
{
HideDay(id)
day = 1;
}
case 4:
{
SharkDay(id)
day = 1;
}
}
menu_destroy(menu);
return PLUGIN_HANDLED;
}
public SharkDay(id)
{
new iPlayers[32]
new iNum
new id

get_players( iPlayers, iNum )

for( new i = 0; i < iNum; i++ )
{
id = iPlayers[i]
if( !is_user_alive( id ) )
{
continue;
}
set_hudmessage( 0 , 255 , 0 , -1.0 , 0.28 , 2 , 1.1 , 1.1 , 0.01 , 0.01 );
show_hudmessage(id, "Praegu on: Hai-Paev")

client_print(id, print_chat, "%s valvurid on nuud haid, tapke nad!", PREFIX)

strip_user_weapons( id )

give_item( id, "weapon_knife" )

if (cs_get_user_team(id) == CS_TEAM_CT)
{
set_user_health(id, 150);
set_user_noclip (id, true);
}

if (cs_get_user_team(id) == CS_TEAM_T)
{
set_user_health(id, 200);
give_item(id, "weapon_ak47")
cs_set_user_bpammo( id, CSW_AK47, 200 );
give_item(id, "weapon_deagle");
cs_set_user_bpammo( id, CSW_DEAGLE, 200 );
}
}
}

public NightDay(id)
{
new iPlayers[32]
new iNum
new id

get_players( iPlayers, iNum )

for( new i = 0; i < iNum; i++ )
{
id = iPlayers[i]
if( !is_user_alive( id ) )
{
continue;
}
set_hudmessage( 0 , 255 , 0 , -1.0 , 0.28 , 2 , 1.1 , 1.1 , 0.01 , 0.01 );
show_hudmessage(id, "Praegu on: NightCrawleri-Paev")

client_print(id, print_chat, "%s Valvurid on nahtamatud. Tapke koik valvurid!", PREFIX)

strip_user_weapons(id)

set_user_footsteps(id, 1)

give_item( id, "weapon_knife" )

if (cs_get_user_team(id) == CS_TEAM_CT)
{
set_user_rendering(id, kRenderFxNone, 0, 0, 0, kRenderTransAlpha, 0 );
}

if (cs_get_user_team(id) == CS_TEAM_T)
{
set_user_health(id, 200);
give_item(id, "weapon_ak47")
cs_set_user_bpammo( id, CSW_AK47, 200 );
give_item(id, "weapon_deagle");
cs_set_user_bpammo( id, CSW_DEAGLE, 200 );
}
}
}
public KnifeDay(id)
{

new iPlayers[32]
new iNum
new id

get_players( iPlayers, iNum )

for( new i = 0; i < iNum; i++ )
{
id = iPlayers[i]
if( !is_user_alive(id) )
{
continue;
}
set_hudmessage( 0 , 255 , 0 , -1.0 , 0.28 , 2 , 1.1 , 1.1 , 0.01 , 0.01 );
show_hudmessage(id, "Praegu on: Noa-Paev")

client_print( id, print_chat, "%s Tapke uksteist nugadega!", PREFIX)

strip_user_weapons(id)
give_item( id, "weapon_knife" )
set_user_health(id, 200);
}
}

public HideDay(id)
{
set_hudmessage( 0 , 255 , 0 , -1.0 , 0.28 , 2 , 1.1 , 1.1 , 0.01 , 0.01 );
show_hudmessage(id, "Praegu on: HnSi-paev")

client_print( id, print_chat, "%s Vangidel on 60 sekundit aega peita!", PREFIX)

strip_user_weapons(id)
give_item( id, "weapon_knife" )
if (cs_get_user_team(id) == CS_TEAM_CT)
{
set_user_health(id, 500);
}
g_iCountTime = CountSeconds;
set_task( 1.0 , "Count" , _ , _ , _ , "a" , g_iCountTime );
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1048\\ f0\\ fs16 \n\\ par }
*/

Last edited by wizz; 02-24-2013 at 17:12.
wizz is offline
 



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

Forum Jump


All times are GMT -4. The time now is 21:48.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode