Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ==UserScript==
- // @name Vertix Mods; Aimbot, Switch Shooting, Zoom, Enemy Radar (Progress)
- // @namespace http://vertix.io/
- // @version 2.1
- // @description Mods for Vertix.io, press [ to start aimbot and ] to stop it. Right click to super shot. Use the scroll bar to zoom in and out. Enemy radar is red dots on map (In Progress).
- // @author SnowLord7
- // @match http://vertix.io/
- // @supportURL http://iomods.weebly.com/
- // @downloadURL http://iomods.weebly.com/vertixio-aimbot.html
- // @icon http://i.imgur.com/HtuQwpq.png
- // ==/UserScript==
- window.alert('SnowLords Super Mod has Been Correctly Installed!');
- //Aimbot
- var active = false;
- var interval = void 0;
- function activate(event) {
- event.preventDefault();
- if (event.keyCode === 219 && !active) {
- window.alert('Aimbot Actibated, Press Enter to Quickly Close This.');
- c.removeEventListener("mousemove", gameInput, false);
- active = true;
- interval = setInterval(aimClosestPlayer, 10);
- }
- }
- function deactivate(event) {
- event.preventDefault();
- if (event.keyCode === 221) {
- active = false;
- window.alert('Aimbot Deactivated, Press Enter to Quickly Close This.');
- clearInterval(interval);
- c.addEventListener("mousemove", gameInput, false);
- }
- }
- c.addEventListener("keydown", activate, false);
- c.addEventListener("keyup", deactivate, false);
- function getOtherPlayers(gameObjects, myTeam) {
- return gameObjects.filter(function (o) {
- return o.type === 'player' && o.dead === false && o.name !== player.name && o.team !== myTeam;
- });
- }
- function getMyPlayer(gameObjects) {
- return gameObjects.filter(function (o) {
- return o.name === player.name;
- })[0];
- }
- function distance(x1, y1, x2, y2) {
- return Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2));
- }
- function getClosestPlayer(gameObjects) {
- var myTeam = getMyPlayer(gameObjects).team;
- var otherPlayers = getOtherPlayers(gameObjects, myTeam);
- var closestDistance = Infinity;
- var closestPlayer = void 0;
- otherPlayers.forEach(function (p) {
- var d = distance(player.x, player.y, p.x, p.y);
- if (d < closestDistance) {
- closestPlayer = p;
- closestDistance = d;
- }
- });
- return closestPlayer;
- }
- function getAngle(x1, y1, x2, y2) {
- return Math.atan2(y1 - y2, x1 - x2);
- }
- function setTarget(angle, distance) {
- target.f = angle;
- target.d = distance;
- }
- function aimClosestPlayer() {
- var closestPlayer = getClosestPlayer(gameObjects);
- if (!closestPlayer) {
- return;
- }
- var angle = getAngle(player.x, player.y, closestPlayer.x, closestPlayer.y);
- var distance = 100;
- setTarget(angle, distance);
- targetChanged = true;
- }
- //Right Click to Double Shoot
- $("#cvs").mousedown(function(ev){
- if(ev.which == 3)
- {
- playerSwapWeapon(player, 1);
- setTimeout(shootBullet(player), 10);
- playerSwapWeapon(player, 1);
- }
- });
- //Zoom Mod
- var scrollDelta = 0,
- cvs = document.getElementById('cvs');
- cvs.addEventListener('mousewheel', zoom, false);
- cvs.addEventListener('DOMMouseScroll', zoom, false);
- function zoom(a) {
- userScroll = overlayFadeUp = overlayFadeDown = overlayMaxAlpha = 0;
- animateOverlay = false;
- a = window.event || a;
- a.preventDefault();
- a.stopPropagation();
- scrollDelta = Math.max(-1, Math.min(1, a.wheelDelta || -a.detail));
- if (socket && scrollDelta == -1 && maxScreenHeight < 4000) {
- (maxScreenHeight = maxScreenWidth += 250);
- resize();
- scrollDelta = 0;
- viewMult = 100;
- }
- if (socket && scrollDelta == 1 && maxScreenHeight > 1000) {
- (maxScreenHeight = maxScreenWidth -= 250);
- resize();
- scrollDelta = 0;
- viewMult = 100;
- }
- }
- //Machine Gun
- $("#cvs").mousedown(function(ev){
- if(ev.which == 3)
- {
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- shootBullet(player);
- }
- });
- //Ememy Radar
- $(document).ready(function() {
- window.drawMiniMap = function() {
- mapCanvas.width = mapCanvas.width, mapContext.globalAlpha = 1;
- for (var a = 0; a < gameObjects.length; ++a)
- "player" == gameObjects[a].type &&
- gameObjects[a].onScreen &&
- (gameObjects[a].index == player.index ||
- gameObjects[a].team !== player.team ||
- gameObjects[a].isBoss) &&
- (mapContext.fillStyle = gameObjects[a].index == player.index ? "#fff" : gameObjects[a].isBoss ? "#db4fcd" : "#d20d12",
- mapContext.beginPath(),
- mapContext.arc(gameObjects[a].x / gameWidth * mapScale, gameObjects[a].y / gameHeight * mapScale, pingScale, 0, 2 * mathPI, !0),
- mapContext.closePath(),
- mapContext.fill());
- if (null !== gameMap) {
- for (mapContext.globalAlpha = 1, a = 0; a < gameMap.pickups.length; ++a)
- gameMap.pickups[a].active &&
- ("lootcrate" == gameMap.pickups[a].type ? mapContext.fillStyle = "#ffd100" : "healthpack" == gameMap.pickups[a].type &&
- (mapContext.fillStyle = "#5ed951"),
- mapContext.beginPath(),
- mapContext.arc(gameMap.pickups[a].x / gameWidth * mapScale, gameMap.pickups[a].y / gameHeight * mapScale, pingScale, 0, 2 * mathPI, !0),
- mapContext.closePath(),
- mapContext.fill());
- mapContext.globalAlpha = 1.0,
- a = getCachedMiniMap(),
- null !== a &&
- mapContext.drawImage(a, 0, 0, mapScale, mapScale),
- delete a;
- }
- };
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement