Drake Leet Scripter pl0x
Guest
|
Post by Drake Leet Scripter pl0x on Mar 30, 2009 15:10:02 GMT -5
//--------------------------------------------------------------------- // Filename: Console K-Sat // Compiler: Drake~{DWR}-;) // Source: C&D Script File by Gen. Raven [M.I.B.] // for the K-Sat, slightly modified by Drake~{DWR}-;) //--------------------------------------------------------------------- // // Instructions: // - Open Console in a game and type: // exec("consoleksat.cs"); // - Afterwards, use playerList(); to find a player. // - Use the following command: // focusserver();ksat(2049);focusclient(); //--------------------------------------------------------------------- $satsafe = true;
function ksat(%player) { if(%player != "") { if($satsafe == true) {
$satsafe = false; %vehicleId = playerManager::playerNumToVehicleId(%player); %target = getHudName(%vehicleId); %x = getPosition(%vehicleId, x); %y = getPosition(%vehicleId, y); %z = getTerrainHeight(%x, %y); say(0,83,"<F5>WARNING: K-SAT Target Lock: " @ %target @ "<F5>.","warn_missl_lock.wav"); schedule("flushChannel(83);", 0.65); %beam = newObject("beam", StaticShape, "fx_orbeam.DTS"); setPosition(%beam, 0, 0, getTerrainHeight(0, 0) - 10000); setHudTimer(10,-1,"K-SAT Aligning:", 2); playSound(0, "sfx_quake.wav", IDPRF_2D); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",3); schedule("setPosition(" @ %beam @ ", " @ %x @ ", " @ %y @ ", " @ %z @ "-100);",5); schedule("playSound(0, \"plasma3.wav\", IDPRF_2D);",5); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",6); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",7); schedule("dropPod(" @ %x @ ", " @ %y @ ", " @ %z+800 @ ", " @ %x @ ", " @ %y @ ", " @ %z @ ");",8); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",8); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",9); schedule("playSound(0, \"sfx_prob.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_fog.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_thunder1.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_thunder2.wav\", IDPRF_2D);",10); schedule("damageArea("@ %vehicleId @",0,0,0,100,999999999);",10.5); schedule("damageArea("@ %vehicleId @",75,0,0,100,999999999);",10.5); schedule("damageArea("@ %vehicleId @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %vehicleId @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %vehicleId @", 0, 0, 0, 100, 999999999);",10.5); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",12); schedule("playSound(0, \"sfx_thunder1.wav\", IDPRF_2D);",12); schedule("deleteObject(" @ %beam @ ");",14); schedule("echo(\"Beam deleted.\");", 14); schedule("$satsafe = true;", 16); } else { echo("Anti K-Sat Spam Script enabled."); } } else if((%player == "") || (%player < 2049)) { echo("Please input a valid player number."); } }
Save the above as consoleksat.cs The command only works for console and will not work for scripts that involve the use of "function vehicle::onScan" or whatever. T'was requested to be console like - and so it is.
Requested by Angel - the evil little girl that is far from being an Angel.
Drake the almighty God of scripting bids thee farewell? o.O
|
|
Drake Leet Scripter pl0x
Guest
|
Post by Drake Leet Scripter pl0x on Mar 31, 2009 15:16:12 GMT -5
//--------------------------------------------------------------------- // Filename: Console K-Sat // Compiler: Drake~{DWR}-;) // Source: C&D Script File by Gen. Raven [M.I.B.] // for the K-Sat, slightly modified by Drake~{DWR}-;) //--------------------------------------------------------------------- // // Instructions: // - Open Console in a game and type: // exec("consoleksat.cs"); // - Afterwards, use playerList(); to find a player. // - Use the following command for console use: // focusserver();ksat(2049, "player");focusclient(); // - For function use, use the "other" input: // ksat(%playervar, "other"); // - It is possible to make a different style input, // but the "other" input works universally for // scanning, LTADS or whatever other means possible. // Examples provided. //--------------------------------------------------------------------- $satsafe = true;
echo("function ksat(%player, %style) {}"); echo("Command Line: focusserver(); ksat(player#, \"player\"); focusclient();");
function ksat(%player, %style) { if(%style == "player") { if(%player != "") { if($satsafe == true) {
$satsafe = false; %vehicleId = playerManager::playerNumToVehicleId(%player); %target = getHudName(%vehicleId); %x = getPosition(%vehicleId, x); %y = getPosition(%vehicleId, y); %z = getTerrainHeight(%x, %y); say(0,83,"<F5>WARNING: K-SAT Target Lock: " @ %target @ "<F5>.","warn_missl_lock.wav"); schedule("flushChannel(83);", 0.65);
// Creates a new beam object where in the C&D Files // a beam on the map was teleported to an area of a // strike. Simple and easy to adjust when/if wanted. %beam = newObject("beam", StaticShape, "fx_orbeam.DTS"); setPosition(%beam, 0, 0, getTerrainHeight(0, 0) - 10000); setHudTimer(10,-1,"K-SAT Aligning:", 2); playSound(0, "sfx_quake.wav", IDPRF_2D); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",3); schedule("setPosition(" @ %beam @ ", " @ %x @ ", " @ %y @ ", " @ %z @ "-100);",5); schedule("playSound(0, \"plasma3.wav\", IDPRF_2D);",5); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",6); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",7); schedule("dropPod(" @ %x @ ", " @ %y @ ", " @ %z+800 @ ", " @ %x @ ", " @ %y @ ", " @ %z @ ");",8); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",8); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",9); schedule("playSound(0, \"sfx_prob.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_fog.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_thunder1.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_thunder2.wav\", IDPRF_2D);",10);
// I have lowered the damage radius to reduce // spamming of deaths in the message area. // - Drake
schedule("damageArea("@ %vehicleId @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %vehicleId @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %vehicleId @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %vehicleId @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %vehicleId @", 0, 0, 0, 100, 999999999);",10.5); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",12); schedule("playSound(0, \"sfx_thunder1.wav\", IDPRF_2D);",12); schedule("deleteObject(" @ %beam @ ");",14); schedule("echo(\"Beam deleted.\");", 14); schedule("$satsafe = true;", 16); } else { echo("Anti K-Sat Spam Script enabled."); } } else if(%player == "") { echo("Please input a valid player number."); } } else if(%style == "other") { if($satsafe == true) {
$satsafe = false; %target = getHudName(%player); %x = getPosition(%player, x); %y = getPosition(%player, y); %z = getTerrainHeight(%x, %y); say(0,83,"<F5>WARNING: K-SAT Target Lock: " @ %target @ "<F5>.","warn_missl_lock.wav"); schedule("flushChannel(83);", 0.65);
// Creates a new beam object where in the C&D Files // a beam on the map was teleported to an area of a // strike. Simple and easy to adjust when/if wanted. %beam = newObject("beam", StaticShape, "fx_orbeam.DTS"); setPosition(%beam, 0, 0, getTerrainHeight(0, 0) - 10000); setHudTimer(10,-1,"K-SAT Aligning:", 2); playSound(0, "sfx_quake.wav", IDPRF_2D); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",3); schedule("setPosition(" @ %beam @ ", " @ %x @ ", " @ %y @ ", " @ %z @ "-100);",5); schedule("playSound(0, \"plasma3.wav\", IDPRF_2D);",5); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",6); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",7); schedule("dropPod(" @ %x @ ", " @ %y @ ", " @ %z+800 @ ", " @ %x @ ", " @ %y @ ", " @ %z @ ");",8); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",8); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",9); schedule("playSound(0, \"sfx_prob.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_fog.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_thunder1.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_thunder2.wav\", IDPRF_2D);",10);
// I have lowered the damage radius to reduce // spamming of deaths in the message area. // - Drake
schedule("damageArea("@ %player @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %player @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %player @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %player @", 0, 0, 0, 100, 999999999);",10.5); schedule("damageArea("@ %player @", 0, 0, 0, 100, 999999999);",10.5); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",12); schedule("playSound(0, \"sfx_thunder1.wav\", IDPRF_2D);",12); schedule("deleteObject(" @ %beam @ ");",14); schedule("echo(\"Beam deleted.\");", 14); schedule("$satsafe = true;", 16); } else { echo("Anti K-Sat Spam Script enabled."); } } else { echo("Style not supported."); } }
//--------------------------------------------------------------------- // // Possible Examples... // //---------------------------------------------------------------------
function vehicle::onSpot(%spotter, %target) { if(getTeam(%target) != getTeam(%spotter)) { // "other" allows the command to be used // in a function that calls on variables.
ksat(%target, "other"); echo("Vehicle Spot K-Sat Target: " @ getVehicleName(%target) @ " operated by: " @ getHudName(%target) @ "."); } else { %player = playerManager::vehicleIdToPlayerNum(%spotter); say(%player, 1, "<F5>You cannot spot your own teammate for a K-Sat strike!"); } }
function structure::onSpot(%spotter, %target) { if(getTeam(%target) != getTeam(%spotter)) { // "other" also allows for the spotting of // structures. "False" in the message shown // in-game after a K-Sat is spotted is for // an object not given a name. // Note: This also works on Turrets.
ksat(%target, "other"); echo("Structure Spot K-Sat Target: " @ getHudName(%target) @ "."); } else { %player = playerManager::vehicleIdToPlayerNum(%spotter); say(%player, 1, "<F5>You cannot spot your own team's buildings for a K-Sat strike!"); } }
Updated for other possible uses, and yes it will work on single player campaigns as far as I know. There are examples typed up so anyone who uses this script may use a LTADS to spot a vehicle or structure to use the K-Sat on. There is a 16 second limit between each K-Sat shot so it cannot be spammed unless someone changes a variable =\
Enjoy.
|
|
Drake Leet Scripter pl0x
Guest
|
Post by Drake Leet Scripter pl0x on Apr 12, 2009 15:57:04 GMT -5
Done Angel - was easy so what the hell lol.
Taro - make me a cheese biscuit now. I'm not playin with you boy I want my cheese biscuit.
$satsafe = true;
function fog(%player) { if(%player != "") { if($satsafe == true) {
$satsafe = false; %vehicleId = playerManager::playerNumToVehicleId(%player); %target = getHudName(%vehicleId); %x = getPosition(%vehicleId, x); %y = getPosition(%vehicleId, y); %z = getTerrainHeight(%x, %y); say(0,83,"<F5>WARNING: Finger of God tracking: " @ %target @ "<F5>.","warn_missl_lock.wav"); schedule("flushChannel(83);", 0.65); %beam = newObject("beam", StaticShape, "hTitanBeam.DTS"); setPosition(%beam, 0, 0, getTerrainHeight(0, 0) - 10000); setHudTimer(10,-1,"Finger of God - finding target.", 2); playSound(0, "sfx_quake.wav", IDPRF_2D); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",3); schedule("setPosition(" @ %beam @ ", " @ %x @ ", " @ %y @ ", " @ %z @ "-100);",5); schedule("playSound(0, \"plasma3.wav\", IDPRF_2D);",5); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",6); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",7); schedule("dropPod(" @ %x @ ", " @ %y @ ", " @ %z+800 @ ", " @ %x @ ", " @ %y @ ", " @ %z @ ");",8); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",8); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",9); schedule("playSound(0, \"sfx_prob.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_fog.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_thunder1.wav\", IDPRF_2D);",10); schedule("playSound(0, \"sfx_thunder2.wav\", IDPRF_2D);",10); schedule("damageObject("@ %vehicleId @", 999999999);",10.5); schedule("messageBox(" @ %player @ ", \"You have been touched by the Finger of God\");", 10.5); schedule("playSound(0, \"sfx_quake.wav\", IDPRF_2D);",12); schedule("playSound(0, \"sfx_thunder1.wav\", IDPRF_2D);",12); schedule("deleteObject(" @ %beam @ ");",14); schedule("echo(\"Beam deleted.\");", 14); schedule("$satsafe = true;", 16); } else { echo("Anti K-Sat Spam Script enabled."); } } else if(%player == "") { echo("Please input a valid player number."); } }
|
|