<aside> 📦 ASSTLIB.acs
</aside>
<aside> âš¡ void BasicImageDisplay(str image, int id, int x, int y)
</aside>
This function just draws a basic given image at a given x and y coordinate of the screen.
image
: String - The name of the graphic to draw (Ex. "RUSJGO"
).id
: Int - Internally this function uses HudMessage
which requires an ID, so you should pass a unique HudMessage
ID using [Get_And_Inc_AssistDisplayID](<https://mm8bdm.notion.site/Get_And_Inc_AssistDisplayID-00a4e858bdcd4550ab346852f18050be>)
. Alternatively, you can supply your own static ID, just make sure that it is unique!x
: Fixed - The X coordinate of the screen to draw the image at.y
: Fixed - The Y coordinate of the screen to draw the image at.<aside>
💡 **Note: Again, because this function is implemented using HudMessage
internally, the X and Y coordinates here abide by the rules of SetHudSize
as that function does.
If you’re using [Get_AssistDisplayBar_X](<https://mm8bdm.notion.site/Get_AssistDisplayBar_X-b1024a0668234f129edaf36a126c7b81>)
and [Get_AssistDisplayBar_Y](<https://mm8bdm.notion.site/Get_AssistDisplayBar_Y-031bc9a7a82f448fbb4797839a35c692>)
, this is not much of a concern to you, because they already give coordinates assuming that SetHudSize(320, 200, 0)
has been used, but it is good to know for specifying your own coordinates!**
</aside>
Below is a truncated version of MM8BDM’s main assist item assist display script which only has Rush Jet which will show every function being used.
#library "COREAST"
#include "zcommon.acs"
#include "DTADD.acs"
Script "core_trunc_assists_define" OPEN CLIENTSIDE
{
DefineAssistDisplay("core_trunc_assists");
}
#include "ASSTLIB.acs"
Script "core_trunc_assists" (int cam) CLIENTSIDE
{
if(AssistDisplayBar_On()) {
SetHudSize(320,200,0);
if(CheckActorInventory(cam,"RushJetCounter")>0) {
int pos = Get_And_Inc_AssistBarCount();
int x = Get_AssistDisplayBar_X(pos);
int y = Get_AssistDisplayBar_Y(pos);
str img = "RUSJGO";
if(CheckActorInventory(cam, "PlayerPropertyGrounded") > 0) img = "RUSJGON";
if(CheckActorInventory(cam, "RushJetCounter") <= 1 && Timer() % 8 <= 3) img = "TNT1A0";
BasicImageDisplay(img,Get_And_Inc_AssistDisplayID(),x,y);
DrawBasicBarAndNumber(
"ASTBARPR","ASSTBARE",
"ASTVARPR","ASSTVARE",
x,y,
Get_And_Inc_AssistDisplayID(),Get_And_Inc_AssistDisplayID(),Get_And_Inc_AssistDisplayID(),
CheckActorInventory(cam,"RushJetCounter"),
CheckActorInventory(cam,"AssistNumberFlag")>0,
CheckActorInventory(cam,"RushJetCounter")
);
}
}
}