Raised This Month: $ Target: $400
 0% 

include set_lights("a") in a set_task


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Obbin
Senior Member
Join Date: Mar 2005
Location: 192.168.1.3
Old 08-27-2005 , 06:55   include set_lights("a") in a set_task
Reply With Quote #1

how do i include set_lights("a") in an set_task?

Code:
new freezetime = get_cvar_num("mp_freezetime") set_task(freezetime,/*what to put here*/)
Obbin is offline
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 08-27-2005 , 07:03  
Reply With Quote #2

What do you want it to do?
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
Obbin
Senior Member
Join Date: Mar 2005
Location: 192.168.1.3
Old 08-27-2005 , 07:20  
Reply With Quote #3

when an new round starts (event_roundstart), everything should become black after the freezetime has ran out!

did you understand now or is my english so bad
__________________
Sig(h)!
Obbin is offline
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 08-27-2005 , 07:26  
Reply With Quote #4

In your plugin_init:
Code:
register_logevent("new_round",2,"0=World triggered","1=Round_Start");
That is called right after freezetime ends.

Now, just make a function like this:
Code:
public new_round() {     set_lights("a"); }
Note: You can change new_round to whatever you'd like.
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
Obbin
Senior Member
Join Date: Mar 2005
Location: 192.168.1.3
Old 08-27-2005 , 11:02  
Reply With Quote #5

then why does this not work??

Code:
#include <amxmodx> #include <engine> public plugin_init() {    register_plugin("dark", "11", "Rockstar")    register_logevent( "Event_RoundStart", 2, "0=World triggered", "1=Round_Start" );    register_logevent( "Event_RoundEnd",   2, "0=World triggered", "1=Round_End" ); } public Event_roundstart(){ set_lights("a") return PLUGIN_CONTINUE } public Event_RoundEnd(){ set_lights("#OFF") return PLUGIN_CONTINUE } public client_putinserver(){ set_lights("a") return PLUGIN_CONTINUE }
__________________
Sig(h)!
Obbin is offline
JuXas
Member
Join Date: Jul 2005
Location: Panavezys, Lithuania
Old 08-27-2005 , 11:16  
Reply With Quote #6

Code:
public Event_roundstart() {
Code:
public Event_RoundStart() {
__________________
-- Nothing Here --
JuXas is offline
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 08-27-2005 , 11:16  
Reply With Quote #7

Code:
register_logevent( "Event_RoundStart", 2, "0=World triggered", "1=Round_Start" );
Code:
public Event_roundstart(){
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
XxAvalanchexX
Veteran Member
Join Date: Oct 2004
Location: abort73.com
Old 08-27-2005 , 15:48  
Reply With Quote #8

What they're saying is that function names are case-sensitive, and the case is different in register_logevent and the actual function's name.
__________________
No longer around. Thanks your support, everyone! As always:
THIS ONES FOR YOU
3000 PTS
XxAvalanchexX is offline
v3x
Veteran Member
Join Date: Oct 2004
Location: US
Old 08-27-2005 , 22:48  
Reply With Quote #9

Seems as though he posted the answer the same time as I did.
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116

I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.
v3x is offline
Reply



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 14:26.


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