Raised This Month: $51 Target: $400
 12% 

Blockear Comandos


  
 
 
Thread Tools Display Modes
Author Message
chetah
Senior Member
Join Date: Jan 2013
Location: BangBros
Old 04-06-2013 , 21:48   Blockear Comandos
#1

Hola, Nesecito ayuda, un ej o si me dicen como blockear un comando por ej
el impulse 100 para la linterna
cuando empieza la ronda que pasen los 20 seg , estando prendida la linterna
y despues la apage y al precionar la [F] no se prenda hastaa que pasen los 20 seg

Si no es mucho
Gracias
__________________
Minecraft Mod: | %15
"Tomorrowland <3"
chetah is offline
Manu127
Veteran Member
Join Date: Jul 2010
Location: Argentina
Old 04-06-2013 , 23:09   Re: Blockear Comandos
#2

Quote:
Originally Posted by chetah View Post
Hola, Nesecito ayuda, un ej o si me dicen como blockear un comando por ej
el impulse 100 para la linterna
cuando empieza la ronda que pasen los 20 seg , estando prendida la linterna
y despues la apage y al precionar la [F] no se prenda hastaa que pasen los 20 seg

Si no es mucho
Gracias
La manera mas facil seria usar engine, registrando el impulse... Y ahi checkeas lo que tengas que checkear.

Un impulse no se puede bloquear como cualquier comando (ej: say).
__________________
Manu127 is offline
Send a message via MSN to Manu127 Send a message via Skype™ to Manu127
chetah
Senior Member
Join Date: Jan 2013
Location: BangBros
Old 04-06-2013 , 23:18   Re: Blockear Comandos
#3

Me darias un ejemplo? . Fuck you me ayudo pero no funciono lo iso con engine. Porfa que lo nesecito a mi se me ocurria otra cosa pero como nose puede blockear
__________________
Minecraft Mod: | %15
"Tomorrowland <3"
chetah is offline
BlackFur
BANNED
Join Date: Apr 2012
Location: RCL
Old 04-06-2013 , 23:33   Re: Blockear Comandos
#4

IMPULSE_FLASHLIGHT seria el 100

PHP Code:
register_forward(FM_CmdStart"fw_CmdStart")

public 
fw_CmdStart(idhandle)
{
    if (!
g_isalive[id])
        return;

    if (!
g_zombie[id] && !g_survivor[id] && !g_sniper[id] && (g_zombie[id] || !g_cached_customflash))
        return;
    
    if (
get_uc(handleUC_Impulse) != IMPULSE_FLASHLIGHT)
        return;
    
    
set_uc(handleUC_Impulse0)
    
    if (!
g_zombie[id] && !g_survivor[id] && !g_sniper[id] && g_flashbattery[id] > && get_gametime() - g_lastflashtime[id] > 1.2)
    {
        
g_lastflashtime[id] = get_gametime()
        
        
g_flashlight[id] = !(g_flashlight[id])
        
        
// Play flashlight toggle sound
        
emit_sound(idCHAN_ITEMsound_flashlight1.0ATTN_NORM0PITCH_NORM)
        
        
// Update flashlight status on the HUD
        
message_begin(MSG_ONEg_msgFlashlight_id)
        
write_byte(g_flashlight[id]) // toggle
        
write_byte(g_flashbattery[id]) // battery
        
message_end()
        
        
// Remove previous tasks
        
remove_task(id+TASK_CHARGE)
        
remove_task(id+TASK_FLASH)
        
        
// Set the flashlight charge task
        
set_task(1.0"flashlight_charge"id+TASK_CHARGE__"b")
        
        
// Call our custom flashlight task if enabled
        
if (g_flashlight[id]) set_task(0.1"set_user_flashlight"id+TASK_FLASH__"b")
    }


Last edited by BlackFur; 04-06-2013 at 23:33.
BlackFur is offline
DJHD!
Veteran Member
Join Date: Dec 2009
Location: Santiago, Chile
Old 04-07-2013 , 00:33   Re: Blockear Comandos
#5

El no dijo que era para ZP.
__________________
Quote:
Originally Posted by XINLEI View Post
Porque rocccos trata de ser el metalicross que nunca va a poder ser.
DJHD! is offline
Send a message via MSN to DJHD!
baneado
Veteran Member
Join Date: Dec 2012
Location: amxmodx-es.com
Old 04-07-2013 , 08:54   Re: Blockear Comandos
#6

Quote:
Originally Posted by DJHD! View Post
El no dijo que era para ZP.
todo se puede adaptar
baneado is offline
DJHD!
Veteran Member
Join Date: Dec 2009
Location: Santiago, Chile
Old 04-07-2013 , 12:36   Re: Blockear Comandos
#7

y si el no sabe adaptar?
__________________
Quote:
Originally Posted by XINLEI View Post
Porque rocccos trata de ser el metalicross que nunca va a poder ser.
DJHD! is offline
Send a message via MSN to DJHD!
r0ma
Senior Member
Join Date: Apr 2012
Location: Great Tomb of Nazarick
Old 04-07-2013 , 12:49   Re: Blockear Comandos
#8

para que usar CMDStart si puede usar register_impulse
__________________
Discord:FluffyDeveloper#4753
Github: https://github.com/francoromaniello
AMX-ES: https://amxmodx-es.com/r0ma'
r0ma is offline
Send a message via MSN to r0ma
chetah
Senior Member
Join Date: Jan 2013
Location: BangBros
Old 04-07-2013 , 16:21   Re: Blockear Comandos
#9

Alguna otra forma? tengo el register_impulse
pero nose hoockearlo?
__________________
Minecraft Mod: | %15
"Tomorrowland <3"
chetah is offline
Kiske
Veteran Member
Join Date: May 2009
Old 04-07-2013 , 19:23   Re: Blockear Comandos
#10

PHP Code:
register_impulse(100"impulse_Flashlight");

public 
impulse_Flashlight(const id)
    return 
PLUGIN_HANDLED
Con eso no la puede prender nadie.
__________________


Last edited by Kiske; 04-07-2013 at 19:23.
Kiske is offline
Send a message via Skype™ to Kiske
 



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 20:09.


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