AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   help with round end plugin (https://forums.alliedmods.net/showthread.php?t=75063)

refused 07-29-2008 21:17

help with round end plugin
 
what's wrong with this?


#include <amxmodx>
#include <amxmisc>

#define PLUGIN "Round end"
#define VERSION "1.0"
#define AUTHOR ""


public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)

register_logevent("logevent_round_end", 2, "1=Round_End")

.
}

public logevent_round_end()
{
set_hudmessage(178, 14, 41, -1.0, -0.4, 1, 0.5, 1.7, 0.2, 0.2,5);
show_hudmessage(id, "Round ended.^nStarting next round" );
}

Exolent[jNr] 07-29-2008 21:21

Re: help with round end plugin
 
Code:

show_hudmessage(id, "Round ended.^nStarting next round" );
should be
Code:

show_hudmessage(0, "Round ended.^nStarting next round" );

refused 07-29-2008 21:24

Re: help with round end plugin
 
Your plugin failed to compile! Read the errors below:
Welcome to the AMX Mod X 1.76-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

/home/groups/amxmodx/tmp3/phpCtSN4R.sma(14) : error 029: invalid expression, assumed zero

1 Error.
Could not locate output file /home/groups/amxmodx/public_html/websc3/phpCtSN4R.amx (compile failed).

451228 successful compiles to date.
270798 failed compiles to date.
Old compiler: 101980 compiles before decommission.
This tool by: David "BAILOPAN" Anderson.

Exolent[jNr] 07-29-2008 21:30

Re: help with round end plugin
 
remove the period "." from the plugin_init() brackets.

refused 07-29-2008 21:35

Re: help with round end plugin
 
OK, it works now. But it dissapears after 1sec, how can i make so the text will be there for about 3 seconds?

hleV 07-29-2008 21:40

Re: help with round end plugin
 
Code:

set_hudmessage(178, 14, 41, -1.0, -0.4, 1, 0.5, 1.7, 0.2, 0.2,5) // Red number is seconds


All times are GMT -4. The time now is 05:29.

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