Trying to make hitmark script for 1.3 / 1.4

S_hift

Veteran X
Veteran XX
Code:
function Hitmark::OnSound(%Sound) {
   if (Match::String(%Sound, "~button4")){
      newEvent("Hitmark::OnSound" @ %Sound("Hitmark.bmp", 512, 384, 100, 0.8)
   }
}




Not sure were to go from here
PicardFacepalm.png

Some help would be appreciate also I'm new to this whole scripting deal, but I'm willing to learn. Yes I know it probably looks retarded to the more experienced eyes.


also the goal for this is to make a script that works on 1.3 and 1.4 with very little editing. Preferably just changing hitmark.bmp to hitmark.png


I'll explain further what I'm trying to do. The server I play in is modified to play a sound everytime I hit someone, kind of like the mid air in the LT server. I'm trying to detect that sound (button4.wav) and have tribes draw the desired image onto the center of my screen.
 
Last edited:
update. Credit to perrinoia

Code:
function onClientMessage(%client, %msg)
{
   if(%client)
      $lastClientMessage = %client;

   // filter messages here
      if(%msg == "~wButton3.wav")
         echo("Blink crosshair or whatever.");
   return true;
}

this is basically just the first half of the script. instead of "echo" would write something like Draw("hitmark.bmp, 800, 600, idk, 0.8"); return true" }
 
Last edited:
Back
Top