Rust customized "ToastMessage"/"Popup-Message"?

Hi there,

i was wondering if someone could help me.

I wasn't coding rust plugin(s) a while, just came back to game now and i saw where a server had a customized "toast message".

With toast message i mean like if you collect something, eat something etc.



I checked the methods, and found following:

public void ShowToast(GameTip.Styles style, Translate.Phrase phrase, params string[] arguments);

is this the right one? If so, can someone give me an example please, since i don't know which plugin is using this to get inspired.

Thank you!

While waiting for a reply i found following "

gametip.showgametip" as playercommand, is there something similar for the collectablemessage? I can't find any list and i'm wondering how other knows that.

They are likely using some custom UI in the same style as the native UI to create the illusion that it is a custom tooltip.

The GiveItem method also shows a note like that.

Look https://codefling.com/plugins/custom-status-framework


Merged post

If you need like this:

KenkIKdL4p2EiXg.jpg

Use:

player.SendConsoleCommand("gametip.showtoast_translated", 1, "", "Message here!"); - warning gametip (time live ~4s)
player.SendConsoleCommand("gametip.showtoast_translated", 2, "", "Message here!"); - info gametip (time live ~5s)

player.SendConsoleCommand("gametip.showgametip", Message here!"); - enable info gametip (time live )
player.SendConsoleCommand("gametip.hidegametip"); - disable any gametip