Jump to content

Forums Announcement

Read-Only Mode for Announcements & Changelogs

Dear Survivors, we'd like to inform you that this forum will transition to read-only mode. From now on, it will serve exclusively as a platform for official announcements and changelogs.

For all community discussions, debates, and engagement, we encourage you to join us on our social media platforms: Discord, Twitter/X, Facebook.

Thank you for being a valued part of our community. We look forward to connecting with you on our other channels!

Stay safe out there,
Your DayZ Team

Sign in to follow this  
Heisen99

OnEvent issue.

Recommended Posts

18 hours ago, Heisen99 said:

adPAlgv.png

Not showing up in the logs when the event should be triggered.

override void OnEvent(EventType eventTypeId, Param params){
	super.OnEvent(eventTypeId,params);	
	if(eventTypeId == ChatMessageEventTypeID) then
		ChatMessageEventParams chat_params = ChatMessageEventParams.Cast(params);
		if(chat_params.param1 != "")then
			print(chat_params.ToString());
		end
	end
}

something like this works?
untested tho I'm at work (very busy :P)

 

Share this post


Link to post
Share on other sites
3 hours ago, kaspar rave said:

override void OnEvent(EventType eventTypeId, Param params){
	super.OnEvent(eventTypeId,params);	
	if(eventTypeId == ChatMessageEventTypeID) then
		ChatMessageEventParams chat_params = ChatMessageEventParams.Cast(params);
		if(chat_params.param1 != "")then
			print(chat_params.ToString());
		end
	end
}

something like this works?
untested tho I'm at work (very busy :P)

 

That's great however a bit of explanation on where you found the chatMessageEventParams..

Share this post


Link to post
Share on other sites

I save almost every script I come across here to learn more commands.

This is taken from somebody else's script.

But the question is does it work? did'nt have time to test i can acces my server but can't join to test...

 

I'm waitin till 1.0 before scripting again because updating is annoying

Edited by kaspar rave

Share this post


Link to post
Share on other sites
Sign in to follow this  

×