From 8141cb7708e380b7f6950d5c4c9f0d48791f0599 Mon Sep 17 00:00:00 2001 From: Sergey Yarkov Date: Mon, 3 Aug 2020 23:30:50 +0300 Subject: [PATCH] working version --- client_packages/.listcache | Bin 0 -> 214 bytes client_packages/copchase/index.js | 92 + client_packages/copchase/package.json | 11 + client_packages/index.js | 1 + client_packages/nativeui/index.js | 1 + client_packages/ui/index.js | 1104 ++++++ packages/copchase/api/index.js | 44 + packages/copchase/commands/admin/admin.js | 258 ++ packages/copchase/commands/player/player.js | 159 + packages/copchase/copchase-config.js | 25 + packages/copchase/copchase.js | 290 ++ packages/copchase/events/admin/admin.js | 153 + packages/copchase/events/player/player.js | 164 + packages/copchase/events/skin.js | 725 ++++ packages/copchase/helpers/getDistance.js | 5 + packages/copchase/index.js | 47 + packages/copchase/models/Player.js | 8 + packages/copchase/models/index.js | 5 + packages/copchase/package-lock.json | 3341 +++++++++++++++++++ packages/copchase/package.json | 20 + 20 files changed, 6453 insertions(+) create mode 100644 client_packages/.listcache create mode 100644 client_packages/copchase/index.js create mode 100644 client_packages/copchase/package.json create mode 100644 client_packages/index.js create mode 100644 client_packages/nativeui/index.js create mode 100644 client_packages/ui/index.js create mode 100644 packages/copchase/api/index.js create mode 100644 packages/copchase/commands/admin/admin.js create mode 100644 packages/copchase/commands/player/player.js create mode 100644 packages/copchase/copchase-config.js create mode 100644 packages/copchase/copchase.js create mode 100644 packages/copchase/events/admin/admin.js create mode 100644 packages/copchase/events/player/player.js create mode 100644 packages/copchase/events/skin.js create mode 100644 packages/copchase/helpers/getDistance.js create mode 100644 packages/copchase/index.js create mode 100644 packages/copchase/models/Player.js create mode 100644 packages/copchase/models/index.js create mode 100644 packages/copchase/package-lock.json create mode 100644 packages/copchase/package.json diff --git a/client_packages/.listcache b/client_packages/.listcache new file mode 100644 index 0000000000000000000000000000000000000000..c070f221bc73f91135242e0d0a9cd58a64df5a70 GIT binary patch literal 214 zcmWe+U|>kjFG$WvEKb$W%u7kF(90@zD-6Ie>haq0&$}11PVAAU`j$B(p5FG!yQE p@J@)T22}`M8`u0}_ERrAZXg#)*^5Ak^a5E3eShoSOI0ROtpKh7IKKb@ literal 0 HcmV?d00001 diff --git a/client_packages/copchase/index.js b/client_packages/copchase/index.js new file mode 100644 index 0000000..be6c533 --- /dev/null +++ b/client_packages/copchase/index.js @@ -0,0 +1,92 @@ +require('./ui/index') // setup nativeui + +mp.gui.cursor.visible = false; + +let freeze = true +let showHud = false + +//mp.game.ui.displayHud(showHud); +mp.voiceChat.muted = false + +mp.events.add('render', () => { + + // Default ui + + mp.game.graphics.drawText("copchase server", [0.9, 0.005], { + font: 2, + color: [255, 255, 255, 1000], + scale: [0.8, 0.8], + outline: true + }) + mp.game.graphics.drawText("RageMP v1.1", [0.947, 0.050], { + font: 4, + color: [255, 255, 255, 1000], + scale: [0.5, 0.5], + outline: true + }) + mp.game.graphics.drawText(`${new Date().getHours()}:${new Date().getMinutes()}:${new Date().getSeconds()}`, [0.24, 0.95], { + font: 4, + color: [255, 255, 255, 1000], + scale: [0.6, 0.6], + outline: true + }) + if (mp.players.local.vehicle) { + mp.game.graphics.drawText(`Engine health: ${mp.players.local.vehicle.getEngineHealth().toFixed()}`, [0.54, 0.95], { + font: 7, + color: [255, 255, 255, 1000], + scale: [0.6, 0.6], + outline: true + }) + } +}) + +mp.events.add('setCarHealth', () => { + if (mp.players.local.vehicle.getEngineHealth().toFixed() <= 500) { + return false + } + + mp.players.local.vehicle.setEngineHealth(500) +}) + + +/* + Admin events +*/ + +mp.events.add('onGodMode', (player, godmode) => player.setInvincible(godmode)) + +/* + Player events +*/ + +mp.events.add("playerDeath", (player, reason, killer) => { + mp.game.graphics.startScreenEffect("DeathFailNeutralIn", 3000, false) + mp.game.gameplay.setFadeOutAfterDeath(false) + mp.game.ui.displayHud(true) + mp.game.ui.resetHudComponentValues(0) +}) + +mp.game.ui.displayHud(true) + +mp.events.add('setInv', (player) => player.setInvincible(true)) +mp.events.add('delInv', (player) => player.setInvincible(false)) + +mp.events.add("playerJoin", (player, message) => { + player.freezePosition(freeze) + mp.events.callRemote('onPlayerDamage') + mp.gui.chat.push(message) +}) + +mp.events.add('login', player => { + player.freezePosition(!freeze) + //mp.game.ui.displayHud(!showHud) +}) + +// mp.keys.bind(0x58, true, function() { +// mp.events.callRemote("voiceEnable", [mp.players.local]); +// mp.players.local.voiceVolume = 1.0 +// }) + +// mp.keys.bind(0x58, false, function() { +// mp.events.callRemote("voiceDisable", [mp.players.local]); +// }) diff --git a/client_packages/copchase/package.json b/client_packages/copchase/package.json new file mode 100644 index 0000000..3a5c4a1 --- /dev/null +++ b/client_packages/copchase/package.json @@ -0,0 +1,11 @@ +{ + "name": "copchase", + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "author": "", + "license": "ISC" +} diff --git a/client_packages/index.js b/client_packages/index.js new file mode 100644 index 0000000..8fa2f92 --- /dev/null +++ b/client_packages/index.js @@ -0,0 +1 @@ +require('./copchase/index') \ No newline at end of file diff --git a/client_packages/nativeui/index.js b/client_packages/nativeui/index.js new file mode 100644 index 0000000..abb9bb5 --- /dev/null +++ b/client_packages/nativeui/index.js @@ -0,0 +1 @@ +!function(t){var e={};function s(i){if(e[i])return e[i].exports;var n=e[i]={i:i,l:!1,exports:{}};return t[i].call(n.exports,n,n.exports,s),n.l=!0,n.exports}s.m=t,s.c=e,s.d=function(t,e,i){s.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},s.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},s.t=function(t,e){if(1&e&&(t=s(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(s.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)s.d(i,n,function(e){return t[e]}.bind(null,n));return i},s.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return s.d(e,"a",e),e},s.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},s.p="",s(s.s=0)}([function(t,e,s){"use strict";var i;s.r(e),function(t){t[t.None=0]="None",t[t.BronzeMedal=1]="BronzeMedal",t[t.GoldMedal=2]="GoldMedal",t[t.SilverMedal=3]="SilverMedal",t[t.Alert=4]="Alert",t[t.Crown=5]="Crown",t[t.Ammo=6]="Ammo",t[t.Armour=7]="Armour",t[t.Barber=8]="Barber",t[t.Clothes=9]="Clothes",t[t.Franklin=10]="Franklin",t[t.Bike=11]="Bike",t[t.Car=12]="Car",t[t.Gun=13]="Gun",t[t.Heart=14]="Heart",t[t.Makeup=15]="Makeup",t[t.Mask=16]="Mask",t[t.Michael=17]="Michael",t[t.Star=18]="Star",t[t.Tatoo=19]="Tatoo",t[t.Trevor=20]="Trevor",t[t.Lock=21]="Lock",t[t.Tick=22]="Tick"}(i||(i={}));var n,h=i;!function(t){t[t.ChaletLondon=0]="ChaletLondon",t[t.HouseScript=1]="HouseScript",t[t.Monospace=2]="Monospace",t[t.CharletComprimeColonge=4]="CharletComprimeColonge",t[t.Pricedown=7]="Pricedown"}(n||(n={}));var o=n;class r{constructor(t,e,s,i=255){this.R=t,this.G=e,this.B=s,this.A=i}}r.Empty=new r(0,0,0,0),r.Transparent=new r(0,0,0,0),r.Black=new r(0,0,0,255),r.White=new r(255,255,255,255),r.WhiteSmoke=new r(245,245,245,255);const a=mp.game.graphics.getScreenActiveResolution(0,0),l={width:a.x,height:a.y};class c{constructor(t,e,s,i,n=0,h=new r(255,255,255)){this.TextureDict=t,this.TextureName=e,this.pos=s,this.size=i,this.heading=n,this.color=h,this.visible=!0}LoadTextureDictionary(){for(mp.game.graphics.requestStreamedTextureDict(this._textureDict,!0);!this.IsTextureDictionaryLoaded;)mp.game.wait(0)}set TextureDict(t){this._textureDict=t,this.IsTextureDictionaryLoaded||this.LoadTextureDictionary()}get TextureDict(){return this._textureDict}get IsTextureDictionaryLoaded(){return mp.game.graphics.hasStreamedTextureDictLoaded(this._textureDict)}Draw(t,e,s,i,n,h,o){t=t||this.TextureDict,e=e||this.TextureName,s=s||this.pos,i=i||this.size,n=n||this.heading,h=h||this.color,(o=o||!0)&&(mp.game.graphics.hasStreamedTextureDictLoaded(t)||mp.game.graphics.requestStreamedTextureDict(t,!0));const r=1080*(l.width/l.height),a=this.size.Width/r,c=this.size.Height/1080,u=this.pos.X/r+.5*a,d=this.pos.Y/1080+.5*c;mp.game.graphics.drawSprite(t,e,u,d,a,c,n,h.R,h.G,h.B,h.A)}}class u{constructor(){this.handlers=[]}on(t){this.handlers.push(t)}off(t){this.handlers=this.handlers.filter(e=>e!==t)}emit(...t){this.handlers.slice(0).forEach(e=>e(...t))}expose(){return this}}class d{constructor(t,e){this.X=0,this.Y=0,this.X=t,this.Y=e}static Parse(t){if("object"==typeof t){if(t.length)return new d(t[0],t[1]);if(t.X&&t.Y)return new d(t.X,t.Y)}else if("string"==typeof t&&-1!==t.indexOf(",")){const e=t.split(",");return new d(parseFloat(e[0]),parseFloat(e[1]))}return new d(0,0)}}class m{constructor(t=0,e=0){this.Width=t,this.Height=e}}class g{constructor(){this.enabled=!0}}class f extends g{constructor(t,e,s){super(),this.enabled=!0,this.pos=t,this.size=e,this.color=s}Draw(t,e,s){t||(t=new m(0,0)),e||s||(t=new d(this.pos.X+t.Width,this.pos.Y+t.Height),e=this.size,s=this.color);const i=e.Width/1280,n=e.Height/720,h=t.X/1280+.5*i,o=t.Y/720+.5*n;mp.game.graphics.drawRect(h,o,i,n,s.R,s.G,s.B,s.A)}}class _ extends f{constructor(t,e,s){super(t,e,s)}Draw(t,e,s){t||(t=new m),!t||e||s||(t=new d(this.pos.X+t.Width,this.pos.Y+t.Height),e=this.size,s=this.color);const i=1080*(l.width/l.height),n=e.Width/i,h=e.Height/1080,o=t.X/i+.5*n,r=t.Y/1080+.5*h;mp.game.graphics.drawRect(o,r,n,h,s.R,s.G,s.B,s.A)}}class I extends g{constructor(t,e,s,i,n,h){super(),this.caption=t,this.pos=e,this.scale=s,this.color=i||new r(255,255,255,255),this.font=n||0,this.centered=h||!1}Draw(t,e,s,i,n,h){!t||e||s||i||n||h||(e=new d(this.pos.X+t.Width,this.pos.Y+t.Height),s=this.scale,i=this.color,n=this.font,h=this.centered);const o=e.X/1280,r=e.Y/720;mp.game.ui.setTextFont(parseInt(n)),mp.game.ui.setTextScale(s,s),mp.game.ui.setTextColour(i.R,i.G,i.B,i.A),mp.game.ui.setTextCentre(h),mp.game.ui.setTextEntry("STRING"),w.AddLongString(t),mp.game.ui.drawText(o,r)}}var p;exports=I,function(t){t[t.Left=0]="Left",t[t.Centered=1]="Centered",t[t.Right=2]="Right"}(p||(p={}));class w extends I{constructor(t,e,s,i,n,h){super(t,e,s,i||new r(255,255,255),n||0,!1),this.TextAlignment=p.Left,h&&(this.TextAlignment=h)}Draw(t,e,s,i,n,h,o,r,a){let c=t,u=h,g=h;t||(t=new m(0,0)),t&&!e&&(g=this.TextAlignment,c=this.caption,e=new d(this.pos.X+t.Width,this.pos.Y+t.Height),s=this.scale,i=this.color,n=this.font,1==u||0==u?u=this.centered:(u=void 0,o=this.DropShadow,r=this.Outline,a=this.WordWrap));const f=1080*(l.width/l.height),_=this.pos.X/f,I=this.pos.Y/1080;if(mp.game.ui.setTextFont(parseInt(n)),mp.game.ui.setTextScale(1,s),mp.game.ui.setTextColour(i.R,i.G,i.B,i.A),void 0!==u)mp.game.ui.setTextCentre(u);else{switch(o&&mp.game.ui.setTextDropshadow(2,0,0,0,0),r&&console.warn("not working!"),g){case p.Centered:mp.game.ui.setTextCentre(!0);break;case p.Right:mp.game.ui.setTextRightJustify(!0),mp.game.ui.setTextWrap(0,_)}if(a){const t=(this.pos.X+a.Width)/f;mp.game.ui.setTextWrap(_,t)}}mp.game.ui.setTextEntry("STRING"),w.AddLongString(c),mp.game.ui.drawText(_,I)}static AddLongString(t){for(var e=0;ee.Id===t.Id);this.Index=e>0?e:0}get SelectedItem(){return this.Collection.length>0?this.Collection[this.Index]:null}get SelectedValue(){return null==this.SelectedItem?null:null==this.SelectedItem.Data?this.SelectedItem.DisplayText:this.SelectedItem.Data}get ListChanged(){return this.OnListChanged.expose()}get Index(){return null==this.Collection?-1:null!=this.Collection&&0==this.Collection.length?-1:this._index%this.Collection.length}set Index(t){if(null==this.Collection)return;if(null!=this.Collection&&0==this.Collection.length)return;this._index=1e5-1e5%this.Collection.length+t;const e=this.Collection.length>=this.Index?this.Collection[this.Index].DisplayText:" ";this.currOffset=D.MeasureString(e)}setCollection(t){this.Collection=t.getListItems()}setCollectionItem(t,e,s=!0){if(t>this.Collection.length)throw new Error("Index out of bounds");"string"==typeof e&&(e=new C(e)),this.Collection.splice(t,1,e),s&&(this.Index=0)}SetVerticalPosition(t){this._arrowLeft.pos=new d(300+this.Offset.X+this.Parent.WidthOffset,147+t+this.Offset.Y),this._arrowRight.pos=new d(400+this.Offset.X+this.Parent.WidthOffset,147+t+this.Offset.Y),this._itemText.pos=new d(300+this.Offset.X+this.Parent.WidthOffset,t+147+this.Offset.Y),super.SetVerticalPosition(t)}SetRightLabel(t){return this}SetRightBadge(t){return this}Draw(){super.Draw();const t=this.Collection.length>=this.Index?this.Collection[this.Index].DisplayText:" ",e=this.currOffset;this._itemText.color=this.Enabled?this.Selected?this.HighlightedForeColor:this.ForeColor:new r(163,159,148),this._itemText.caption=t,this._arrowLeft.color=this.Enabled?this.Selected?this.HighlightedForeColor:this.ForeColor:new r(163,159,148),this._arrowRight.color=this.Enabled?this.Selected?this.HighlightedForeColor:this.ForeColor:new r(163,159,148),this._arrowLeft.pos=new d(375-e+this.Offset.X+this.Parent.WidthOffset,this._arrowLeft.pos.Y),this.Selected?(this._arrowLeft.Draw(),this._arrowRight.Draw(),this._itemText.pos=new d(405+this.Offset.X+this.Parent.WidthOffset,this._itemText.pos.Y)):this._itemText.pos=new d(420+this.Offset.X+this.Parent.WidthOffset,this._itemText.pos.Y),this._itemText.Draw()}}class b extends S{get Index(){return this._index%this._items.length}set Index(t){this._index=1e8-1e8%this._items.length+t}constructor(t,e,s,i="",n=!1){super(t,i);this._items=e,this._arrowLeft=new c("commonmenutu","arrowleft",new d(0,105),new m(15,15)),this._arrowRight=new c("commonmenutu","arrowright",new d(0,105),new m(15,15)),this._rectangleBackground=new _(new d(0,0),new m(150,9),new r(4,32,57,255)),this._rectangleSlider=new _(new d(0,0),new m(75,9),new r(57,116,200,255)),this._rectangleDivider=new _(new d(0,0),new m(2.5,20),n?r.WhiteSmoke:r.Transparent),this.Index=s}SetVerticalPosition(t){this._rectangleBackground.pos=new d(250+this.Offset.X+this.Parent.WidthOffset,t+158.5+this.Offset.Y),this._rectangleSlider.pos=new d(250+this.Offset.X+this.Parent.WidthOffset,t+158.5+this.Offset.Y),this._rectangleDivider.pos=new d(323.5+this.Offset.X+this.Parent.WidthOffset,t+153+this.Offset.Y),this._arrowLeft.pos=new d(235+this.Offset.X+this.Parent.WidthOffset,155.5+t+this.Offset.Y),this._arrowRight.pos=new d(400+this.Offset.X+this.Parent.WidthOffset,155.5+t+this.Offset.Y),super.SetVerticalPosition(t)}IndexToItem(t){return this._items[t]}Draw(){super.Draw(),this._arrowLeft.color=this.Enabled?this.Selected?r.Black:r.WhiteSmoke:new r(163,159,148),this._arrowRight.color=this.Enabled?this.Selected?r.Black:r.WhiteSmoke:new r(163,159,148);let t=(this._rectangleBackground.size.Width-this._rectangleSlider.size.Width)/(this._items.length-1)*this.Index;this._rectangleSlider.pos=new d(250+this.Offset.X+t+ +this.Parent.WidthOffset,this._rectangleSlider.pos.Y),this.Selected&&(this._arrowLeft.Draw(),this._arrowRight.Draw()),this._rectangleBackground.Draw(),this._rectangleSlider.Draw(),this._rectangleDivider.Draw()}SetRightBadge(t){}SetRightLabel(t){}}class T extends f{constructor(t,e,s){super(t,e,s),this.Items=[]}addItem(t){this.Items.push(t)}Draw(t){if(!this.enabled)return;t=t||new m;const e=1080*(l.width/l.height),s=this.size.Width/e,i=this.size.Height/1080,n=(this.pos.X+t.Width)/e+.5*s,h=(this.pos.Y+t.Height)/1080+.5*i;for(var o of(mp.game.graphics.drawRect(n,h,s,i,this.color.R,this.color.G,this.color.B,this.color.A),this.Items))o.Draw(new m(this.pos.X+t.Width,this.pos.Y+t.Height))}}class v{static PlaySound(t,e){mp.game.audio.playSound(-1,t,e,!1,0,!0)}}s.d(e,"default",function(){return L});class L{constructor(t,e,s,i,n){this.Id=x(),this.counterPretext="",this.counterOverride=void 0,this.lastUpDownNavigation=0,this.lastLeftRightNavigation=0,this._activeItem=1e3,this.extraOffset=0,this.WidthOffset=0,this.Visible=!0,this.MouseControlsEnabled=!1,this._justOpened=!0,this.safezoneOffset=new d(0,0),this.MaxItemsOnScreen=9,this._maxItem=this.MaxItemsOnScreen,this.AUDIO_LIBRARY="HUD_FRONTEND_DEFAULT_SOUNDSET",this.AUDIO_UPDOWN="NAV_UP_DOWN",this.AUDIO_LEFTRIGHT="NAV_LEFT_RIGHT",this.AUDIO_SELECT="SELECT",this.AUDIO_BACK="BACK",this.AUDIO_ERROR="ERROR",this.MenuItems=[],this.IndexChange=new u,this.ListChange=new u,this.SliderChange=new u,this.SliderSelect=new u,this.CheckboxChange=new u,this.ItemSelect=new u,this.MenuClose=new u,this.MenuChange=new u,this.MouseEdgeEnabled=!0,s instanceof d||(s=d.Parse(s)),this.title=t,this.subtitle=e,this.spriteLibrary=i||"commonmenu",this.spriteName=n||"interaction_bgd",this.offset=new d(s.X,s.Y),this.Children=new Map,this._mainMenu=new T(new d(0,0),new m(700,500),new r(0,0,0,0)),this._logo=new c(this.spriteLibrary,this.spriteName,new d(0+this.offset.X,0+this.offset.Y),new m(431,107)),this._mainMenu.addItem(this._title=new w(this.title,new d(215+this.offset.X,20+this.offset.Y),1.15,new r(255,255,255),1,p.Centered)),""!==this.subtitle&&(this._mainMenu.addItem(new _(new d(0+this.offset.X,107+this.offset.Y),new m(431,37),new r(0,0,0,255))),this._mainMenu.addItem(this._subtitle=new w(this.subtitle,new d(8+this.offset.X,110+this.offset.Y),.35,new r(255,255,255),0,p.Left)),this.subtitle.startsWith("~")&&(this.counterPretext=this.subtitle.substr(0,3)),this._counterText=new w("",new d(425+this.offset.X,110+this.offset.Y),.35,new r(255,255,255),0,p.Right),this.extraOffset+=37),this._upAndDownSprite=new c("commonmenu","shop_arrows_upanddown",new d(190+this.offset.X,147+37*(this.MaxItemsOnScreen+1)+this.offset.Y-37+this.extraOffset),new m(50,50)),this._extraRectangleUp=new _(new d(0+this.offset.X,144+38*(this.MaxItemsOnScreen+1)+this.offset.Y-37+this.extraOffset),new m(431,18),new r(0,0,0,200)),this._extraRectangleDown=new _(new d(0+this.offset.X,162+38*(this.MaxItemsOnScreen+1)+this.offset.Y-37+this.extraOffset),new m(431,18),new r(0,0,0,200)),this._descriptionBar=new _(new d(this.offset.X,123),new m(431,4),r.Black),this._descriptionRectangle=new c("commonmenu","gradient_bgd",new d(this.offset.X,127),new m(431,30)),this._descriptionText=new w("Description",new d(this.offset.X+5,125),.35,new r(255,255,255,255),o.ChaletLondon,p.Left),this._background=new c("commonmenu","gradient_bgd",new d(this.offset.X,144+this.offset.Y-37+this.extraOffset),new m(290,25)),mp.events.add("render",this.render.bind(this)),console.log(`Created Native UI! ${this.title}`)}get CurrentSelection(){return this._activeItem%this.MenuItems.length}set CurrentSelection(t){this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem=1e3-1e3%this.MenuItems.length+t,this.CurrentSelection>this._maxItem?(this._maxItem=this.CurrentSelection,this._minItem=this.CurrentSelection-this.MaxItemsOnScreen):this.CurrentSelectionthis.MaxItemsOnScreen+1&&(t=this.MaxItemsOnScreen+2),this._descriptionBar.pos=new d(this.offset.X,38*t+this._descriptionBar.pos.Y),this._descriptionRectangle.pos=new d(this.offset.X,38*t+this._descriptionRectangle.pos.Y),this._descriptionText.pos=new d(this.offset.X+8,38*t+this._descriptionText.pos.Y)}SetMenuWidthOffset(t){if(this.WidthOffset=t,null!=this._logo&&(this._logo.size=new m(431+this.WidthOffset,107)),this._mainMenu.Items[0].pos=new d((this.WidthOffset+this.offset.X+431)/2,20+this.offset.Y),this._counterText&&(this._counterText.pos=new d(425+this.offset.X+t,110+this.offset.Y)),this._mainMenu.Items.length>=2){this._mainMenu.Items[1].size=new m(431+this.WidthOffset,37)}}AddItem(t){this._justOpened&&(this._justOpened=!1),t.Offset=this.offset,t.Parent=this,t.SetVerticalPosition(25*this.MenuItems.length-37+this.extraOffset),this.MenuItems.push(t),t.Description=this.FormatDescription(t.Description),this.RefreshIndex(),this.RecalculateDescriptionPosition()}RefreshIndex(){if(0==this.MenuItems.length)return this._activeItem=1e3,this._maxItem=this.MaxItemsOnScreen,void(this._minItem=0);for(let t=0;t=t.X&&s<=t.X+e.Width&&i>t.Y&&it.Hovered).forEach(t=>t.Hovered=!1);mp.gui.cursor.visible||(mp.gui.cursor.visible=!0);let t=this.MenuItems.length-1,e=0;this.MenuItems.length>this.MaxItemsOnScreen+1&&(t=this._maxItem),this.IsMouseInBounds(new d(0,0),new m(30,1080))&&this.MouseEdgeEnabled?(mp.game.cam.setGameplayCamRelativeHeading(mp.game.cam.getGameplayCamRelativeHeading()+5),mp.game.ui.setCursorSprite(6)):this.IsMouseInBounds(new d(this.GetScreenResolutionMantainRatio().Width-30,0),new m(30,1080))&&this.MouseEdgeEnabled?(mp.game.cam.setGameplayCamRelativeHeading(mp.game.cam.getGameplayCamRelativeHeading()-5),mp.game.ui.setCursorSprite(7)):this.MouseEdgeEnabled&&mp.game.ui.setCursorSprite(1);for(let i=this._minItem;i<=t;i++){let t=this.offset.X,n=this.offset.Y+144-37+this.extraOffset+38*e,h=431+this.WidthOffset;const o=38,r=this.MenuItems[i];if(this.IsMouseInBounds(new d(t,n),new m(h,o))){if(r.Hovered=!0,mp.game.controls.isControlJustPressed(0,24)||mp.game.controls.isDisabledControlJustPressed(0,24))if(r.Selected&&r.Enabled)if(this.MenuItems[i]instanceof R&&this.IsMouseInListItemArrows(this.MenuItems[i],new d(t,n),0)>0){switch(this.IsMouseInListItemArrows(this.MenuItems[i],new d(t,n),0)){case 1:v.PlaySound(this.AUDIO_SELECT,this.AUDIO_LIBRARY),this.MenuItems[i].fireEvent(),this.ItemSelect.emit(this.MenuItems[i],i);break;case 2:var s=this.MenuItems[i];(null==s.Collection?s.Items.Count:s.Collection.Count)>0&&(s.Index++,v.PlaySound(this.AUDIO_LEFTRIGHT,this.AUDIO_LIBRARY),this.ListChange.emit(s,s.Index))}}else this.SelectItem();else r.Selected?!r.Enabled&&r.Selected&&v.PlaySound(this.AUDIO_ERROR,this.AUDIO_LIBRARY):(this.CurrentSelection=i,v.PlaySound(this.AUDIO_UPDOWN,this.AUDIO_LIBRARY),this.IndexChange.emit(this.CurrentSelection),this.SelectItem())}else r.Hovered=!1;e++}const i=144+38*(this.MaxItemsOnScreen+1)+this.offset.Y-37+this.extraOffset+this.safezoneOffset.Y,n=this.safezoneOffset.X+this.offset.X;this.MenuItems.length<=this.MaxItemsOnScreen+1||(this.IsMouseInBounds(new d(n,i),new m(431+this.WidthOffset,18))?(this._extraRectangleUp.color=new r(30,30,30,255),(mp.game.controls.isControlJustPressed(0,24)||mp.game.controls.isDisabledControlJustPressed(0,24))&&(this.MenuItems.length>this.MaxItemsOnScreen+1?this.GoUpOverflow():this.GoUp())):this._extraRectangleUp.color=new r(0,0,0,200),this.IsMouseInBounds(new d(n,i+18),new m(431+this.WidthOffset,18))?(this._extraRectangleDown.color=new r(30,30,30,255),(mp.game.controls.isControlJustPressed(0,24)||mp.game.controls.isDisabledControlJustPressed(0,24))&&(this.MenuItems.length>this.MaxItemsOnScreen+1?this.GoDownOverflow():this.GoDown())):this._extraRectangleDown.color=new r(0,0,0,200))}ProcessControl(){this.Visible&&(this._justOpened?this._justOpened=!1:(mp.game.controls.isControlJustReleased(0,177)&&this.GoBack(),0!=this.MenuItems.length&&(mp.game.controls.isControlPressed(0,172)&&this.lastUpDownNavigation+120this.MaxItemsOnScreen+1?this.GoUpOverflow():this.GoUp()):mp.game.controls.isControlJustReleased(0,172)?this.lastUpDownNavigation=0:mp.game.controls.isControlPressed(0,173)&&this.lastUpDownNavigation+120this.MaxItemsOnScreen+1?this.GoDownOverflow():this.GoDown()):mp.game.controls.isControlJustReleased(0,173)?this.lastUpDownNavigation=0:mp.game.controls.isControlPressed(0,174)&&this.lastLeftRightNavigation+10099&&(t=t.slice(0,99));const e=425+this.WidthOffset;let s=0,i="";const n=t.split(" ");for(const t of n){const n=D.MeasureString(t);(s+=n)>e?(i+="\n"+t+" ",s=n+D.MeasureString(" ")):(i+=t+" ",s+=D.MeasureString(" "))}return i}GoUpOverflow(){this.MenuItems.length<=this.MaxItemsOnScreen+1||(this._activeItem%this.MenuItems.length<=this._minItem?this._activeItem%this.MenuItems.length==0?(this._minItem=this.MenuItems.length-this.MaxItemsOnScreen-1,this._maxItem=this.MenuItems.length-1,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem=1e3-1e3%this.MenuItems.length,this._activeItem+=this.MenuItems.length-1,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0):(this._minItem--,this._maxItem--,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem--,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0):(this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem--,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0),v.PlaySound(this.AUDIO_UPDOWN,this.AUDIO_LIBRARY),this.IndexChange.emit(this.CurrentSelection))}GoUp(){this.MenuItems.length>this.MaxItemsOnScreen+1||(this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem--,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0,v.PlaySound(this.AUDIO_UPDOWN,this.AUDIO_LIBRARY),this.IndexChange.emit(this.CurrentSelection))}GoDownOverflow(){this.MenuItems.length<=this.MaxItemsOnScreen+1||(this._activeItem%this.MenuItems.length>=this._maxItem?this._activeItem%this.MenuItems.length==this.MenuItems.length-1?(this._minItem=0,this._maxItem=this.MaxItemsOnScreen,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem=1e3-1e3%this.MenuItems.length,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0):(this._minItem++,this._maxItem++,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem++,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0):(this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem++,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0),v.PlaySound(this.AUDIO_UPDOWN,this.AUDIO_LIBRARY),this.IndexChange.emit(this.CurrentSelection))}GoDown(){this.MenuItems.length>this.MaxItemsOnScreen+1||(this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!1,this._activeItem++,this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0,v.PlaySound(this.AUDIO_UPDOWN,this.AUDIO_LIBRARY),this.IndexChange.emit(this.CurrentSelection))}GoBack(){v.PlaySound(this.AUDIO_BACK,this.AUDIO_LIBRARY),this.Visible=!1,null!=this.ParentMenu&&(this.ParentMenu.Visible=!0,this.ParentMenu._justOpened=!0,this.MenuChange.emit(this.ParentMenu,!1)),this.MenuClose.emit()}BindMenuToItem(t,e){t.ParentMenu=this,t.ParentItem=e,this.Children.set(e.Id,t)}ReleaseMenuFromItem(t){if(!this.Children.has(t.Id))return!1;const e=this.Children.get(t.Id);return e.ParentItem=null,e.ParentMenu=null,this.Children.delete(t.Id),!0}render(){if(this.Visible){if(this._justOpened&&(null==this._logo||this._logo.IsTextureDictionaryLoaded||this._logo.LoadTextureDictionary(),this._background.IsTextureDictionaryLoaded||this._background.LoadTextureDictionary(),this._descriptionRectangle.IsTextureDictionaryLoaded||this._descriptionRectangle.LoadTextureDictionary(),this._upAndDownSprite.IsTextureDictionaryLoaded||this._upAndDownSprite.LoadTextureDictionary()),this._mainMenu.Draw(),this.ProcessMouse(),this.ProcessControl(),this._background.size=this.MenuItems.length>this.MaxItemsOnScreen+1?new m(431+this.WidthOffset,38*(this.MaxItemsOnScreen+1)):new m(431+this.WidthOffset,38*this.MenuItems.length),this._background.Draw(),this.MenuItems.length>0&&(this.MenuItems[this._activeItem%this.MenuItems.length].Selected=!0,""!==this.MenuItems[this._activeItem%this.MenuItems.length].Description.trim())){this.RecalculateDescriptionPosition();let t=this.MenuItems[this._activeItem%this.MenuItems.length].Description;this._descriptionText.caption=t;const e=this._descriptionText.caption.split("\n").length;this._descriptionRectangle.size=new m(431+this.WidthOffset,25*e+15),this._descriptionBar.Draw(),this._descriptionRectangle.Draw(),this._descriptionText.Draw()}if(this.MenuItems.length<=this.MaxItemsOnScreen+1){let t=0;for(const e of this.MenuItems)e.SetVerticalPosition(38*t-37+this.extraOffset),e.Draw(),t++;this._counterText&&this.counterOverride&&(this._counterText.caption=this.counterPretext+this.counterOverride,this._counterText.Draw())}else{let e=0;for(let s=this._minItem;s<=this._maxItem;s++){var t=this.MenuItems[s];t.SetVerticalPosition(38*e-37+this.extraOffset),t.Draw(),e++}if(this._extraRectangleUp.size=new m(431+this.WidthOffset,18),this._extraRectangleDown.size=new m(431+this.WidthOffset,18),this._upAndDownSprite.pos=new d(190+this.offset.X+this.WidthOffset/2,147+37*(this.MaxItemsOnScreen+1)+this.offset.Y-37+this.extraOffset),this._extraRectangleUp.Draw(),this._extraRectangleDown.Draw(),this._upAndDownSprite.Draw(),this._counterText){if(this.counterOverride)this._counterText.caption=this.counterPretext+this.counterOverride;else{const t=this.CurrentSelection+1+" / "+this.MenuItems.length;this._counterText.caption=this.counterPretext+t}this._counterText.Draw()}}this._logo.Draw()}}}exports.Menu=L,exports.UIMenuItem=S,exports.UIMenuListItem=R,exports.UIMenuCheckboxItem=M,exports.UIMenuSliderItem=b,exports.BadgeStyle=h,exports.Point=d,exports.Size=m,exports.Color=r,exports.Font=o,exports.ItemsCollection=O,exports.ListItem=C}]); \ No newline at end of file diff --git a/client_packages/ui/index.js b/client_packages/ui/index.js new file mode 100644 index 0000000..6eace97 --- /dev/null +++ b/client_packages/ui/index.js @@ -0,0 +1,1104 @@ +const NativeUI = require('./nativeui/index') +const Menu = NativeUI.Menu +const UIMenuItem = NativeUI.UIMenuItem +const UIMenuListItem = NativeUI.UIMenuListItem +const ItemsCollection = NativeUI.ItemsCollection +const UIMenuCheckboxItem = NativeUI.UIMenuCheckboxItem +const Point = NativeUI.Point + +const menuPos = new Point(1450, 150) + +const cars = `ninef +ninef2 +blista +asea +asea2 +boattrailer +bus +armytanker +armytrailer +armytrailer2 +freighttrailer +coach +airbus +asterope +airtug +ambulance +barracks +barracks2 +baller +baller2 +bjxl +banshee +benson +bfinjection +biff +blazer +blazer2 +blazer3 +bison +bison2 +bison3 +boxville +boxville2 +boxville3 +bobcatxl +bodhi2 +buccaneer +buffalo +buffalo2 +bulldozer +bullet +blimp +burrito +burrito2 +burrito3 +burrito4 +burrito5 +cavalcade +cavalcade2 +policet +gburrito +cablecar +caddy +caddy2 +camper +carbonizzare +cheetah +comet2 +cogcabrio +coquette +cutter +gresley +dilettante +dilettante2 +dune +dune2 +hotknife +dloader +dubsta +dubsta2 +dump +rubble +docktug +dominator +emperor +emperor2 +emperor3 +entityxf +exemplar +elegy2 +f620 +fbi +fbi2 +felon +felon2 +feltzer2 +firetruk +flatbed +forklift +fq2 +fusilade +fugitive +futo +granger +gauntlet +habanero +hauler +handler +infernus +ingot +intruder +issi2 +Jackal +journey +jb700 +khamelion +landstalker +lguard +manana +mesa +mesa2 +mesa3 +crusader +minivan +mixer +mixer2 +monroe +mower +mule +mule2 +oracle +oracle2 +packer +patriot +pbus +penumbra +peyote +phantom +phoenix +picador +pounder +police +police4 +police2 +police3 +policeold1 +policeold2 +pony +pony2 +prairie +pranger +premier +primo +proptrailer +rancherxl +rancherxl2 +rapidgt +rapidgt2 +radi +ratloader +rebel +regina +rebel2 +rentalbus +ruiner +rumpo +rumpo2 +rhino +riot +ripley +rocoto +romero +sabregt +sadler +sadler2 +sandking +sandking2 +schafter2 +schwarzer +scrap +seminole +sentinel +sentinel2 +zion +zion2 +serrano +sheriff +sheriff2 +speedo +speedo2 +stanier +stinger +stingergt +stockade +stockade3 +stratum +sultan +superd +surano +surfer +surfer2 +surge +taco +tailgater +taxi +trash +tractor +tractor2 +tractor3 +graintrailer +baletrailer +tiptruck +tiptruck2 +tornado +tornado2 +tornado3 +tornado4 +tourbus +towtruck +towtruck2 +utillitruck +utillitruck2 +utillitruck3 +voodoo2 +washington +stretch +youga +ztype +sanchez +sanchez2 +scorcher +tribike +tribike2 +tribike3 +fixter +cruiser +BMX +policeb +akuma +carbonrs +bagger +bati +bati2 +ruffian +daemon +double +pcj +vader +vigero +faggio2 +hexer +annihilator +buzzard +buzzard2 +cargobob +cargobob2 +cargobob3 +skylift +polmav +maverick +nemesis +frogger +frogger2 +cuban800 +duster +stunt +mammatus +jet +shamal +luxor +titan +lazer +cargoplane +squalo +marquis +dinghy +dinghy2 +jetmax +predator +tropic +seashark +seashark2 +submersible +freightcar +freight +freightcont1 +freightcont2 +freightgrain +tankercar +metrotrain +docktrailer +trailers +trailers2 +trailers3 +tvtrailer +raketrailer +tanker +trailerlogs +tr2 +tr3 +tr4 +trflat +trailersmall +velum +adder +voltic +vacca +suntrap +submersible2 +dukes +dukes2 +buffalo3 +dominator2 +dodo +marshall +blimp2 +gauntlet2 +stalion +stalion2 +blista2 +blista3 +bifta +speeder +kalahari +paradise +btype +jester +turismor +alpha +vestra +zentorno +massacro +huntley +thrust +rhapsody +warrener +blade +glendale +panto +dubsta3 +pigalle +monster +sovereign +innovation +hakuchou +furoregt +miljet +besra +coquette2 +swift +jester2 +massacro2 +ratloader2 +slamvan +mule3 +velum2 +tanker2 +casco +boxville4 +hydra +insurgent +insurgent2 +gburrito2 +technical +dinghy3 +savage +enduro +guardian +lectro +kuruma +kuruma2 +trash2 +barracks3 +valkyrie +slamvan2 +swift2 +luxor2 +feltzer3 +osiris +virgo +windsor +coquette3 +vindicator +t20 +brawler +toro +chino +faction +faction2 +moonbeam +moonbeam2 +primo2 +chino2 +buccaneer2 +voodoo +Lurcher +btype2 +verlierer2 +nightshade +mamba +limo2 +schafter3 +schafter4 +schafter5 +schafter6 +cog55 +cog552 +cognoscenti +cognoscenti2 +baller3 +baller4 +baller5 +baller6 +toro2 +seashark3 +dinghy4 +tropic2 +speeder2 +cargobob4 +supervolito +supervolito2 +valkyrie2 +tampa +sultanrs +banshee2 +btype3 +faction3 +minivan2 +sabregt2 +slamvan3 +tornado5 +virgo2 +virgo3 +nimbus +xls +xls2 +seven70 +fmj +bestiagts +pfister811 +brickade +rumpo3 +volatus +prototipo +reaper +tug +windsor2 +lynx +gargoyle +tyrus +sheava +omnis +le7b +contender +trophytruck +trophytruck2 +rallytruck +cliffhanger +bf400 +tropos +brioso +tampa2 +tornado6 +faggio3 +faggio +raptor +vortex +avarus +sanctus +youga2 +hakuchou2 +nightblade +chimera +esskey +wolfsbane +zombiea +zombieb +defiler +daemon2 +ratbike +shotaro +manchez +blazer4 +elegy +tempesta +italigtb +italigtb2 +nero +nero2 +specter +specter2 +diablous +diablous2 +blazer5 +ruiner2 +dune4 +dune5 +phantom2 +voltic2 +penetrator +boxville5 +wastelander +technical2 +fcr +fcr2 +comet3 +ruiner3 +turismo2 +infernus2 +gp1 +ruston +trailers4 +xa21 +caddy3 +vagner +phantom3 +nightshark +cheetah2 +torero +hauler2 +trailerlarge +technical3 +insurgent3 +apc +tampa3 +dune3 +trailersmall2 +halftrack +ardent +oppressor +vigilante +bombushka +alphaz1 +seabreeze +tula +havok +hunter +microlight +rogue +pyro +howard +mogul +starling +nokota +molotok +rapidgt3 +retinue +cyclone +visione +z190 +viseris +comet5 +raiden +riata +sc1 +autarch +savestra +gt500 +comet4 +neon +sentinel3 +khanjali +barrage +volatol +akula +deluxo +stromberg +chernobog +riot2 +avenger +avenger2 +thruster +yosemite +hermes +hustler +streiter +revolter +pariah +kamacho +entity2 +cheburek +jester3 +caracara +hotring +seasparrow +flashgt +ellie +michelli +fagaloa +dominator3 +tyrant +tezeract +gb200 +issi3 +taipan +blimp3 +mule4 +pounder2 +speedo4 +pbus2 +patriot2 +swinger +terbyte +oppressor2 +strikeforce +menacer +scramjet +freecrawler +stafford +bruiser +bruiser2 +bruiser3 +brutus +brutus2 +brutus3 +cerberus +cerberus2 +cerberus3 +clique +deathbike +deathbike2 +deathbike3 +deveste +deviant +dominator4 +dominator5 +dominator6 +impaler +impaler2 +impaler3 +impaler4 +imperator +imperator2 +imperator3 +issi4 +issi5 +issi6 +italigto +monster3 +monster4 +monster5 +rcbandito +scarab +scarab2 +scarab3 +schlagen +slamvan4 +slamvan5 +slamvan6 +toros +tulip +vamos +zr380 +zr3802 +zr3803 +caracara2 +drafter +dynasty +emerus +gauntlet3 +gauntlet4 +hellion +issi7 +jugular +krieger +locust +paragon +paragon2 +peyote2 +nebula +neo +novak +rrocket +s80 +thrax +zion3 +zorrusso +asbo +formula2 +formula +furia +imorgon +jb7002 +kanjo +komoda +minitank +outlaw +rebla +retinue2 +stryder +sugoi +sultan2 +vagrant +vstr +yosemite2 +zhaba`.split(/\r?\n/) +const locations = ['airport', 'spawn', 'fibroof', 'epsilon', 'policestation', 'yankton'] +const weapons = { + melee: { + dagger: '0x92A27487', + bat: '0x958A4A8F', + bottle: '0xF9E6AA4B', + crowbar: '0x84BD7BFD', + unarmed: '0xA2719263', + flashlight: '0x8BB05FD7', + golfclub: '0x440E4788', + hammer: '0x4E875F73', + hatchet: '0xF9DCBF2D', + knuckle: '0xD8DF3C3C', + knife: '0x99B507EA', + machete: '0xDD5DF8D9', + switchblade: '0xDFE37640', + nightstick: '0x678B81B1', + wrench: '0x19044EE0', + battleaxe: '0xCD274149', + poolcue: '0x94117305', + stone_hatchet: '0x3813FC08' + }, + handguns: { + pistol: '0x1B06D571', + pistol_mk2: '0xBFE256D4', + combatpistol: '0x5EF9FEC4', + appistol: '0x22D8FE39', + stungun: '0x3656C8C1', + pistol50: '0x99AEEB3B', + snspistol: '0xBFD21232', + snspistol_mk2: '0x88374054', + heavypistol: '0xD205520E', + vintagepistol: '0x83839C4', + flaregun: '0x47757124', + marksmanpistol: '0xDC4DB296', + revolver: '0xC1B3C3D1', + revolver_mk2: '0xCB96392F', + doubleaction: '0x97EA20B8', + raypistol: '0xAF3696A1', + ceramicpistol: '0x2B5EF5EC', + navyrevolver: '0x917F6C8C' + }, + smg: { + microsmg: '0x13532244', + smg: '0x2BE6766B', + smg_mk2: '0x78A97CD0', + assaultsmg: '0xEFE7E2DF', + combatpdw: '0xA3D4D34', + machinepistol: '0xDB1AA450', + minismg: '0xBD248B55', + raycarbine: '0x476BF155' + }, + shotguns: { + pumpshotgun: '0x1D073A89', + pumpshotgun_mk2: '0x555AF99A', + sawnoffshotgun: '0x7846A318', + assaultshotgun: '0xE284C527', + bullpupshotgun: '0x9D61E50F', + musket: '0xA89CB99E', + heavyshotgun: '0x3AABBBAA', + dbshotgun: '0xEF951FBB', + autoshotgun: '0x12E82D3D' + }, + assault_rifles: { + assaultrifle: '0xBFEFFF6D', + assaultrifle_mk2: '0x394F415C', + carbinerifle: '0x83BF0278', + carbinerifle_mk2: '0xFAD1F1C9', + advancedrifle: '0xAF113F99', + specialcarbine: '0xC0A3098D', + specialcarbine_mk2: '0x969C3D67', + bullpuprifle: '0x7F229F94', + bullpuprifle_mk2: '0x84D6FAFD', + compactrifle: '0x624FE830' + }, + machine_guns: { + mg: '0x9D07F764', + combatmg: '0x7FD62962', + combatmg_mk2: '0xDBBD7280', + gusenberg: '0x61012683' + }, + sniper_rifles: { + sniperrifle: '0x5FC3C11', + heavysniper: '0xC472FE2', + heavysniper_mk2: '0xA914799', + marksmanrifle: '0xC734385A', + marksmanrifle_mk2: '0x6A6C02E0' + }, + heavy_weapons: { + rpg: '0xB1CA77B1', + grenadelauncher: '0xA284510B', + grenadelauncher_smoke: '0x4DD2DC56', + minigun: '0x42BF8A85', + firework: '0x7F7497E5', + railgun: '0x6D544C99', + hominglauncher: '0x63AB0442', + compactlauncher: '0x781FE4A', + rayminigun: '0xB62D1F67' + }, + throwables: { + grenade: '0x93E220BD', + bzgas: '0xA0973D5E', + smokegrenade: '0xFDBC8A50', + flare: '0x497FACC3', + molotov: '0x24B17070', + stickybomb: '0x2C3731D9', + proxmine: '0xAB564B93', + snowball: '0x787F0BB', + pipebomb: '0xBA45E8B8', + ball: '0x23C9F95C' + }, + misc: { + petrolcan: '0x34A67B97', + fireextinguisher: '0x60EC506', + parachute: '0xFBAB5776', + hazardcan: '0xBA536372' + } +} + +let subMenuActive = false + +/* + Player panels START +*/ + +const helpMenu = new Menu("Помощь", "Помощь по игре на сервере", menuPos) +const listCommandsMenu = new Menu("Команды", "Узнайте список доступных команд", menuPos) + +// items +const commandsItem = new UIMenuItem('Достуные команды', Description = `Узнайте список доступных команд`) + +helpMenu.BindMenuToItem(listCommandsMenu, commandsItem) + +helpMenu.AddItem(commandsItem) + +listCommandsMenu.AddItem(new UIMenuItem('Copchase', Description = `/copchase`)) +listCommandsMenu.AddItem(new UIMenuItem('Появиться на спауне', Description = `/spawn`)) +listCommandsMenu.AddItem(new UIMenuItem('Узнать текущий онлайн', Description = `/online`)) + +helpMenu.Close() +listCommandsMenu.Close() + +helpMenu.ItemSelect.on(item => { + if (item instanceof UIMenuItem && item.Text.toLowerCase() === 'достуные команды') subMenuActive = true +}) + + +/* + Player panels END +*/ + +/* + Admin panels START +*/ + +// menus +const adminMenu = new Menu("Админ Панель", "Выполняйте админ-функции", menuPos) +const kickPlayerMenu = new Menu("Кикнуть игрока", "Сервер кикнет любого игрока", menuPos) +const banPlayerMenu = new Menu('Забанить игрока', "Сервер забанит игрока", menuPos) +const killPlayerMenu = new Menu('Убить игрока', "Сервер моментально убьет игрока", menuPos) +const carSpawnMenu = new Menu("Заспавнить машину", "Сервер заспавнит машину", menuPos) +const teleportToLocationMenu = new Menu("Телепорт к локации", "Телепортируйтесь на выбранную локацию", menuPos) +const myPersonMenu = new Menu("Мой персонаж", "Выберите что-то", menuPos) +const weaponsMenu = new Menu("Оружие", "Выберите оружие", menuPos) +const teleportToPlayerMenu = new Menu("Телепорт к игроку", "Вы телепортируетесь к игроку", menuPos) +const teleportToMeMenu = new Menu("Телепорт к себе", "Вы телепортируете игрока к себе", menuPos) + +// items +const kickItem = new UIMenuItem('Кикнуть игрока', Description = `Сервер кикнет игрока`) +const banItem = new UIMenuItem('Забанить игрока', Description = `Сервер заблокирует игрока`) +const killItem = new UIMenuItem('Убить игрока', Description = `Убейте моментально любого игрока`) +const spawnCarItem = new UIMenuItem('Заспавнить машину', Description = `Сервер заспавнит машину перед вами`) +const teleportToLocationItem = new UIMenuItem('Телепорт к локации', Description = `Телепортируйтесь к выбранной локации`) +const myPersonItem = new UIMenuItem('Мой персонаж', Description = `Выдайте себе здоровье или станьте неуязвимым`) +const weaponsItem = new UIMenuItem('Выдать себе оружие', Description = `Выдайте любое оружие себе`) +const teleportToPlayerItem = new UIMenuItem('Телепорт к игроку', Description = `Телепортируйтесь к игроку`) +const teleportToMeItem = new UIMenuItem('Телепорт игрока к себе', Description = `Телепортируйте игрока к себе`) + + +adminMenu.BindMenuToItem(kickPlayerMenu, kickItem) +adminMenu.BindMenuToItem(banPlayerMenu, banItem) +adminMenu.BindMenuToItem(killPlayerMenu, killItem) +adminMenu.BindMenuToItem(carSpawnMenu, spawnCarItem) +adminMenu.BindMenuToItem(teleportToLocationMenu, teleportToLocationItem) +adminMenu.BindMenuToItem(myPersonMenu, myPersonItem) +adminMenu.BindMenuToItem(weaponsMenu, weaponsItem) +adminMenu.BindMenuToItem(teleportToPlayerMenu, teleportToPlayerItem) +adminMenu.BindMenuToItem(teleportToMeMenu, teleportToMeItem) + +adminMenu.AddItem(myPersonItem) +adminMenu.AddItem(kickItem) +adminMenu.AddItem(banItem) +adminMenu.AddItem(killItem) +adminMenu.AddItem(spawnCarItem) +adminMenu.AddItem(weaponsItem) +adminMenu.AddItem(teleportToLocationItem) +adminMenu.AddItem(teleportToPlayerItem) +adminMenu.AddItem(teleportToMeItem) + +// kick items add + + // if (mp.players.toArray().filter(_player => _player.name !== mp.players.local.name) <= 0) { + // kickPlayerMenu.AddItem(new UIMenuItem('Игроков на сервере нет', Description = `На сервере никого нету кроме вас`)) + // } else { + // kickPlayerMenu.AddItem(new UIMenuListItem( + // "Игроки", + // "Выберите игрока чтобы кикнуть его", + // new ItemsCollection(mp.players.toArray().map(_player => _player.id)) + // )) + // } + + const playersListItem = new UIMenuListItem( + "Игроки", + "Выберите игрока", + new ItemsCollection(mp.players.toArray().map(_player => _player.name)) + ) + + kickPlayerMenu.AddItem(playersListItem) + banPlayerMenu.AddItem(playersListItem) + killPlayerMenu.AddItem(playersListItem) + teleportToPlayerMenu.AddItem(playersListItem) + teleportToMeMenu.AddItem(playersListItem) + + setInterval(() => { + playersListItem.Collection = new ItemsCollection(mp.players.toArray().map(_player => _player.name)).getListItems() + }, 300) + + // mp.events.add('updatePlayers', () => { + // playersListItem.Collection = new ItemsCollection(mp.players.toArray().map(_player => _player.name)).getListItems() + // }) + + +// carr items add +carSpawnMenu.AddItem(new UIMenuListItem( + "Список машин", + "Выберите машину и сервер заспавнит её", + new ItemsCollection(cars) +)) + + +teleportToLocationMenu.AddItem(new UIMenuListItem( + "Список локаций", + "Выберите локацию для телепортирования", + new ItemsCollection(locations) +)) + +myPersonMenu.AddItem(new UIMenuCheckboxItem( + "Неуязвимость", + false, + "Делает вашего персонажа неуязвимым" +)) + +myPersonMenu.AddItem(new UIMenuItem('Восстановить здоровье', Description = `Восстанавливает 100hp`)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Ближнее оружие", + "Выберите ближнее оружие", + new ItemsCollection(Object.keys(weapons["melee"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Пистолеты", + "Выберите пистолет", + new ItemsCollection(Object.keys(weapons["handguns"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Пистолет-пулеметы", + "Выберите пистолет-пулемет", + new ItemsCollection(Object.keys(weapons["smg"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Дробовики", + "Выберите дробовик", + new ItemsCollection(Object.keys(weapons["shotguns"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Штурмовые винтовки", + "Выберите штурмовую винтовку", + new ItemsCollection(Object.keys(weapons["assault_rifles"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Пулеметы", + "Выберите пулемет", + new ItemsCollection(Object.keys(weapons["machine_guns"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Снайперские винтовки", + "Выберите снайп.винтовку", + new ItemsCollection(Object.keys(weapons["sniper_rifles"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Тяжелое оружие", + "Выберите тяжелое оружие", + new ItemsCollection(Object.keys(weapons["heavy_weapons"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Гранаты", + "Выберите гранату", + new ItemsCollection(Object.keys(weapons["throwables"])) +)) + +weaponsMenu.AddItem(new UIMenuListItem( + "Разное", + "Выберите что-то", + new ItemsCollection(Object.keys(weapons["misc"])) +)) + +adminMenu.Close() +kickPlayerMenu.Close() +banPlayerMenu.Close() +killPlayerMenu.Close() +carSpawnMenu.Close() +teleportToLocationMenu.Close() +myPersonMenu.Close() +weaponsMenu.Close() +teleportToPlayerMenu.Close() +teleportToMeMenu.Close() + +adminMenu.ItemSelect.on(item => { + if (item instanceof UIMenuItem) subMenuActive = true +}) + +kickPlayerMenu.ItemSelect.on(item => { + mp.events.callRemote("[ui:kickPlayer]", item.SelectedItem.DisplayText); +}) + +banPlayerMenu.ItemSelect.on(item => { + mp.events.callRemote("[ui:banPlayer]", item.SelectedItem.DisplayText); +}) + +killPlayerMenu.ItemSelect.on(item => { + mp.events.callRemote("[ui:killPlayer]", item.SelectedItem.DisplayText); +}) + +teleportToPlayerMenu.ItemSelect.on(item => { + mp.events.callRemote("[ui:teleportToPlayer]", item.SelectedItem.DisplayText); +}) + +teleportToMeMenu.ItemSelect.on(item => { + mp.events.callRemote("[ui:teleportToMe]", item.SelectedItem.DisplayText); +}) + +carSpawnMenu.ItemSelect.on(item => { + if (item instanceof UIMenuListItem) return mp.events.callRemote("[ui:spawnCar]", item.SelectedItem.DisplayText) +}) + +teleportToLocationMenu.ItemSelect.on(item => { + mp.events.callRemote("[ui:teleportToLocation]", item.SelectedItem.DisplayText); +}) + +myPersonMenu.ItemSelect.on(item => { + if (item.Text.toLowerCase() === 'восстановить здоровье') mp.events.callRemote('[ui:getHealth]') +}) + +myPersonMenu.CheckboxChange.on(item => { + if (item.Text.toLowerCase() === 'неуязвимость') mp.events.callRemote('[ui:godMode]', item.Checked) +}) + +weaponsMenu.ItemSelect.on(item => { + if (item instanceof UIMenuListItem) return mp.events.callRemote("[ui:giveWeapon]", item.SelectedItem.DisplayText) +}) + +/* + Admin panels END +*/ + +mp.keys.bind(0x50, false, () => { + if (mp.players.local.isTypingInTextChat) return false + if (helpMenu.Visible) helpMenu.Close() + + if (subMenuActive) return false + + mp.events.callRemote('[ui:showAdminPanel]') +}) // P - admin panel + +mp.keys.bind(0x48, false, () => { + if (mp.players.local.isTypingInTextChat) return false + if (adminMenu.Visible) adminMenu.Close() + + if (subMenuActive) return false + + mp.events.callRemote('[ui:showHelpPanel]') +}) // H - help menu + +mp.keys.bind(0x08, false, () => subMenuActive = false) // backspace +mp.keys.bind(0x02, false, () => { + mp.gui.chat.push('s') +}) + +mp.events.add('onShowAdminPanel', () => { + if (subMenuActive) return false + if (helpMenu.Visible || listCommandsMenu.Visible) { + helpMenu.Close() + listCommandsMenu.Close() + } + + adminMenu.Visible ? adminMenu.Close() : adminMenu.Open() +}) + +mp.events.add('onShowHelpPanel', () => helpMenu.Visible ? helpMenu.Close() : helpMenu.Open()) + diff --git a/packages/copchase/api/index.js b/packages/copchase/api/index.js new file mode 100644 index 0000000..ec7ace9 --- /dev/null +++ b/packages/copchase/api/index.js @@ -0,0 +1,44 @@ +const copchaseConfig = require('../copchase-config') + +class API { + constructor(players) { + this.players = players + this.authenticatedPlayers = [] + this.blips = {} + } + + authenticatedPlayers() { + return this.authenticatedPlayers + } + + addAuthPlayer(player) { + this.authenticatedPlayers.push({ + id: player.id, + name: player.name + }) + } + + delAuthPlayer(player) { + const index = this.authenticatedPlayers.findIndex(_player => _player.name === player.name) + + if (index != -1) this.authenticatedPlayers.splice(index, 1) + } + + isPlayerLoggedIn(player) { + if (this.authenticatedPlayers.find(_player => _player.name === player.name)) { + return true + } else { + return false + } + } + + isPlayerAdmin(candidate) { + if (copchaseConfig.admins.find(admin => candidate.name === admin.name)) { + return true + } else { + return false + } + } +} + +module.exports = API \ No newline at end of file diff --git a/packages/copchase/commands/admin/admin.js b/packages/copchase/commands/admin/admin.js new file mode 100644 index 0000000..b3521d5 --- /dev/null +++ b/packages/copchase/commands/admin/admin.js @@ -0,0 +1,258 @@ +const copchaseConfig = require('../../copchase-config') +require('../../events/skin') + +module.exports = ({ api }) => { + mp.events.addCommand('skin', (player, model) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + if (model >= 722 || !model || isNaN(model)) player.outputChatBox('!{orange}[SERVER]: !{white}/skin [0-722]') + + player.model = ped.skin[model] + }) + /* + Check if player admin + !auth + */ + + mp.events.addCommand('admin', (player) => { + + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + player.call('onShowAdminPanel') + }) + + /* + Ban player + */ + + mp.events.addCommand('ban', (player, target) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + let newTarget = mp.players.at(target); + + if(!target || isNaN(target)) return player.outputChatBox("!{orange}[SERVER]: /ban [id игрока]"); + if(newTarget === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + newTarget.outputChatBox("!{orange}[SERVER]: !{red}Вы были заблокированы на этом сервере."); + newTarget.ban('Заблокирован!'); + }) + + /* + Teleport to location + */ + + mp.events.addCommand('to', (player, location) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + const findLocation = Object.keys(copchaseConfig.locations).find(_location => _location === location) + + if (findLocation === undefined) { + player.outputChatBox('!{orange}[SERVER]: !{red}Локация не найдена') + return false + } + + player.position = copchaseConfig.locations[location] + }) + + /* + Teleport to player + */ + + mp.events.addCommand('tp', (player, target) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + let newTarget = mp.players.at(target); + + if(!target || isNaN(target)) return player.outputChatBox("!{orange}[SERVER]: !{white}/tp [id игрока]"); + if(newTarget === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + + player.position = newTarget.position + }) + + /* + Teleport to player to admin + */ + + mp.events.addCommand('gethere', (player, target) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + let newTarget = mp.players.at(target); + + if(!target || isNaN(target)) return player.outputChatBox("!{orange}[SERVER]: !{white}/gethere [id игрока]"); + if(newTarget === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + + newTarget.spawn(player.position) + }) + + /* + Kick player + */ + + mp.events.addCommand('kick', (player, target) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + let newTarget = mp.players.at(target); + if(!target || isNaN(target)) return player.outputChatBox("!{orange}[SERVER]: !{white}/kick [id игрока]"); + if (newTarget === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + + mp.players.forEach(_player => _player.outputChatBox(`!{orange}[SERVER]: !{white}Игрок !{1CD8FD}${newTarget.name} !{white}был кикнут с сервера`)) + newTarget.notify('Вы были кикнуты с сервера') + setTimeout(() => newTarget.kick('Кикнут.'), 300) + }); + + /* + Get position + !auth + */ + + mp.events.addCommand('pos', player => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + player.outputChatBox(`Pos: ${player.position}`) + }) + + /* + Create car on Spawn + */ + + mp.events.addCommand('car', (player, carRef) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + if (carRef === undefined) { + player.outputChatBox('!{orange}[SERVER]: !{white}/car [reference машины]') + return false + } + + const car = mp.vehicles.new(mp.joaat(carRef), player.position) + + car.setColor(0, 0, 0) + car.numberPlate = 'ADMIN' + car.dimension = player.dimension + + setTimeout(() => player.putIntoVehicle(car, 0), 200) + }) + + mp.events.addCommand('carHealth', (player, string, health) => { + if(player.vehicle) { + if(!string) { + return player.outputChatBox("!{orange}[SERVER]: !{white}/carHealth [value]"); + } + player.eval(`mp.players.local.vehicle.setEngineHealth(${health})`) + } else { + return player.outputChatBox("!{orange}[SERVER]: !{red}Вы должны находться в машине!"); + } +}); + + /* + Kill player by id + */ + + mp.events.addCommand('kill', (player, target) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + let newTarget = mp.players.at(target); + if(!target || isNaN(target)) return player.outputChatBox("/kill [id игрока]"); + if (newTarget === undefined) { + return player.outputChatBox("!{red}Игрока с таким ID не найдено.") + } + + newTarget.health = 0 + newTarget.outputChatBox(`!{orange}Вы были убиты администратором: !{gold}${player.name}`) + }) + + mp.events.addCommand('weather', (player, weather) => { + + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + if (weather === undefined) return player.outputChatBox(`!{orange}[SERVER]: !{white}/weather [name]`) + + mp.world.weather = weather.toLowerCase() + }) +} \ No newline at end of file diff --git a/packages/copchase/commands/player/player.js b/packages/copchase/commands/player/player.js new file mode 100644 index 0000000..b372b09 --- /dev/null +++ b/packages/copchase/commands/player/player.js @@ -0,0 +1,159 @@ +const bcrypt = require('bcryptjs') +const { Player } = require('../../models/index') +const copchaseConfig = require('../../copchase-config') + +module.exports = ({ api, copchase }) => { + + /* + Show Online + !auth + */ + + mp.events.addCommand('online', player => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + player.outputChatBox(`!{orange}[SERVER]: !{white}Онлайн сейчас: !{1CD8FD}${mp.players.length}`) + }) + + /* + Register Player + !auth + */ + + mp.events.addCommand('reg', (player, message) => { + const candidate = api.players.filter(_player => _player.name === player.name) + + if (candidate.length > 0) { + player.outputChatBox(copchaseConfig.messages.accountRegistered) + return false + } + + if (api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.authenticated) + return false + } + + if (message === undefined) { + player.outputChatBox('!{orange}[SERVER]: !{red}Введите пароль для регистрации') + return false + } + + const passwords = message.split(' ') + + if (passwords[0] === passwords[1]) { + try { + if (candidate.length <= 0) { + + player.outputChatBox('!{orange}[SERVER]: !{white}Регистируем аккаунт...') + const newPlayer = new Player({ + name: player.name, + password: bcrypt.hashSync(message.split(' ')[0], bcrypt.genSaltSync(10)) + }) + + newPlayer.save().then((data) => api.players.push(data)) + + player.notify('~g~Аккаунт зарегистрирован!') + player.outputChatBox(`!{orange}[SERVER]: !{white}/login [пароль] !{green}для авторизации.`) + console.log(`Игрок с ником ${player.name} зарегистрировался!`) + } else { + player.notify('~r~Вы уже зарегистрированы!') + } + } catch (error) { + player.notify('~r~Произошла ошибка!') + } + } else { + player.notify('~r~Пароли не совпадают!') + } + }) + + /* + Login Player + !auth + */ + + mp.events.addCommand('login', (player, message) => { + if (api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.authenticated) + return false + } + + const candidatePassword = message + const currentPlayer = api.players.filter(currentPlayer => currentPlayer.name === player.name) + + if (currentPlayer.length <= 0) { + player.notify('~r~Вы еще не зарегистрировали аккаунт!') + return false + } + + if (message === undefined) { + player.notify('~r~Введите пароль!') + return false + } + + bcrypt.compare(candidatePassword, currentPlayer[0].password, function(err, res) { + if (err){ + player.notify('~r~Произошла ошибка при авторизации!') + } + + if (res) { + player.notify('~g~Вы авторизовались!') + player.call('login', [player]) // выключить фриз + + api.addAuthPlayer(player) + console.log(api.authenticatedPlayers) + } else { + player.notify('~r~Неверный пароль!') + } + }) + }) + + /* + Spawn + !auth + */ + + mp.events.addCommand('spawn', player => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (copchase.isPlayerInWaitingRoom(player)) return false + if (copchase.isPlayerInGame(player)) return false + + player.dimension = 0 + player.position = copchaseConfig.spawn + }) + + mp.events.addCommand('copchase', player => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (copchase.isPlayerInWaitingRoom(player)) return false + if (copchase.isPlayerInGame(player)) return false + + player.dimension = copchase.waitingRoomDimension + player.position = copchaseConfig.waitingRoom + + copchase.addPlayerToWaitingRoom(player) // добавить игрока в комнату ожидания + player.call('setInv', [player]) + + if (copchase.isStarted && copchase.players.length > 0) { + return player.outputChatBox('!{orange}[SERVER]: !{blue}Игра уже начата! Ожидание игроков...') + } + + if (copchase.waitingPlayers.length < copchase.minPlayers) { + return player.outputChatBox('!{orange}[SERVER]: !{blue}Ожидание игроков...') + } + + copchase.startGame() + + }) +} + + diff --git a/packages/copchase/copchase-config.js b/packages/copchase/copchase-config.js new file mode 100644 index 0000000..e018b6f --- /dev/null +++ b/packages/copchase/copchase-config.js @@ -0,0 +1,25 @@ +module.exports = { + spawn: { x: -425.446, y: 1123.767, z: 325.854 }, + waitingRoom: { x: 135.901, y: -749.107, z: 258.152 }, + locations: { + airport: { x: -1329.613, y: -3038.4901286875747, z: 13.938 }, + spawn: { x: 135.901, y: -749.107, z: 258.152 }, + fibroof: { x:150.126, y:-754.591, z:262.865 }, + policestation: { x:436.491, y: -982.172, z: 30.699 }, + epsilon: { x:-695.025, y: 82.955, z: 55.855}, + yankton: { x: 5331.8583, y: -5181.8349609375, z: 82.77088928222656 } + }, + admins: [ + { name: 'kinguinmlg' }, + { name: 'Dynya' }, + { name: 'Dynya1' }, + { name: 'ch3ks1' } + ], + messages: { + register: '!{orange}[SERVER]: !{green}Регистрация: !{white}/reg [пароль] [пароль]', + accountRegistered: '!{orange}[SERVER]: !{red}Аккаунт уже зарегистрирован!', + authenticated: '!{orange}[SERVER]: !{red}Вы уже авторизованы!', + notAuthenticated: '!{orange}[SERVER]: !{red}Авторизуйтесь!', + notAvailable: '!{orange}[SERVER]: !{red}Вам недоступна эта команда' + } +} \ No newline at end of file diff --git a/packages/copchase/copchase.js b/packages/copchase/copchase.js new file mode 100644 index 0000000..89f0565 --- /dev/null +++ b/packages/copchase/copchase.js @@ -0,0 +1,290 @@ +const copchaseConfig = require('./copchase-config') + +class Copchase { + constructor({ dimension, waitingRoomDimension, minPlayers, maxPlayers, timeRemaining, timeToStart }) { + this.dimension = dimension + this.waitingRoomDimension = waitingRoomDimension + this.minPlayers = minPlayers + this.maxPlayers = maxPlayers + this.timeRemaining = timeRemaining + this.timeRemainingInterval = null + this.timeToStart = timeToStart + this.isStarted = false + this.suspectCars = [ + 'asea', + 'bison', + 'bobcatxl', + 'burrito', + 'emperor', + 'emperor2', + 'ardent', + 'ingot', + 'journey', + 'clique', + 'vamos', + 'tulip', + 'stafford', + 'cheburek', + 'streiter', + 'nebula', + 'hellion', + 'gauntlet4' + ] + this.weather = [ + 'EXTRASUNNY', + 'CLEAR', + 'CLOUDS', + 'SMOG', + 'FOGGY', + 'OVERCAST', + 'RAIN', + 'THUNDER', + 'CLEARING', + 'NEUTRAL', + 'SNOW', + 'BLIZZARD', + 'SNOWLIGHT', + 'XMAS', + 'HALLOWEEN' + ] + this.players = [] + this.waitingPlayers = [] + this.cars = [] + this.blips = {} + this.suspect = null + this.positions = { + suspect: [ + { x: 395.185, y: -999.645, z: 28.755 }, + { x: 404.691, y: -1907.0604, z: 24.723 }, + { x: 2619.436, y: 3374.145, z: 55.619 } + ], + police: [ + { x: 442.308, y: -1025.066, z: 28.231 }, + { x: 348.865, y: -1966.507, z:24.133 }, + { x: 2678.454, y: 3459.637, z: 55.340 } + ] + } + } + + pushWaitingPlayersToGame(waitingPlayers) { + waitingPlayers.forEach(_player => this.players.push(_player)) + this.waitingPlayers = [] + } + + messageToWaitingPlayers(message) { + this.waitingPlayers.forEach(_player => _player.outputChatBox(message)) + } + + messageToPlayersInGame(message) { + this.players.forEach(_player => _player.outputChatBox(message)) + } + + notifyPolicePlayers(message) { + this.players.forEach(_player => _player.name !== this.suspect.name ? _player.notify(message) : false) + } + + notifySuspectPlayer(message) { + this.suspect.notify(message) + } + + addPlayerToWaitingRoom(player) { + this.waitingPlayers.push(player) + } + + setDefaultState() { + this.timeRemainingInterval = null + this.isStarted = false + this.suspect = null + this.players = [] + this.waitingPlayers = [] + this.blips = {} + + setTimeout(() => { + this.cars.forEach(car => car.destroy()) + this.cars = [] + }, 3000) + } + + isPlayerInGame(player) { + if(this.players.find(_player => _player.name === player.name) !== undefined) { + player.outputChatBox('!{orange}[COPCHASE]: !{red}Дождитесь окончания игры!') + return true + } else { + return false + } + } + + isPlayerInWaitingRoom(player) { + if(this.waitingPlayers.find(_player => _player.name === player.name) !== undefined) { + player.outputChatBox('!{orange}[COPCHASE]: !{red}Вы уже в комнате ожидания!') + return true + } else { + return false + } + } + + selectSuspect() { + this.suspect = this.players[Math.floor(Math.random() * (this.players.length - 1 - 0 + 1) + 0)] + } + + startGame() { + let timeToStart = this.timeToStart + const interval = setInterval(() => { + timeToStart = timeToStart - 1 + + if (timeToStart <= 0) { + this.isStarted = true + + this.pushWaitingPlayersToGame(this.waitingPlayers) + this.selectSuspect() + + this.messageToPlayersInGame(`!{orange}[COPCHASE]: !{blue}Игра началась!`) + this.messageToPlayersInGame(`!{orange}[COPCHASE]: !{white}Саспект: !{red}${this.suspect.name}`) + this.notifyPolicePlayers(`~w~ Остановите саспекта!`) + this.notifySuspectPlayer(`~w~ Уйдите от полицейских!`) + + + // spawn cars and players + this.spawnPlayers().then(() => { + setTimeout(() => this.spawnCars(), 1000) + }) + + setInterval(() => { + this.players.forEach((player, id) => { + if (this.blips[player.id] && player.health > 0) { + this.blips[player.id].position = player.position; + } + }) + }, 1000) + + mp.world.weather = this.weather[Math.floor(Math.random() * (this.weather.length - 1 - 0) + 0)] + + let timeRemaining = this.timeRemaining + this.timeRemainingInterval = setInterval(() => { + timeRemaining = timeRemaining - 1 + if (timeRemaining !== 0) { + this.messageToPlayersInGame(`!{orange}[COPCHASE]: !{white}Время до окончания: !{blue}${timeRemaining} !{white}мин.`) + } + + if (timeRemaining <= 0) { + this.stopGame('suspect') + + clearInterval(this.timeRemainingInterval) + return true + } + }, 60000) + + clearInterval(interval) + return true + } + + this.messageToWaitingPlayers(`!{orange}[COPCHASE]: !{blue}Игра начнется через: !{white}${timeToStart}`) + }, 1000) + } + + stopGame(type) { + + clearInterval(this.timeRemainingInterval) + + this.players.forEach(_player => { + if (this.blips[_player.id]) { + this.blips[_player.id].destroy(); + } + + setTimeout(() => { + _player.dimension = 0 + _player.health = 100 + _player.position = copchaseConfig.spawn + _player.removeAllWeapons() + _player.call('setInv', [_player]) + }, 3000) + }) + + this.setDefaultState() + + if (type === 'police') { + mp.players.forEach(_player => { + _player.outputChatBox(`!{orange}[COPCHASE]: !{blue}Игра закончилась. Полиция выиграла!`) + _player.outputChatBox(`!{orange}[COPCHASE]: !{white}/copchase !{blue} для повторной игры`) + }) + + console.log(`[COPCHASE]: Игра закончилась! Полиция выиграла!`) + } + + if (type === 'suspect') { + mp.players.forEach(_player => { + _player.outputChatBox(`!{orange}[COPCHASE]: !{blue}Игра закончилась. Саспект выиграл!`) + _player.outputChatBox(`!{orange}[COPCHASE]: !{blue}/copchase !{white} для повторной игры`) + }) + + console.log(`[COPCHASE]: Игра закончилась! Саспект выиграл!`) + } + } + + spawnPlayers() { + let suspectRandomNumber = Math.floor(Math.random() * this.positions.suspect.length) + let suspectPosition = this.positions.suspect[suspectRandomNumber] + + return new Promise((resolve, reject) => { + this.players.forEach(_player => { + if (_player.name === this.suspect.name) { + _player.position = suspectPosition + _player.dimension = this.dimension + _player.model = ped.skin[Math.floor(Math.random() * (435 - 432) + 432)] + _player.call('delInv', [_player]) + + this.blips[_player.id] = mp.blips.new(1, suspectPosition) + this.blips[_player.id].name = _player.name + this.blips[_player.id].dimension = this.dimension + this.blips[_player.id].color = 1 + } else { + _player.position = { + x: this.positions.police[suspectRandomNumber].x + 2, + y: this.positions.police[suspectRandomNumber].y, + z: this.positions.police[suspectRandomNumber].z + } + _player.heading = 260 + _player.dimension = this.dimension + _player.model = ped.skin[625] + _player.call('delInv', [_player]) + _player.giveWeapon(mp.joaat('weapon_stungun'), 99999) + + this.blips[_player.id] = mp.blips.new(1, suspectPosition) + this.blips[_player.id].name = _player.name + this.blips[_player.id].dimension = this.dimension + this.blips[_player.id].color = 38 + } + }) + + resolve() + }) + } + + spawnCars() { + this.players.forEach(_player => { + if (_player.name === this.suspect.name) { + const carSuspect = mp.vehicles.new(mp.joaat(this.suspectCars[Math.floor(Math.random() * (this.suspectCars.length - 1 - 0) + 0)]), _player.position, { + dimension: this.dimension + }) + + carSuspect.setColor(0, 0, 0) + carSuspect.numberPlate = 'suspect' + _player.putIntoVehicle(carSuspect, 0) + + this.cars.push(carSuspect) + } else { + const carPolice = mp.vehicles.new(mp.joaat('police3'), _player.position, { + dimension: this.dimension + }) + + carPolice.setColor(0, 0, 0) + carPolice.numberPlate = 'police' + _player.putIntoVehicle(carPolice, 0) + + this.cars.push(carPolice) + } + }) + } +} + +module.exports = Copchase \ No newline at end of file diff --git a/packages/copchase/events/admin/admin.js b/packages/copchase/events/admin/admin.js new file mode 100644 index 0000000..2c8a846 --- /dev/null +++ b/packages/copchase/events/admin/admin.js @@ -0,0 +1,153 @@ +const copchaseConfig = require('../../copchase-config') + +module.exports = ({ api }) => { + mp.events.add('[ui:showAdminPanel]', player => { + if (api.isPlayerLoggedIn(player) && api.isPlayerAdmin(player)) player.call('onShowAdminPanel') + }) + mp.events.add('[ui:kickPlayer]', (player, targetName) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + const target = mp.players.toArray().find(_player => _player.name === targetName) + + if (target === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + + mp.players.forEach(_player => _player.outputChatBox(`!{orange}[SERVER]: !{white}Игрок !{1CD8FD}${target.name} !{white}был кикнут с сервера`)) + target.notify('Вы были кикнуты с сервера') + setTimeout(() => target.kick('Кикнут.'), 300) + + player.call('updatePlayers') + }) + mp.events.add('[ui:banPlayer]', (player, targetName) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + const target = mp.players.toArray().find(_player => _player.name === targetName) + + if (target === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + + mp.players.forEach(_player => _player.outputChatBox(`!{orange}[SERVER]: !{white}Игрок !{1CD8FD}${target.name} !{white}был заблокирован`)) + target.notify('Вы были заблокированы на этом сервере') + setTimeout(() => target.ban('Заблокирован.'), 300) + }) + mp.events.add('[ui:killPlayer]', (player, targetName) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + const target = mp.players.toArray().find(_player => _player.name === targetName) + + if (target === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + + target.notify('Вы были убиты администратором сервера') + target.health = 0 + }) + mp.events.add('[ui:teleportToPlayer]', (player, targetName) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + const target = mp.players.toArray().find(_player => _player.name === targetName) + + if (target === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + + player.notify(`Вы телепортировались к игроку ${target.name}`) + player.position = target.position + }) + mp.events.add('[ui:teleportToMe]', (player, targetName) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + if (!api.isPlayerAdmin(player)) { + player.outputChatBox(copchaseConfig.messages.notAvailable) + return false + } + + const target = mp.players.toArray().find(_player => _player.name === targetName) + + if (target === undefined) return player.outputChatBox("!{orange}[SERVER]: !{red}Игрока с таким ID не найдено.") + + player.notify(`Игрок ${target.name} был телепортирован к вам`) + target.notify(`Вы были телепортированы администратором`) + + target.position = player.position + }) + mp.events.add('[ui:spawnCar]', (player, carRef) => { + if (api.isPlayerLoggedIn(player) && api.isPlayerAdmin(player)) { + + const car = mp.vehicles.new(mp.joaat(carRef), player.position) + + car.setColor(0, 0, 0) + car.numberPlate = 'ADMIN' + car.dimension = player.dimension + + setTimeout(() => player.putIntoVehicle(car, 0), 200) + } + }) + + mp.events.add('[ui:teleportToLocation]', (player, location) => { + if (api.isPlayerLoggedIn(player) && api.isPlayerAdmin(player)) { + const findLocation = Object.keys(copchaseConfig.locations).find(_location => _location === location) + + if (findLocation === undefined) { + player.outputChatBox('!{orange}[SERVER]: !{red}Локация не найдена') + return false + } + + player.position = copchaseConfig.locations[location] + } + }) + + mp.events.add('[ui:godMode]', (player, godmode) => { + if (api.isPlayerLoggedIn(player) && api.isPlayerAdmin(player)) { + player.call('onGodMode', [player, godmode]) + godmode ? player.notify(`Режим неуязвимости: вкл`) : player.notify(`Режим неуязвимости: выкл`) + } + }) + + mp.events.add('[ui:getHealth]', player => { + if (api.isPlayerLoggedIn(player) && api.isPlayerAdmin(player)) { + player.health = 100 + player.notify(`Ваше здоровье было восстановлено!`) + } + }) + + mp.events.add('[ui:giveWeapon]', (player, weaponRef) => { + if (api.isPlayerLoggedIn(player) && api.isPlayerAdmin(player)) { + if (weaponRef === 'parachute') { + player.giveWeapon(mp.joaat(`gadget_${weaponRef}`), 99999) + return false + } + + player.giveWeapon(mp.joaat(`weapon_${weaponRef}`), 99999) + } + }) +} \ No newline at end of file diff --git a/packages/copchase/events/player/player.js b/packages/copchase/events/player/player.js new file mode 100644 index 0000000..7a451b9 --- /dev/null +++ b/packages/copchase/events/player/player.js @@ -0,0 +1,164 @@ +const copchaseConfig = require('../../copchase-config'); + +const { getDistance } = require('../../helpers/getDistance') + +module.exports = ({ api, copchase }) => { + const putIntoVehicleKey = Symbol('putIntoVehicle'); + + mp.events.add('entityCreated', entity => { + if (entity.type !== 'player') { + return; + } + + entity[putIntoVehicleKey] = entity.putIntoVehicle; + entity.putIntoVehicle = (vehicle, seat) => { + setTimeout(() => { + entity[putIntoVehicleKey](vehicle, seat); + }, 400); + }; + }) + + mp.events.add("playerExitVehicle", (player, vehicle, seat) => { + + if (copchase.isStarted && player.name === copchase.suspect.name) { + player.giveWeapon(mp.joaat('weapon_pistol'), 25); + + copchase.players.forEach(_player => { + if (_player.name !== copchase.suspect.name) { + _player.giveWeapon(mp.joaat('weapon_pistol'), 50); + } + }) + } + }) + + mp.events.add('playerEnterVehicle', (player, vehicle, seat) => { + if (copchase.isStarted && player.name === copchase.suspect.name && seat === 0) { + player.call('setCarHealth') + } + + return false + }) + + /* + Player has been joined to the server + */ + + mp.events.add('playerJoin', player => { + const candidate = api.players.filter(_player => _player.name === player.name) + + console.log(`[SERVER]: ${player.name} присоеденился к серверу!`); + mp.players.forEach(_player => _player.outputChatBox(`!{orange}[SERVER]: !{1CD8FD}✋ [${player.id}: ${player.name}] !{white}присоеденился`)) + + player.spawn(copchaseConfig.spawn) + player.dimension = 0 + player.model = ped.skin[Math.floor(Math.random() * (722 - 35) + 35)] + + + candidate <= 0 + ? player.call('playerJoin', [player, copchaseConfig.messages.register]) + : player.call('playerJoin', [player, `!{orange}[SERVER]: !{white}/login [пароль] !{green}для авторизации`]) + }) + + mp.events.add("playerQuit", player => { + if (copchase.isStarted) { + if (player.name === copchase.suspect.name) copchase.stopGame('police') + + const policemanIndex = copchase.players.findIndex(_player => _player.name === player.name && _player.name !== copchase.suspect.name) + + if (policemanIndex !== -1) copchase.players.splice(policemanIndex, 1) + if (copchase.players.length <= 1 && copchase.suspect !== null) copchase.stopGame('suspect') + } + + api.delAuthPlayer(player) // удаляем игрока из массива с авторизованными игроками + console.log(`[SERVER]: игрок ${player.name} отсоеденился`) + console.log(api.authenticatedPlayers) + mp.players.forEach(_player => _player.outputChatBox(`!{orange}[SERVER]: !{1CD8FD}[${player.name}] !{white}покинул нас`)) + }) + + /* + When player send message to the chat + */ + mp.events.add("playerChat", (player, message) => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + mp.players.forEach(_player => _player.outputChatBox(`!{orange}[${player.id}]: !{1CD8FD}${player.name} !{white}${message}`)) + }) + + /* + Unknown command in chat + */ + + mp.events.add('playerCommand', (player, command) => { + if (player.health <= 0) return false + player.outputChatBox(`!{orange}[SERVER]: !{red}Команды "${command}" не существует`) + player.outputChatBox(`!{orange}[SERVER]: !{red}Нажмите !{1CD8FD}H !{red}для помощи`) + }) + + mp.events.add('onPlayerDamage', (player) => { + if (copchase.isStarted) { + return false + } + + player.call('setInv', [player]) + }) + /* + On Player death + */ + + mp.events.add('playerDeath', player => { + if (copchase.isStarted) { + if (player.name === copchase.suspect.name) copchase.stopGame('police') + + const policemanIndex = copchase.players.findIndex(_player => _player.name === player.name && _player.name !== copchase.suspect.name) + + if (policemanIndex !== -1) copchase.players.splice(policemanIndex, 1) + if (copchase.players.length <= 1 && copchase.suspect !== null) copchase.stopGame('suspect') + } + + player.removeAllWeapons() + + mp.players.forEach(_player => _player.notify(`Игрок ${player.name} погиб`)) + + setTimeout(() => { + // player.health = 100 + // player.position = copchaseConfig.spawn + player.spawn(copchaseConfig.spawn) + player.dimension = 0 + player.call('setInv', [player]) + }, 3000) + }) + + mp.events.add('voiceEnable', player => { + mp.players.forEach(_player => { + let distance = getDistance(_player.position, player.position) + if(player == _player) return false; + + if (distance <= 10) { + player.enableVoiceTo(_player); + console.log(`${player.name} что-то говорит`) + } + }) + }) + + mp.events.add('voiceDisable', player => { + mp.players.forEach(_player => { + if(player == _player) return false; + + player.disableVoiceTo(_player); + console.log(`${player.name} перестал говорить`) + }) + }) + + mp.events.add('[ui:showHelpPanel]', player => { + if (!api.isPlayerLoggedIn(player)) { + player.outputChatBox(copchaseConfig.messages.notAuthenticated) + return false + } + + player.call('onShowHelpPanel') + }) +} + diff --git a/packages/copchase/events/skin.js b/packages/copchase/events/skin.js new file mode 100644 index 0000000..7309648 --- /dev/null +++ b/packages/copchase/events/skin.js @@ -0,0 +1,725 @@ +global.ped = { + skin: mp.joaat(["A_C_Boar", + "A_C_Chickenhawk", + "A_C_Chimp", + "A_C_Chop", + "A_C_Cormorant", + "A_C_Cow", + "A_C_Coyote", + "A_C_Crow", + "A_C_Deer", + "A_C_Fish", + "A_C_Hen", + "A_C_Husky", + "A_C_MtLion", + "A_C_ig", + "A_C_igeon", + "A_C_Rat", + "A_C_Retriever", + "A_C_Rhesus", + "A_C_Rottweiler", + "A_C_Seagull", + "A_C_SharkTiger", + "A_C_shepherd", + "A_F_M_Beach_01", + "A_F_M_BevHills_01", + "A_F_M_BevHills_02", + "A_F_M_BodyBuild_01", + "A_F_M_Business_02", + "A_F_M_Downtown_01", + "A_F_M_EastSA_01", + "A_F_M_EastSA_02", + "A_F_M_FatBla_01", + "A_F_M_FatCult_01", + "A_F_M_FatWhite_01", + "A_F_M_KTown_01", + "A_F_M_KTown_02", + "A_F_M_rolHost_01", + "A_F_M_Salton_01", + "A_F_M_SkidRow_01", + "A_F_M_SouCent_01", + "A_F_M_SouCent_02", + "A_F_M_SouCentMC_01", + "A_F_M_Tourist_01", + "A_F_M_Tramp_01", + "A_F_M_TrampBeac_01", + "A_F_O_DesStreet_01", + "A_F_O_GenStreet_01", + "A_F_O_Indian_01", + "A_F_O_KTown_01", + "A_F_O_Salton_01", + "A_F_O_SouCent_01", + "A_F_O_SouCent_02", + "A_F_Y_Beach_01", + "A_F_Y_BevHills_01", + "A_F_Y_BevHills_02", + "A_F_Y_BevHills_03", + "A_F_Y_BevHills_04", + "A_F_Y_Business_01", + "A_F_Y_Business_02", + "A_F_Y_Business_03", + "A_F_Y_Business_04", + "A_F_Y_EastSA_01", + "A_F_Y_EastSA_02", + "A_F_Y_EastSA_03", + "A_F_Y_Epsilon_01", + "A_F_Y_Fitness_01", + "A_F_Y_Fitness_02", + "A_F_Y_GenAsian01", + "A_F_Y_GenHot_01", + "A_F_Y_Golfer_01", + "A_F_Y_Hiker_01", + "A_F_Y_Hippie_01", + "A_F_Y_Hipster_01", + "A_F_Y_Hipster_02", + "A_F_Y_Hipster_03", + "A_F_Y_Hipster_04", + "A_F_Y_Indian_01", + "A_F_Y_Juggalo_01", + "A_F_Y_Runner_01", + "A_F_Y_RurMeth_01", + "A_F_Y_SCDressy_01", + "A_F_Y_SilverHip_01", + "A_F_Y_Skater_01", + "A_F_Y_Skivill_02", + "A_F_Y_SouCent_01", + "A_F_Y_SouCent_02", + "A_F_Y_SouCent_03", + "A_F_Y_Streetlady", + "A_F_Y_Tennis_01", + "A_F_Y_Topless_01", + "A_F_Y_Tourist_01", + "A_F_Y_Tourist_02", + "A_F_Y_Vinewood_01", + "A_F_Y_Vinewood_02", + "A_F_Y_Vinewood_03", + "A_F_Y_Vinewood_04", + "A_F_Y_Yoga_01", + "A_M_M_ACult_01", + "A_M_M_AfriAmer_01", + "A_M_M_Beach_01", + "A_M_M_Beach_02", + "A_M_M_BevHills_01", + "A_M_M_BevHills_02", + "A_M_M_Business_01", + "A_M_M_DesBeg_01", + "A_M_M_DesRebel_02", + "A_M_M_DesRebel_04", + "A_M_M_EastSA_01", + "A_M_M_EastSA_02", + "A_M_M_Farmer_01", + "A_M_M_FatLatin_01", + "A_M_M_GenFat_01", + "A_M_M_GenFat_02", + "A_M_M_Golfer_01", + "A_M_M_HasJew_01", + "A_M_M_Hillbilly_01", + "A_M_M_Hillbilly_02", + "A_M_M_Indian_01", + "A_M_M_KTown_01", + "A_M_M_Malibu_01", + "A_M_M_MexCntry_01", + "A_M_M_MexLabor_01", + "A_M_M_OG_Boss_01", + "A_M_M_aparazzi_01", + "A_M_M_olynesian_01", + "A_M_M_rolHost_01", + "A_M_M_RurMeth_01", + "A_M_M_Salton_01", + "A_M_M_Salton_02", + "A_M_M_Salton_03", + "A_M_M_Salton_04", + "A_M_M_Skater_01", + "A_M_M_Skidrow_01", + "A_M_M_SkiVill_07", + "A_M_M_SoCenLat_01", + "A_M_M_SouCent_01", + "A_M_M_SouCent_02", + "A_M_M_SouCent_03", + "A_M_M_SouCent_04", + "A_M_M_StLat_02", + "A_M_M_Tennis_01", + "A_M_M_Tourist_01", + "A_M_M_Tramp_01", + "A_M_M_TrampBeac_01", + "A_M_M_TranVest_01", + "A_M_M_TranVest_02", + "A_M_O_ACult_01", + "A_M_O_ACult_02", + "A_M_O_Beach_01", + "A_M_O_DesStreet_01", + "A_M_O_GenStreet_01", + "A_M_O_KTown_01", + "A_M_O_Salton_01", + "A_M_O_SouCent_01", + "A_M_O_SouCent_02", + "A_M_O_SouCent_03", + "A_M_O_Tramp_01", + "A_M_Y_ACult_01", + "A_M_Y_ACult_02", + "A_M_Y_Beach_01", + "A_M_Y_Beach_02", + "A_M_Y_Beach_03", + "A_M_Y_BeachVesp_01", + "A_M_Y_BeachVesp_02", + "A_M_Y_BevHills_01", + "A_M_Y_BevHills_02", + "A_M_Y_BreakDance_01", + "A_M_Y_BusiCas_01", + "A_M_Y_Business_01", + "A_M_Y_Business_02", + "A_M_Y_Business_03", + "A_M_Y_Cyclist_01", + "A_M_Y_DesRebel_01", + "A_M_Y_DesStreet_01", + "A_M_Y_DHill_01", + "A_M_Y_Downtown_01", + "A_M_Y_EastSA_01", + "A_M_Y_EastSA_02", + "A_M_Y_Epsilon_01", + "A_M_Y_Epsilon_02", + "A_M_Y_Gay_01", + "A_M_Y_Gay_02", + "A_M_Y_GenStreet_01", + "A_M_Y_GenStreet_02", + "A_M_Y_Golfer_01", + "A_M_Y_HasJew_01", + "A_M_Y_Hiker_01", + "A_M_Y_Hippy_01", + "A_M_Y_Hipster_01", + "A_M_Y_Hipster_02", + "A_M_Y_Hipster_03", + "A_M_Y_Indian_01", + "A_M_Y_Jetski_01", + "A_M_Y_Juggalo_01", + "A_M_Y_KTown_01", + "A_M_Y_KTown_02", + "A_M_Y_Latino_01", + "A_M_Y_MethHead_01", + "A_M_Y_MexThug_01", + "A_M_Y_MotoX_01", + "A_M_Y_MotoX_02", + "A_M_Y_MusclBeac_01", + "A_M_Y_MusclBeac_02", + "A_M_Y_olynesian_01", + "A_M_Y_RoadCyc_01", + "A_M_Y_Runner_01", + "A_M_Y_Runner_02", + "A_M_Y_Salton_01", + "A_M_Y_Skater_01", + "A_M_Y_Skater_02", + "A_M_Y_SouCent_01", + "A_M_Y_SouCent_02", + "A_M_Y_SouCent_03", + "A_M_Y_SouCent_04", + "A_M_Y_StBla_01", + "A_M_Y_StBla_02", + "A_M_Y_StLat_01", + "A_M_Y_StWhi_01", + "A_M_Y_StWhi_02", + "A_M_Y_Sunbathe_01", + "A_M_Y_Surfer_01", + "A_M_Y_VinDouche_01", + "A_M_Y_Vinewood_01", + "A_M_Y_Vinewood_02", + "A_M_Y_Vinewood_03", + "A_M_Y_Vinewood_04", + "A_M_Y_Yoga_01", + "comp_eds_helmets_moped", + "comp_eds_helmets_motox", + "comp_eds_helmets_shorty", + "comp_eds_helmets_sports", + "comp_eds_marine", + "CS_AmandaTownley", + "CS_Andreas", + "CS_ashley", + "CS_Bankman", + "CS_Barry", + "CS_Beverly", + "CS_Brad", + "CS_BradCadaver", + "CS_Carbuyer", + "CS_Casey", + "CS_ChengSr", + "CS_ChrisFormage", + "CS_Clay", + "CS_Dale", + "CS_DaveNorton", + "CS_debra", + "CS_denise", + "CS_Devin", + "CS_Dom", + "CS_Dreyfuss", + "CS_DrFriedlander", + "CS_Fabien", + "CS_fabien", + "CS_FBISuit_01", + "CS_Floyd", + "CS_Guadalope", + "CS_gurk", + "CS_Hunter", + "CS_Janet", + "CS_JewelAss", + "CS_JimmyBoston", + "CS_JimmyDiSanto", + "CS_JoeMinuteMan", + "CS_JohnnyKlebitz", + "CS_Josef", + "CS_Josh", + "CS_LamarDavis", + "CS_Lazlow", + "CS_LesterCrest", + "CS_LifeInvad_01", + "CS_Magenta", + "CS_Manuel", + "CS_Marnie", + "CS_MartinMadrazo", + "CS_MaryAnn", + "CS_Michelle", + "CS_Milton", + "CS_Molly", + "CS_MovPremF_01", + "CS_MovPremMale", + "CS_MRK", + "CS_MRS_Thornhill", + "CS_MrsPhillips", + "CS_Natalia", + "CS_NervousRon", + "CS_Nigel", + "CS_Old_Man1A", + "CS_Old_Man2", + "CS_Omega", + "CS_Orleans", + "CS_aper", + "CS_atricia", + "CS_riest", + "CS_rolSec_02", + "CS_RussianDrunk", + "CS_SiemonYetarian", + "CS_Solomon", + "CS_SteveHains", + "CS_Stretch", + "CS_Tanisha", + "CS_TaoCheng", + "CS_TaosTranslator", + "CS_TennisCoach", + "CS_Terry", + "CS_Tom", + "CS_TomEpsilon", + "CS_TracyDiSanto", + "CS_Wade", + "CS_Zimbor", + "CSB_Abigail", + "CSB_Anita", + "CSB_Anton", + "CSB_BallasOG", + "CSB_Bride", + "CSB_BurgerDrug", + "CSB_Car3guy1", + "CSB_Car3guy2", + "CSB_Chef", + "CSB_Chin_goon", + "CSB_Cletus", + "CSB_Cop", + "CSB_Customer", + "CSB_Denise_friend", + "CSB_FOS_rep", + "CSB_G", + "CSB_Groom", + "CSB_Grove_str_dlr", + "CSB_Hao", + "CSB_Hugh", + "CSB_Imran", + "CSB_Janitor", + "CSB_Maude", + "CSB_MWeather", + "CSB_Ortega", + "CSB_Oscar", + "CSB_ornDudes", + "CSB_rologueDriver", + "CSB_rolSec", + "CSB_Ramp_Gang", + "CSB_Ramp_hic", + "CSB_Ramp_hipster", + "CSB_Ramp_Marine", + "CSB_Ramp_Mex", + "CSB_Reporter", + "CSB_RoccoPelosi", + "CSB_Screen_Writer", + "CSB_Stripper_01", + "CSB_Stripper_02", + "CSB_Tonya", + "CSB_TrafficWarden", + "G_F_Y_ballas_01", + "G_F_Y_Families_01", + "G_F_Y_Lost_01", + "G_F_Y_Vagos_01", + "G_M_M_AlpHench_01", + "G_M_M_AlpHench_02", + "G_M_M_ArmBoss_01", + "G_M_M_ArmGoon_01", + "G_M_M_ArmLieut_01", + "G_M_M_ChemWork_01", + "G_M_M_ChiBoss_01", + "G_M_M_ChiCold_01", + "G_M_M_ChiGoon_01", + "G_M_M_ChiGoon_02", + "G_M_M_KorBoss_01", + "G_M_M_MexBoss_01", + "G_M_M_MexBoss_02", + "G_M_O_DesOfficer", + "G_M_Y_AlpHeli_01", + "G_M_Y_ArmGoon_02", + "G_M_Y_Azteca_01", + "G_M_Y_BallaEast_01", + "G_M_Y_BallaOrig_01", + "G_M_Y_BallaSout_01", + "G_M_Y_Black01", + "G_M_Y_Const_01", + "G_M_Y_DesArmy_01", + "G_M_Y_DesArmy_02", + "G_M_Y_DesArmy_05", + "G_M_Y_DesHench_02", + "G_M_Y_DesHench_03", + "G_M_Y_DesMilit_03", + "G_M_Y_FamCA_01", + "G_M_Y_FamDNF_01", + "G_M_Y_FamFor_01", + "G_M_Y_Famfor_01", + "G_M_Y_Korean_01", + "G_M_Y_Korean_02", + "G_M_Y_KorLieut_01", + "G_M_Y_Latino01", + "G_M_Y_Lost_01", + "G_M_Y_Lost_02", + "G_M_Y_Lost_03", + "G_M_Y_MexGang_01", + "G_M_Y_MexGoon_01", + "G_M_Y_MexGoon_02", + "G_M_Y_MexGoon_03", + "G_M_Y_oloGoon_01", + "G_M_Y_oloGoon_02", + "G_M_Y_SalvaBoss_01", + "G_M_Y_SalvaGoon_01", + "G_M_Y_SalvaGoon_02", + "G_M_Y_SalvaGoon_03", + "G_M_Y_SciHench_01", + "G_M_Y_ScuHench_02", + "G_M_Y_SpaceHench_01", + "G_M_Y_SPACHENCH_02", + "G_M_Y_StrPunk_01", + "G_M_Y_StrPunk_02", + "G_M_Y_SubHench_01", + "G_M_Y_White01", + "HC_Driver", + "HC_Gunman", + "HC_Hacker", + "IG_Abigail", + "IG_AmandaTownley", + "IG_Andreas", + "IG_Ashley", + "IG_BallasOG", + "IG_Bankman", + "IG_Barry", + "IG_BestMen", + "IG_Beverly", + "IG_Brad", + "IG_Bride", + "IG_Car3guy1", + "IG_Car3guy2", + "IG_Casey", + "IG_Chef", + "IG_ChengSr", + "IG_ChrisFormage", + "IG_Clay", + "IG_ClayPain", + "IG_Cletus", + "IG_Dale", + "IG_DaveNorton", + "IG_Denise", + "IG_Devin", + "IG_Dom", + "IG_Dreyfuss", + "IG_DrFriedlander", + "IG_Fabien", + "IG_FBISuit_01", + "IG_Floyd", + "IG_Groom", + "IG_Hao", + "IG_Hunter", + "IG_Janet", + "IG_JAY_Norris", + "IG_JewelAss", + "IG_JimmyBoston", + "IG_JimmyDiSanto", + "IG_JoeMinuteMan", + "IG_JohnnyKlebitz", + "IG_Josef", + "IG_Josh", + "IG_KerryMcIntosh", + "IG_LamarDavis", + "IG_Lazlow", + "IG_LesterCrest", + "IG_LifeInvad_01", + "IG_LifeInvad_02", + "IG_Magenta", + "IG_Manuel", + "IG_Marnie", + "IG_MaryAnn", + "IG_Maude", + "IG_Michelle", + "IG_Milton", + "IG_Molly", + "IG_MRK", + "IG_MRS_Thornhill", + "IG_MrsPhillips", + "IG_Natalia", + "IG_NervousRon", + "IG_Nigel", + "IG_Old_Man1A", + "IG_Old_Man2", + "IG_Omega", + "IG_ONeil", + "IG_Orleans", + "IG_Ortega", + "IG_aper", + "IG_atricia", + "IG_riest", + "IG_rolSec_02", + "IG_Ramp_Gang", + "IG_Ramp_Hic", + "IG_Ramp_Hipster", + "IG_Ramp_Mex", + "IG_RoccoPelosi", + "IG_RussianDrunk", + "IG_Screen_Writer", + "IG_SiemonYetarian", + "IG_Solomon", + "IG_SteveHains", + "IG_Stretch", + "IG_Talina", + "IG_Tanisha", + "IG_TaoCheng", + "IG_TaosTranslator", + "IG_TennisCoach", + "IG_Terry", + "IG_TomEpsilon", + "IG_Tonya", + "IG_TracyDiSanto", + "IG_TrafficWarden", + "IG_TylerDix", + "IG_Wade", + "IG_Zimbor", + "MP_F_Cop_01", + "MP_F_DeadHooker", + "MP_F_Freemode_01", + "MP_F_Misty_01", + "MP_F_StripperLite", + "MP_G_F_Mexican_01", + "MP_G_F_Vagos_01", + "MP_G_M_Black_01", + "MP_G_M_Mexican_01", + "MP_G_M_ros_01", + "MP_G_M_Vagos_01", + "MP_HeadTargets", + "MP_M_Claude_01", + "MP_M_Cop_01", + "MP_M_ExArmy_01", + "MP_M_FamDD_01", + "MP_M_FIBSec_01", + "MP_M_Freemode_01", + "MP_M_Marston_01", + "MP_M_Niko_01", + "MP_M_ShopKeep_01", + "MP_S_M_Armoured_01", + "player", + "Player_One", + "Player_Two", + "Player_Zero", + "S_F_M_Fembarber", + "S_F_M_Maid_01", + "S_F_M_MAID_02", + "S_F_M_Shop_HIGH", + "S_F_M_SweatShop_01", + "S_F_Y_AirHostess_01", + "S_F_Y_Bartender_01", + "S_F_Y_Baywatch_01", + "S_F_Y_Cop_01", + "S_F_Y_Factory_01", + "S_F_Y_Hooker_01", + "S_F_Y_Hooker_02", + "S_F_Y_Hooker_03", + "S_F_Y_Migrant_01", + "S_F_Y_MovPrem_01", + "S_F_Y_Ranger_01", + "S_F_Y_Scrubs_01", + "S_F_Y_Sheriff_01", + "S_F_Y_Shop_LOW", + "S_F_Y_Shop_MID", + "S_F_Y_Snowcop_01", + "S_F_Y_Stripper_01", + "S_F_Y_Stripper_02", + "S_F_Y_StripperLite", + "S_F_Y_SweatShop_01", + "S_M_M_Alpstall", + "S_M_M_AmmuCountry", + "S_M_M_Armoured_01", + "S_M_M_Armoured_02", + "S_M_M_AutoShop_01", + "S_M_M_AutoShop_02", + "S_M_M_Bouncer_01", + "S_M_M_ChemSec_01", + "S_M_M_CIASec_01", + "S_M_M_CntryBar_01", + "S_M_M_DockWork_01", + "S_M_M_Doctor_01", + "S_M_M_FIBOffice_01", + "S_M_M_FIBOffice_02", + "S_M_M_Gaffer_01", + "S_M_M_Gardener_01", + "S_M_M_GenTransport", + "S_M_M_HairDress_01", + "S_M_M_HighSec_01", + "S_M_M_HighSec_02", + "S_M_M_INTWork", + "S_M_M_Janitor", + "S_M_M_LatHandy_01", + "S_M_M_LifeInvad_01", + "S_M_M_Linecook", + "S_M_M_LSMetro_01", + "S_M_M_Mariachi_01", + "S_M_M_Marine_01", + "S_M_M_Marine_02", + "S_M_M_Migrant_01", + "S_M_M_MovAlien_01", + "S_M_M_MovPrem_01", + "S_M_M_MovSpace_01", + "S_M_M_aramedic_01", + "S_M_M_ilot_01", + "S_M_M_ilot_02", + "S_M_M_ostal_01", + "S_M_M_ostal_02", + "S_M_M_risGuard_01", + "S_M_M_Scientist_01", + "S_M_M_Security_01", + "S_M_M_SnowCop_01", + "S_M_M_StrPerf_01", + "S_M_M_StrPreach_01", + "S_M_M_StrVend_01", + "S_M_M_Trucker_01", + "S_M_M_UPS_01", + "S_M_M_UPS_02", + "S_M_O_Busker_01", + "S_M_O_Snowcop_01", + "S_M_Y_AirWorker", + "S_M_Y_AmmuCity_01", + "S_M_Y_ArmyMech_01", + "S_M_Y_Autopsy_01", + "S_M_Y_Barman_01", + "S_M_Y_BayWatch_01", + "S_M_Y_BlackOps_01", + "S_M_Y_BlackOps_02", + "S_M_Y_BusBoy_01", + "S_M_Y_Chef_01", + "S_M_Y_Clown_01", + "S_M_Y_Construct_01", + "S_M_Y_Construct_02", + "S_M_Y_Cop_01", + "S_M_Y_Dealer_01", + "S_M_Y_DevinSec_01", + "S_M_Y_DockWork_01", + "S_M_Y_Doorman_01", + "S_M_Y_DWService_01", + "S_M_Y_DWService_02", + "S_M_Y_Factory_01", + "S_M_Y_Fireman_01", + "S_M_Y_Garbage", + "S_M_Y_Grip_01", + "S_M_Y_HwayCop_01", + "S_M_Y_Marine_01", + "S_M_Y_Marine_02", + "S_M_Y_Marine_03", + "S_M_Y_Mime", + "S_M_Y_estCont_01", + "S_M_Y_ilot_01", + "S_M_Y_risMuscl_01", + "S_M_Y_risoner_01", + "S_M_Y_Ranger_01", + "S_M_Y_Robber_01", + "S_M_Y_Scrubs_01", + "S_M_Y_Sheriff_01", + "S_M_Y_Shop_MASK", + "S_M_Y_StrVend_01", + "S_M_Y_Swat_01", + "S_M_Y_USCG_01", + "S_M_Y_Valet_01", + "S_M_Y_Waiter_01", + "S_M_Y_WinClean_01", + "S_M_Y_XMech_01", + "S_M_Y_XMech_02", + "slod_human", + "slod_large_quadped", + "slod_small_quadped", + "strm_eds_mpShare", + "strm_eds_mpTattRTs", + "U_F_M_Corpse_01", + "U_F_M_Miranda", + "U_F_M_roMourn_01", + "U_F_O_MovieStar", + "U_F_O_rolHost_01", + "U_F_Y_BikerChic", + "U_F_Y_COMJane", + "U_F_Y_corpse_01", + "U_F_Y_corpse_02", + "U_F_Y_HotPosh_01", + "U_F_Y_JewelAss_01", + "U_F_Y_Mistress", + "U_F_Y_oppyMich", + "U_F_Y_rincess", + "U_F_Y_SpyActress", + "U_M_M_Aldinapoli", + "U_M_M_BankMan", + "U_M_M_BikeHire_01", + "U_M_M_FIBArchitect", + "U_M_M_FilmDirector", + "U_M_M_GlenStank_01", + "U_M_M_Griff_01", + "U_M_M_Jesus_01", + "U_M_M_JewelSec_01", + "U_M_M_JewelThief", + "U_M_M_MarkFost", + "U_M_M_artyTarget", + "U_M_M_rolSec_01", + "U_M_M_roMourn_01", + "U_M_M_RivalPap", + "U_M_M_SpyActor", + "U_M_M_WillyFist", + "U_M_O_FinGuru_01", + "U_M_O_TapHillBilly", + "U_M_O_Tramp_01", + "U_M_Y_Abner", + "U_M_Y_AntonB", + "U_M_Y_BabyD", + "U_M_Y_Baygor", + "U_M_Y_BurgerDrug_01", + "U_M_Y_Chip", + "U_M_Y_Cyclist_01", + "U_M_Y_FIBMugger_01", + "U_M_Y_Guido_01", + "U_M_Y_GunVend_01", + "U_M_Y_Hippie_01", + "U_M_Y_ImpoRage", + "U_M_Y_Justin", + "U_M_Y_Mani", + "U_M_Y_MilitaryBum", + "U_M_Y_aparazzi", + "U_M_Y_arty_01", + "U_M_Y_ogo_01", + "U_M_Y_risoner_01", + "U_M_Y_rolDriver_01", + "U_M_Y_RSRanger_01", + "U_M_Y_SBike", + "U_M_Y_StagGrm_01", + "U_M_Y_Tattoo_01", + "U_M_Y_Zombie_01"]) +} \ No newline at end of file diff --git a/packages/copchase/helpers/getDistance.js b/packages/copchase/helpers/getDistance.js new file mode 100644 index 0000000..4c9e410 --- /dev/null +++ b/packages/copchase/helpers/getDistance.js @@ -0,0 +1,5 @@ +const getDistance = function (v1, v2){ + return Math.abs(Math.sqrt(Math.pow((v2.x - v1.x),2) + Math.pow((v2.y - v1.y), 2))); +} + +module.exports = { getDistance } \ No newline at end of file diff --git a/packages/copchase/index.js b/packages/copchase/index.js new file mode 100644 index 0000000..d731197 --- /dev/null +++ b/packages/copchase/index.js @@ -0,0 +1,47 @@ +const mongoose = require('mongoose') +const { Player } = require('./models') +const API = require('./api') +const Copchase = require('./copchase') + +const startServer = async () => { + + try { + await mongoose.connect('mongodb+srv://sergeyyarkov:1234@cluster0.erqpg.mongodb.net/copchase-db?retryWrites=true&w=majority', { + useNewUrlParser: true, + useUnifiedTopology: true, + useFindAndModify: false, + }) + + console.log('Database connected!') + + const players = await Player.find({}) + const api = new API(players) + const copchase = new Copchase({ + dimension: 10, + waitingRoomDimension: 5, + maxPlayers: 11, + minPlayers: 1, + timeRemaining: 10, + timeToStart: 3 + }) + + /* + Commands + */ + + require('./commands/admin/admin')({ api }) + require('./commands/player/player')({ api, copchase }) + + /* + Events + */ + + require('./events/admin/admin')({ api }) + require('./events/player/player')({ api, copchase }) + + } catch (error) { + console.log('Error!', error) + } +} + +startServer() \ No newline at end of file diff --git a/packages/copchase/models/Player.js b/packages/copchase/models/Player.js new file mode 100644 index 0000000..b61959d --- /dev/null +++ b/packages/copchase/models/Player.js @@ -0,0 +1,8 @@ +const mongoose = require('mongoose') + +const playerSchema = mongoose.Schema({ + name: String, + password: String +}) + +module.exports = mongoose.model('Player', playerSchema) \ No newline at end of file diff --git a/packages/copchase/models/index.js b/packages/copchase/models/index.js new file mode 100644 index 0000000..fae160c --- /dev/null +++ b/packages/copchase/models/index.js @@ -0,0 +1,5 @@ +const Player = require('./Player') + +module.exports = { + Player +} \ No newline at end of file diff --git a/packages/copchase/package-lock.json b/packages/copchase/package-lock.json new file mode 100644 index 0000000..0d307a3 --- /dev/null +++ b/packages/copchase/package-lock.json @@ -0,0 +1,3341 @@ +{ + "name": "copchase", + "version": "1.0.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "bcryptjs": { + "version": "2.4.3", + "resolved": "https://registry.npmjs.org/bcryptjs/-/bcryptjs-2.4.3.tgz", + "integrity": "sha1-mrVie5PmBiH/fNrF2pczAn3x0Ms=" + }, + "bl": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/bl/-/bl-2.2.0.tgz", + "integrity": "sha512-wbgvOpqopSr7uq6fJrLH8EsvYMJf9gzfo2jCsL2eTy75qXPukA4pCgHamOQkZtY5vmfVtjB+P3LNlMHW5CEZXA==", + "requires": { + "readable-stream": "^2.3.5", + "safe-buffer": "^5.1.1" + } + }, + "bluebird": { + "version": "3.5.1", + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.1.tgz", + "integrity": "sha512-MKiLiV+I1AA596t9w1sQJ8jkiSr5+ZKi0WKrYGUn6d1Fx+Ij4tIj+m2WMQSGczs5jZVxV339chE8iwk6F64wjA==" + }, + "bson": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/bson/-/bson-1.1.4.tgz", + "integrity": "sha512-S/yKGU1syOMzO86+dGpg2qGoDL0zvzcb262G+gqEy6TgP6rt6z6qxSFX/8X6vLC91P7G7C3nLs0+bvDzmvBA3Q==" + }, + "core-util-is": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" + }, + "debug": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", + "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", + "requires": { + "ms": "2.0.0" + }, + "dependencies": { + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + } + } + }, + "denque": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/denque/-/denque-1.4.1.tgz", + "integrity": "sha512-OfzPuSZKGcgr96rf1oODnfjqBFmr1DVoc/TrItj3Ohe0Ah1C5WX5Baquw/9U9KovnQ88EqmJbD66rKYUQYN1tQ==" + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "install": { + "version": "0.13.0", + "resolved": "https://registry.npmjs.org/install/-/install-0.13.0.tgz", + "integrity": "sha512-zDml/jzr2PKU9I8J/xyZBQn8rPCAY//UOYNmR01XwNwyfhEWObo2SWfSl1+0tm1u6PhxLwDnfsT/6jB7OUxqFA==" + }, + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" + }, + "kareem": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/kareem/-/kareem-2.3.1.tgz", + "integrity": "sha512-l3hLhffs9zqoDe8zjmb/mAN4B8VT3L56EUvKNqLFVs9YlFA+zx7ke1DO8STAdDyYNkeSo1nKmjuvQeI12So8Xw==" + }, + "memory-pager": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/memory-pager/-/memory-pager-1.5.0.tgz", + "integrity": "sha512-ZS4Bp4r/Zoeq6+NLJpP+0Zzm0pR8whtGPf1XExKLJBAczGMnSi3It14OiNCStjQjM6NU1okjQGSxgEZN8eBYKg==", + "optional": true + }, + "mongodb": { + "version": "3.5.9", + "resolved": "https://registry.npmjs.org/mongodb/-/mongodb-3.5.9.tgz", + "integrity": "sha512-vXHBY1CsGYcEPoVWhwgxIBeWqP3dSu9RuRDsoLRPTITrcrgm1f0Ubu1xqF9ozMwv53agmEiZm0YGo+7WL3Nbug==", + "requires": { + "bl": "^2.2.0", + "bson": "^1.1.4", + "denque": "^1.4.1", + "require_optional": "^1.0.1", + "safe-buffer": "^5.1.2", + "saslprep": "^1.0.0" + } + }, + "mongoose": { + "version": "5.9.26", + "resolved": "https://registry.npmjs.org/mongoose/-/mongoose-5.9.26.tgz", + "integrity": "sha512-mVddZM1mB8xg9oJQZAXaN762B01puV+jL5mPqg1HBXpEs7TG6ZZ/hEk98YRJMJff/YhIzuK3a3oos6XWtTaVUQ==", + "requires": { + "bson": "^1.1.4", + "kareem": "2.3.1", + "mongodb": "3.5.9", + "mongoose-legacy-pluralize": "1.0.2", + "mpath": "0.7.0", + "mquery": "3.2.2", + "ms": "2.1.2", + "regexp-clone": "1.0.0", + "safe-buffer": "5.2.1", + "sift": "7.0.1", + "sliced": "1.0.1" + } + }, + "mongoose-legacy-pluralize": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/mongoose-legacy-pluralize/-/mongoose-legacy-pluralize-1.0.2.tgz", + "integrity": "sha512-Yo/7qQU4/EyIS8YDFSeenIvXxZN+ld7YdV9LqFVQJzTLye8unujAWPZ4NWKfFA+RNjh+wvTWKY9Z3E5XM6ZZiQ==" + }, + "mpath": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/mpath/-/mpath-0.7.0.tgz", + "integrity": "sha512-Aiq04hILxhz1L+f7sjGyn7IxYzWm1zLNNXcfhDtx04kZ2Gk7uvFdgZ8ts1cWa/6d0TQmag2yR8zSGZUmp0tFNg==" + }, + "mquery": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/mquery/-/mquery-3.2.2.tgz", + "integrity": "sha512-XB52992COp0KP230I3qloVUbkLUxJIu328HBP2t2EsxSFtf4W1HPSOBWOXf1bqxK4Xbb66lfMJ+Bpfd9/yZE1Q==", + "requires": { + "bluebird": "3.5.1", + "debug": "3.1.0", + "regexp-clone": "^1.0.0", + "safe-buffer": "5.1.2", + "sliced": "1.0.1" + }, + "dependencies": { + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + } + } + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + }, + "npm": { + "version": "6.14.7", + "resolved": "https://registry.npmjs.org/npm/-/npm-6.14.7.tgz", + "integrity": "sha512-swhsdpNpyXg4GbM6LpOQ6qaloQuIKizZ+Zh6JPXJQc59ka49100Js0WvZx594iaKSoFgkFq2s8uXFHS3/Xy2WQ==", + "requires": { + "JSONStream": "^1.3.5", + "abbrev": "~1.1.1", + "ansicolors": "~0.3.2", + "ansistyles": "~0.1.3", + "aproba": "^2.0.0", + "archy": "~1.0.0", + "bin-links": "^1.1.8", + "bluebird": "^3.5.5", + "byte-size": "^5.0.1", + "cacache": "^12.0.3", + "call-limit": "^1.1.1", + "chownr": "^1.1.4", + "ci-info": "^2.0.0", + "cli-columns": "^3.1.2", + "cli-table3": "^0.5.1", + "cmd-shim": "^3.0.3", + "columnify": "~1.5.4", + "config-chain": "^1.1.12", + "debuglog": "*", + "detect-indent": "~5.0.0", + "detect-newline": "^2.1.0", + "dezalgo": "~1.0.3", + "editor": "~1.0.0", + "figgy-pudding": "^3.5.1", + "find-npm-prefix": "^1.0.2", + "fs-vacuum": "~1.2.10", + "fs-write-stream-atomic": "~1.0.10", + "gentle-fs": "^2.3.1", + "glob": "^7.1.6", + "graceful-fs": "^4.2.4", + "has-unicode": "~2.0.1", + "hosted-git-info": "^2.8.8", + "iferr": "^1.0.2", + "imurmurhash": "*", + "infer-owner": "^1.0.4", + "inflight": "~1.0.6", + "inherits": "^2.0.4", + "ini": "^1.3.5", + "init-package-json": "^1.10.3", + "is-cidr": "^3.0.0", + "json-parse-better-errors": "^1.0.2", + "lazy-property": "~1.0.0", + "libcipm": "^4.0.8", + "libnpm": "^3.0.1", + "libnpmaccess": "^3.0.2", + "libnpmhook": "^5.0.3", + "libnpmorg": "^1.0.1", + "libnpmsearch": "^2.0.2", + "libnpmteam": "^1.0.2", + "libnpx": "^10.2.4", + "lock-verify": "^2.1.0", + "lockfile": "^1.0.4", + "lodash._baseindexof": "*", + "lodash._baseuniq": "~4.6.0", + "lodash._bindcallback": "*", + "lodash._cacheindexof": "*", + "lodash._createcache": "*", + "lodash._getnative": "*", + "lodash.clonedeep": "~4.5.0", + "lodash.restparam": "*", + "lodash.union": "~4.6.0", + "lodash.uniq": "~4.5.0", + "lodash.without": "~4.4.0", + "lru-cache": "^5.1.1", + "meant": "~1.0.1", + "mississippi": "^3.0.0", + "mkdirp": "^0.5.5", + "move-concurrently": "^1.0.1", + "node-gyp": "^5.1.0", + "nopt": "^4.0.3", + "normalize-package-data": "^2.5.0", + "npm-audit-report": "^1.3.3", + "npm-cache-filename": "~1.0.2", + "npm-install-checks": "^3.0.2", + "npm-lifecycle": "^3.1.5", + "npm-package-arg": "^6.1.1", + "npm-packlist": "^1.4.8", + "npm-pick-manifest": "^3.0.2", + "npm-profile": "^4.0.4", + "npm-registry-fetch": "^4.0.5", + "npm-user-validate": "~1.0.0", + "npmlog": "~4.1.2", + "once": "~1.4.0", + "opener": "^1.5.1", + "osenv": "^0.1.5", + "pacote": "^9.5.12", + "path-is-inside": "~1.0.2", + "promise-inflight": "~1.0.1", + "qrcode-terminal": "^0.12.0", + "query-string": "^6.8.2", + "qw": "~1.0.1", + "read": "~1.0.7", + "read-cmd-shim": "^1.0.5", + "read-installed": "~4.0.3", + "read-package-json": "^2.1.1", + "read-package-tree": "^5.3.1", + "readable-stream": "^3.6.0", + "readdir-scoped-modules": "^1.1.0", + "request": "^2.88.0", + "retry": "^0.12.0", + "rimraf": "^2.7.1", + "safe-buffer": "^5.1.2", + "semver": "^5.7.1", + "sha": "^3.0.0", + "slide": "~1.1.6", + "sorted-object": "~2.0.1", + "sorted-union-stream": "~2.1.3", + "ssri": "^6.0.1", + "stringify-package": "^1.0.1", + "tar": "^4.4.13", + "text-table": "~0.2.0", + "tiny-relative-date": "^1.3.0", + "uid-number": "0.0.6", + "umask": "~1.1.0", + "unique-filename": "^1.1.1", + "unpipe": "~1.0.0", + "update-notifier": "^2.5.0", + "uuid": "^3.3.3", + "validate-npm-package-license": "^3.0.4", + "validate-npm-package-name": "~3.0.0", + "which": "^1.3.1", + "worker-farm": "^1.7.0", + "write-file-atomic": "^2.4.3" + }, + "dependencies": { + "JSONStream": { + "version": "1.3.5", + "bundled": true, + "requires": { + "jsonparse": "^1.2.0", + "through": ">=2.2.7 <3" + } + }, + "abbrev": { + "version": "1.1.1", + "bundled": true + }, + "agent-base": { + "version": "4.3.0", + "bundled": true, + "requires": { + "es6-promisify": "^5.0.0" + } + }, + "agentkeepalive": { + "version": "3.5.2", + "bundled": true, + "requires": { + "humanize-ms": "^1.2.1" + } + }, + "ajv": { + "version": "5.5.2", + "bundled": true, + "requires": { + "co": "^4.6.0", + "fast-deep-equal": "^1.0.0", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.3.0" + } + }, + "ansi-align": { + "version": "2.0.0", + "bundled": true, + "requires": { + "string-width": "^2.0.0" + } + }, + "ansi-regex": { + "version": "2.1.1", + "bundled": true + }, + "ansi-styles": { + "version": "3.2.1", + "bundled": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "ansicolors": { + "version": "0.3.2", + "bundled": true + }, + "ansistyles": { + "version": "0.1.3", + "bundled": true + }, + "aproba": { + "version": "2.0.0", + "bundled": true + }, + "archy": { + "version": "1.0.0", + "bundled": true + }, + "are-we-there-yet": { + "version": "1.1.4", + "bundled": true, + "requires": { + "delegates": "^1.0.0", + "readable-stream": "^2.0.6" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "asap": { + "version": "2.0.6", + "bundled": true + }, + "asn1": { + "version": "0.2.4", + "bundled": true, + "requires": { + "safer-buffer": "~2.1.0" + } + }, + "assert-plus": { + "version": "1.0.0", + "bundled": true + }, + "asynckit": { + "version": "0.4.0", + "bundled": true + }, + "aws-sign2": { + "version": "0.7.0", + "bundled": true + }, + "aws4": { + "version": "1.8.0", + "bundled": true + }, + "balanced-match": { + "version": "1.0.0", + "bundled": true + }, + "bcrypt-pbkdf": { + "version": "1.0.2", + "bundled": true, + "optional": true, + "requires": { + "tweetnacl": "^0.14.3" + } + }, + "bin-links": { + "version": "1.1.8", + "bundled": true, + "requires": { + "bluebird": "^3.5.3", + "cmd-shim": "^3.0.0", + "gentle-fs": "^2.3.0", + "graceful-fs": "^4.1.15", + "npm-normalize-package-bin": "^1.0.0", + "write-file-atomic": "^2.3.0" + } + }, + "bluebird": { + "version": "3.5.5", + "bundled": true + }, + "boxen": { + "version": "1.3.0", + "bundled": true, + "requires": { + "ansi-align": "^2.0.0", + "camelcase": "^4.0.0", + "chalk": "^2.0.1", + "cli-boxes": "^1.0.0", + "string-width": "^2.0.0", + "term-size": "^1.2.0", + "widest-line": "^2.0.0" + } + }, + "brace-expansion": { + "version": "1.1.11", + "bundled": true, + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "buffer-from": { + "version": "1.0.0", + "bundled": true + }, + "builtins": { + "version": "1.0.3", + "bundled": true + }, + "byline": { + "version": "5.0.0", + "bundled": true + }, + "byte-size": { + "version": "5.0.1", + "bundled": true + }, + "cacache": { + "version": "12.0.3", + "bundled": true, + "requires": { + "bluebird": "^3.5.5", + "chownr": "^1.1.1", + "figgy-pudding": "^3.5.1", + "glob": "^7.1.4", + "graceful-fs": "^4.1.15", + "infer-owner": "^1.0.3", + "lru-cache": "^5.1.1", + "mississippi": "^3.0.0", + "mkdirp": "^0.5.1", + "move-concurrently": "^1.0.1", + "promise-inflight": "^1.0.1", + "rimraf": "^2.6.3", + "ssri": "^6.0.1", + "unique-filename": "^1.1.1", + "y18n": "^4.0.0" + } + }, + "call-limit": { + "version": "1.1.1", + "bundled": true + }, + "camelcase": { + "version": "4.1.0", + "bundled": true + }, + "capture-stack-trace": { + "version": "1.0.0", + "bundled": true + }, + "caseless": { + "version": "0.12.0", + "bundled": true + }, + "chalk": { + "version": "2.4.1", + "bundled": true, + "requires": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + } + }, + "chownr": { + "version": "1.1.4", + "bundled": true + }, + "ci-info": { + "version": "2.0.0", + "bundled": true + }, + "cidr-regex": { + "version": "2.0.10", + "bundled": true, + "requires": { + "ip-regex": "^2.1.0" + } + }, + "cli-boxes": { + "version": "1.0.0", + "bundled": true + }, + "cli-columns": { + "version": "3.1.2", + "bundled": true, + "requires": { + "string-width": "^2.0.0", + "strip-ansi": "^3.0.1" + } + }, + "cli-table3": { + "version": "0.5.1", + "bundled": true, + "requires": { + "colors": "^1.1.2", + "object-assign": "^4.1.0", + "string-width": "^2.1.1" + } + }, + "cliui": { + "version": "5.0.0", + "bundled": true, + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "bundled": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "bundled": true + }, + "string-width": { + "version": "3.1.0", + "bundled": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "bundled": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "clone": { + "version": "1.0.4", + "bundled": true + }, + "cmd-shim": { + "version": "3.0.3", + "bundled": true, + "requires": { + "graceful-fs": "^4.1.2", + "mkdirp": "~0.5.0" + } + }, + "co": { + "version": "4.6.0", + "bundled": true + }, + "code-point-at": { + "version": "1.1.0", + "bundled": true + }, + "color-convert": { + "version": "1.9.1", + "bundled": true, + "requires": { + "color-name": "^1.1.1" + } + }, + "color-name": { + "version": "1.1.3", + "bundled": true + }, + "colors": { + "version": "1.3.3", + "bundled": true, + "optional": true + }, + "columnify": { + "version": "1.5.4", + "bundled": true, + "requires": { + "strip-ansi": "^3.0.0", + "wcwidth": "^1.0.0" + } + }, + "combined-stream": { + "version": "1.0.6", + "bundled": true, + "requires": { + "delayed-stream": "~1.0.0" + } + }, + "concat-map": { + "version": "0.0.1", + "bundled": true + }, + "concat-stream": { + "version": "1.6.2", + "bundled": true, + "requires": { + "buffer-from": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^2.2.2", + "typedarray": "^0.0.6" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "config-chain": { + "version": "1.1.12", + "bundled": true, + "requires": { + "ini": "^1.3.4", + "proto-list": "~1.2.1" + } + }, + "configstore": { + "version": "3.1.2", + "bundled": true, + "requires": { + "dot-prop": "^4.1.0", + "graceful-fs": "^4.1.2", + "make-dir": "^1.0.0", + "unique-string": "^1.0.0", + "write-file-atomic": "^2.0.0", + "xdg-basedir": "^3.0.0" + } + }, + "console-control-strings": { + "version": "1.1.0", + "bundled": true + }, + "copy-concurrently": { + "version": "1.0.5", + "bundled": true, + "requires": { + "aproba": "^1.1.1", + "fs-write-stream-atomic": "^1.0.8", + "iferr": "^0.1.5", + "mkdirp": "^0.5.1", + "rimraf": "^2.5.4", + "run-queue": "^1.0.0" + }, + "dependencies": { + "aproba": { + "version": "1.2.0", + "bundled": true + }, + "iferr": { + "version": "0.1.5", + "bundled": true + } + } + }, + "core-util-is": { + "version": "1.0.2", + "bundled": true + }, + "create-error-class": { + "version": "3.0.2", + "bundled": true, + "requires": { + "capture-stack-trace": "^1.0.0" + } + }, + "cross-spawn": { + "version": "5.1.0", + "bundled": true, + "requires": { + "lru-cache": "^4.0.1", + "shebang-command": "^1.2.0", + "which": "^1.2.9" + }, + "dependencies": { + "lru-cache": { + "version": "4.1.5", + "bundled": true, + "requires": { + "pseudomap": "^1.0.2", + "yallist": "^2.1.2" + } + }, + "yallist": { + "version": "2.1.2", + "bundled": true + } + } + }, + "crypto-random-string": { + "version": "1.0.0", + "bundled": true + }, + "cyclist": { + "version": "0.2.2", + "bundled": true + }, + "dashdash": { + "version": "1.14.1", + "bundled": true, + "requires": { + "assert-plus": "^1.0.0" + } + }, + "debug": { + "version": "3.1.0", + "bundled": true, + "requires": { + "ms": "2.0.0" + }, + "dependencies": { + "ms": { + "version": "2.0.0", + "bundled": true + } + } + }, + "debuglog": { + "version": "1.0.1", + "bundled": true + }, + "decamelize": { + "version": "1.2.0", + "bundled": true + }, + "decode-uri-component": { + "version": "0.2.0", + "bundled": true + }, + "deep-extend": { + "version": "0.6.0", + "bundled": true + }, + "defaults": { + "version": "1.0.3", + "bundled": true, + "requires": { + "clone": "^1.0.2" + } + }, + "define-properties": { + "version": "1.1.3", + "bundled": true, + "requires": { + "object-keys": "^1.0.12" + } + }, + "delayed-stream": { + "version": "1.0.0", + "bundled": true + }, + "delegates": { + "version": "1.0.0", + "bundled": true + }, + "detect-indent": { + "version": "5.0.0", + "bundled": true + }, + "detect-newline": { + "version": "2.1.0", + "bundled": true + }, + "dezalgo": { + "version": "1.0.3", + "bundled": true, + "requires": { + "asap": "^2.0.0", + "wrappy": "1" + } + }, + "dot-prop": { + "version": "4.2.0", + "bundled": true, + "requires": { + "is-obj": "^1.0.0" + } + }, + "dotenv": { + "version": "5.0.1", + "bundled": true + }, + "duplexer3": { + "version": "0.1.4", + "bundled": true + }, + "duplexify": { + "version": "3.6.0", + "bundled": true, + "requires": { + "end-of-stream": "^1.0.0", + "inherits": "^2.0.1", + "readable-stream": "^2.0.0", + "stream-shift": "^1.0.0" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "ecc-jsbn": { + "version": "0.1.2", + "bundled": true, + "optional": true, + "requires": { + "jsbn": "~0.1.0", + "safer-buffer": "^2.1.0" + } + }, + "editor": { + "version": "1.0.0", + "bundled": true + }, + "emoji-regex": { + "version": "7.0.3", + "bundled": true + }, + "encoding": { + "version": "0.1.12", + "bundled": true, + "requires": { + "iconv-lite": "~0.4.13" + } + }, + "end-of-stream": { + "version": "1.4.1", + "bundled": true, + "requires": { + "once": "^1.4.0" + } + }, + "env-paths": { + "version": "2.2.0", + "bundled": true + }, + "err-code": { + "version": "1.1.2", + "bundled": true + }, + "errno": { + "version": "0.1.7", + "bundled": true, + "requires": { + "prr": "~1.0.1" + } + }, + "es-abstract": { + "version": "1.12.0", + "bundled": true, + "requires": { + "es-to-primitive": "^1.1.1", + "function-bind": "^1.1.1", + "has": "^1.0.1", + "is-callable": "^1.1.3", + "is-regex": "^1.0.4" + } + }, + "es-to-primitive": { + "version": "1.2.0", + "bundled": true, + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "es6-promise": { + "version": "4.2.8", + "bundled": true + }, + "es6-promisify": { + "version": "5.0.0", + "bundled": true, + "requires": { + "es6-promise": "^4.0.3" + } + }, + "escape-string-regexp": { + "version": "1.0.5", + "bundled": true + }, + "execa": { + "version": "0.7.0", + "bundled": true, + "requires": { + "cross-spawn": "^5.0.1", + "get-stream": "^3.0.0", + "is-stream": "^1.1.0", + "npm-run-path": "^2.0.0", + "p-finally": "^1.0.0", + "signal-exit": "^3.0.0", + "strip-eof": "^1.0.0" + }, + "dependencies": { + "get-stream": { + "version": "3.0.0", + "bundled": true + } + } + }, + "extend": { + "version": "3.0.2", + "bundled": true + }, + "extsprintf": { + "version": "1.3.0", + "bundled": true + }, + "fast-deep-equal": { + "version": "1.1.0", + "bundled": true + }, + "fast-json-stable-stringify": { + "version": "2.0.0", + "bundled": true + }, + "figgy-pudding": { + "version": "3.5.1", + "bundled": true + }, + "find-npm-prefix": { + "version": "1.0.2", + "bundled": true + }, + "flush-write-stream": { + "version": "1.0.3", + "bundled": true, + "requires": { + "inherits": "^2.0.1", + "readable-stream": "^2.0.4" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "forever-agent": { + "version": "0.6.1", + "bundled": true + }, + "form-data": { + "version": "2.3.2", + "bundled": true, + "requires": { + "asynckit": "^0.4.0", + "combined-stream": "1.0.6", + "mime-types": "^2.1.12" + } + }, + "from2": { + "version": "2.3.0", + "bundled": true, + "requires": { + "inherits": "^2.0.1", + "readable-stream": "^2.0.0" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "fs-minipass": { + "version": "1.2.7", + "bundled": true, + "requires": { + "minipass": "^2.6.0" + }, + "dependencies": { + "minipass": { + "version": "2.9.0", + "bundled": true, + "requires": { + "safe-buffer": "^5.1.2", + "yallist": "^3.0.0" + } + } + } + }, + "fs-vacuum": { + "version": "1.2.10", + "bundled": true, + "requires": { + "graceful-fs": "^4.1.2", + "path-is-inside": "^1.0.1", + "rimraf": "^2.5.2" + } + }, + "fs-write-stream-atomic": { + "version": "1.0.10", + "bundled": true, + "requires": { + "graceful-fs": "^4.1.2", + "iferr": "^0.1.5", + "imurmurhash": "^0.1.4", + "readable-stream": "1 || 2" + }, + "dependencies": { + "iferr": { + "version": "0.1.5", + "bundled": true + }, + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "fs.realpath": { + "version": "1.0.0", + "bundled": true + }, + "function-bind": { + "version": "1.1.1", + "bundled": true + }, + "gauge": { + "version": "2.7.4", + "bundled": true, + "requires": { + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" + }, + "dependencies": { + "aproba": { + "version": "1.2.0", + "bundled": true + }, + "string-width": { + "version": "1.0.2", + "bundled": true, + "requires": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + } + } + } + }, + "genfun": { + "version": "5.0.0", + "bundled": true + }, + "gentle-fs": { + "version": "2.3.1", + "bundled": true, + "requires": { + "aproba": "^1.1.2", + "chownr": "^1.1.2", + "cmd-shim": "^3.0.3", + "fs-vacuum": "^1.2.10", + "graceful-fs": "^4.1.11", + "iferr": "^0.1.5", + "infer-owner": "^1.0.4", + "mkdirp": "^0.5.1", + "path-is-inside": "^1.0.2", + "read-cmd-shim": "^1.0.1", + "slide": "^1.1.6" + }, + "dependencies": { + "aproba": { + "version": "1.2.0", + "bundled": true + }, + "iferr": { + "version": "0.1.5", + "bundled": true + } + } + }, + "get-caller-file": { + "version": "2.0.5", + "bundled": true + }, + "get-stream": { + "version": "4.1.0", + "bundled": true, + "requires": { + "pump": "^3.0.0" + } + }, + "getpass": { + "version": "0.1.7", + "bundled": true, + "requires": { + "assert-plus": "^1.0.0" + } + }, + "glob": { + "version": "7.1.6", + "bundled": true, + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "global-dirs": { + "version": "0.1.1", + "bundled": true, + "requires": { + "ini": "^1.3.4" + } + }, + "got": { + "version": "6.7.1", + "bundled": true, + "requires": { + "create-error-class": "^3.0.0", + "duplexer3": "^0.1.4", + "get-stream": "^3.0.0", + "is-redirect": "^1.0.0", + "is-retry-allowed": "^1.0.0", + "is-stream": "^1.0.0", + "lowercase-keys": "^1.0.0", + "safe-buffer": "^5.0.1", + "timed-out": "^4.0.0", + "unzip-response": "^2.0.1", + "url-parse-lax": "^1.0.0" + }, + "dependencies": { + "get-stream": { + "version": "3.0.0", + "bundled": true + } + } + }, + "graceful-fs": { + "version": "4.2.4", + "bundled": true + }, + "har-schema": { + "version": "2.0.0", + "bundled": true + }, + "har-validator": { + "version": "5.1.0", + "bundled": true, + "requires": { + "ajv": "^5.3.0", + "har-schema": "^2.0.0" + } + }, + "has": { + "version": "1.0.3", + "bundled": true, + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-flag": { + "version": "3.0.0", + "bundled": true + }, + "has-symbols": { + "version": "1.0.0", + "bundled": true + }, + "has-unicode": { + "version": "2.0.1", + "bundled": true + }, + "hosted-git-info": { + "version": "2.8.8", + "bundled": true + }, + "http-cache-semantics": { + "version": "3.8.1", + "bundled": true + }, + "http-proxy-agent": { + "version": "2.1.0", + "bundled": true, + "requires": { + "agent-base": "4", + "debug": "3.1.0" + } + }, + "http-signature": { + "version": "1.2.0", + "bundled": true, + "requires": { + "assert-plus": "^1.0.0", + "jsprim": "^1.2.2", + "sshpk": "^1.7.0" + } + }, + "https-proxy-agent": { + "version": "2.2.4", + "bundled": true, + "requires": { + "agent-base": "^4.3.0", + "debug": "^3.1.0" + } + }, + "humanize-ms": { + "version": "1.2.1", + "bundled": true, + "requires": { + "ms": "^2.0.0" + } + }, + "iconv-lite": { + "version": "0.4.23", + "bundled": true, + "requires": { + "safer-buffer": ">= 2.1.2 < 3" + } + }, + "iferr": { + "version": "1.0.2", + "bundled": true + }, + "ignore-walk": { + "version": "3.0.3", + "bundled": true, + "requires": { + "minimatch": "^3.0.4" + } + }, + "import-lazy": { + "version": "2.1.0", + "bundled": true + }, + "imurmurhash": { + "version": "0.1.4", + "bundled": true + }, + "infer-owner": { + "version": "1.0.4", + "bundled": true + }, + "inflight": { + "version": "1.0.6", + "bundled": true, + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "bundled": true + }, + "ini": { + "version": "1.3.5", + "bundled": true + }, + "init-package-json": { + "version": "1.10.3", + "bundled": true, + "requires": { + "glob": "^7.1.1", + "npm-package-arg": "^4.0.0 || ^5.0.0 || ^6.0.0", + "promzard": "^0.3.0", + "read": "~1.0.1", + "read-package-json": "1 || 2", + "semver": "2.x || 3.x || 4 || 5", + "validate-npm-package-license": "^3.0.1", + "validate-npm-package-name": "^3.0.0" + } + }, + "ip": { + "version": "1.1.5", + "bundled": true + }, + "ip-regex": { + "version": "2.1.0", + "bundled": true + }, + "is-callable": { + "version": "1.1.4", + "bundled": true + }, + "is-ci": { + "version": "1.2.1", + "bundled": true, + "requires": { + "ci-info": "^1.5.0" + }, + "dependencies": { + "ci-info": { + "version": "1.6.0", + "bundled": true + } + } + }, + "is-cidr": { + "version": "3.0.0", + "bundled": true, + "requires": { + "cidr-regex": "^2.0.10" + } + }, + "is-date-object": { + "version": "1.0.1", + "bundled": true + }, + "is-fullwidth-code-point": { + "version": "1.0.0", + "bundled": true, + "requires": { + "number-is-nan": "^1.0.0" + } + }, + "is-installed-globally": { + "version": "0.1.0", + "bundled": true, + "requires": { + "global-dirs": "^0.1.0", + "is-path-inside": "^1.0.0" + } + }, + "is-npm": { + "version": "1.0.0", + "bundled": true + }, + "is-obj": { + "version": "1.0.1", + "bundled": true + }, + "is-path-inside": { + "version": "1.0.1", + "bundled": true, + "requires": { + "path-is-inside": "^1.0.1" + } + }, + "is-redirect": { + "version": "1.0.0", + "bundled": true + }, + "is-regex": { + "version": "1.0.4", + "bundled": true, + "requires": { + "has": "^1.0.1" + } + }, + "is-retry-allowed": { + "version": "1.2.0", + "bundled": true + }, + "is-stream": { + "version": "1.1.0", + "bundled": true + }, + "is-symbol": { + "version": "1.0.2", + "bundled": true, + "requires": { + "has-symbols": "^1.0.0" + } + }, + "is-typedarray": { + "version": "1.0.0", + "bundled": true + }, + "isarray": { + "version": "1.0.0", + "bundled": true + }, + "isexe": { + "version": "2.0.0", + "bundled": true + }, + "isstream": { + "version": "0.1.2", + "bundled": true + }, + "jsbn": { + "version": "0.1.1", + "bundled": true, + "optional": true + }, + "json-parse-better-errors": { + "version": "1.0.2", + "bundled": true + }, + "json-schema": { + "version": "0.2.3", + "bundled": true + }, + "json-schema-traverse": { + "version": "0.3.1", + "bundled": true + }, + "json-stringify-safe": { + "version": "5.0.1", + "bundled": true + }, + "jsonparse": { + "version": "1.3.1", + "bundled": true + }, + "jsprim": { + "version": "1.4.1", + "bundled": true, + "requires": { + "assert-plus": "1.0.0", + "extsprintf": "1.3.0", + "json-schema": "0.2.3", + "verror": "1.10.0" + } + }, + "latest-version": { + "version": "3.1.0", + "bundled": true, + "requires": { + "package-json": "^4.0.0" + } + }, + "lazy-property": { + "version": "1.0.0", + "bundled": true + }, + "libcipm": { + "version": "4.0.8", + "bundled": true, + "requires": { + "bin-links": "^1.1.2", + "bluebird": "^3.5.1", + "figgy-pudding": "^3.5.1", + "find-npm-prefix": "^1.0.2", + "graceful-fs": "^4.1.11", + "ini": "^1.3.5", + "lock-verify": "^2.1.0", + "mkdirp": "^0.5.1", + "npm-lifecycle": "^3.0.0", + "npm-logical-tree": "^1.2.1", + "npm-package-arg": "^6.1.0", + "pacote": "^9.1.0", + "read-package-json": "^2.0.13", + "rimraf": "^2.6.2", + "worker-farm": "^1.6.0" + } + }, + "libnpm": { + "version": "3.0.1", + "bundled": true, + "requires": { + "bin-links": "^1.1.2", + "bluebird": "^3.5.3", + "find-npm-prefix": "^1.0.2", + "libnpmaccess": "^3.0.2", + "libnpmconfig": "^1.2.1", + "libnpmhook": "^5.0.3", + "libnpmorg": "^1.0.1", + "libnpmpublish": "^1.1.2", + "libnpmsearch": "^2.0.2", + "libnpmteam": "^1.0.2", + "lock-verify": "^2.0.2", + "npm-lifecycle": "^3.0.0", + "npm-logical-tree": "^1.2.1", + "npm-package-arg": "^6.1.0", + "npm-profile": "^4.0.2", + "npm-registry-fetch": "^4.0.0", + "npmlog": "^4.1.2", + "pacote": "^9.5.3", + "read-package-json": "^2.0.13", + "stringify-package": "^1.0.0" + } + }, + "libnpmaccess": { + "version": "3.0.2", + "bundled": true, + "requires": { + "aproba": "^2.0.0", + "get-stream": "^4.0.0", + "npm-package-arg": "^6.1.0", + "npm-registry-fetch": "^4.0.0" + } + }, + "libnpmconfig": { + "version": "1.2.1", + "bundled": true, + "requires": { + "figgy-pudding": "^3.5.1", + "find-up": "^3.0.0", + "ini": "^1.3.5" + }, + "dependencies": { + "find-up": { + "version": "3.0.0", + "bundled": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "bundled": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.2.0", + "bundled": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "bundled": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "p-try": { + "version": "2.2.0", + "bundled": true + } + } + }, + "libnpmhook": { + "version": "5.0.3", + "bundled": true, + "requires": { + "aproba": "^2.0.0", + "figgy-pudding": "^3.4.1", + "get-stream": "^4.0.0", + "npm-registry-fetch": "^4.0.0" + } + }, + "libnpmorg": { + "version": "1.0.1", + "bundled": true, + "requires": { + "aproba": "^2.0.0", + "figgy-pudding": "^3.4.1", + "get-stream": "^4.0.0", + "npm-registry-fetch": "^4.0.0" + } + }, + "libnpmpublish": { + "version": "1.1.2", + "bundled": true, + "requires": { + "aproba": "^2.0.0", + "figgy-pudding": "^3.5.1", + "get-stream": "^4.0.0", + "lodash.clonedeep": "^4.5.0", + "normalize-package-data": "^2.4.0", + "npm-package-arg": "^6.1.0", + "npm-registry-fetch": "^4.0.0", + "semver": "^5.5.1", + "ssri": "^6.0.1" + } + }, + "libnpmsearch": { + "version": "2.0.2", + "bundled": true, + "requires": { + "figgy-pudding": "^3.5.1", + "get-stream": "^4.0.0", + "npm-registry-fetch": "^4.0.0" + } + }, + "libnpmteam": { + "version": "1.0.2", + "bundled": true, + "requires": { + "aproba": "^2.0.0", + "figgy-pudding": "^3.4.1", + "get-stream": "^4.0.0", + "npm-registry-fetch": "^4.0.0" + } + }, + "libnpx": { + "version": "10.2.4", + "bundled": true, + "requires": { + "dotenv": "^5.0.1", + "npm-package-arg": "^6.0.0", + "rimraf": "^2.6.2", + "safe-buffer": "^5.1.0", + "update-notifier": "^2.3.0", + "which": "^1.3.0", + "y18n": "^4.0.0", + "yargs": "^14.2.3" + } + }, + "lock-verify": { + "version": "2.1.0", + "bundled": true, + "requires": { + "npm-package-arg": "^6.1.0", + "semver": "^5.4.1" + } + }, + "lockfile": { + "version": "1.0.4", + "bundled": true, + "requires": { + "signal-exit": "^3.0.2" + } + }, + "lodash._baseindexof": { + "version": "3.1.0", + "bundled": true + }, + "lodash._baseuniq": { + "version": "4.6.0", + "bundled": true, + "requires": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "lodash._bindcallback": { + "version": "3.0.1", + "bundled": true + }, + "lodash._cacheindexof": { + "version": "3.0.2", + "bundled": true + }, + "lodash._createcache": { + "version": "3.1.2", + "bundled": true, + "requires": { + "lodash._getnative": "^3.0.0" + } + }, + "lodash._createset": { + "version": "4.0.3", + "bundled": true + }, + "lodash._getnative": { + "version": "3.9.1", + "bundled": true + }, + "lodash._root": { + "version": "3.0.1", + "bundled": true + }, + "lodash.clonedeep": { + "version": "4.5.0", + "bundled": true + }, + "lodash.restparam": { + "version": "3.6.1", + "bundled": true + }, + "lodash.union": { + "version": "4.6.0", + "bundled": true + }, + "lodash.uniq": { + "version": "4.5.0", + "bundled": true + }, + "lodash.without": { + "version": "4.4.0", + "bundled": true + }, + "lowercase-keys": { + "version": "1.0.1", + "bundled": true + }, + "lru-cache": { + "version": "5.1.1", + "bundled": true, + "requires": { + "yallist": "^3.0.2" + } + }, + "make-dir": { + "version": "1.3.0", + "bundled": true, + "requires": { + "pify": "^3.0.0" + } + }, + "make-fetch-happen": { + "version": "5.0.2", + "bundled": true, + "requires": { + "agentkeepalive": "^3.4.1", + "cacache": "^12.0.0", + "http-cache-semantics": "^3.8.1", + "http-proxy-agent": "^2.1.0", + "https-proxy-agent": "^2.2.3", + "lru-cache": "^5.1.1", + "mississippi": "^3.0.0", + "node-fetch-npm": "^2.0.2", + "promise-retry": "^1.1.1", + "socks-proxy-agent": "^4.0.0", + "ssri": "^6.0.0" + } + }, + "meant": { + "version": "1.0.1", + "bundled": true + }, + "mime-db": { + "version": "1.35.0", + "bundled": true + }, + "mime-types": { + "version": "2.1.19", + "bundled": true, + "requires": { + "mime-db": "~1.35.0" + } + }, + "minimatch": { + "version": "3.0.4", + "bundled": true, + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minizlib": { + "version": "1.3.3", + "bundled": true, + "requires": { + "minipass": "^2.9.0" + }, + "dependencies": { + "minipass": { + "version": "2.9.0", + "bundled": true, + "requires": { + "safe-buffer": "^5.1.2", + "yallist": "^3.0.0" + } + } + } + }, + "mississippi": { + "version": "3.0.0", + "bundled": true, + "requires": { + "concat-stream": "^1.5.0", + "duplexify": "^3.4.2", + "end-of-stream": "^1.1.0", + "flush-write-stream": "^1.0.0", + "from2": "^2.1.0", + "parallel-transform": "^1.1.0", + "pump": "^3.0.0", + "pumpify": "^1.3.3", + "stream-each": "^1.1.0", + "through2": "^2.0.0" + } + }, + "mkdirp": { + "version": "0.5.5", + "bundled": true, + "requires": { + "minimist": "^1.2.5" + }, + "dependencies": { + "minimist": { + "version": "1.2.5", + "bundled": true + } + } + }, + "move-concurrently": { + "version": "1.0.1", + "bundled": true, + "requires": { + "aproba": "^1.1.1", + "copy-concurrently": "^1.0.0", + "fs-write-stream-atomic": "^1.0.8", + "mkdirp": "^0.5.1", + "rimraf": "^2.5.4", + "run-queue": "^1.0.3" + }, + "dependencies": { + "aproba": { + "version": "1.2.0", + "bundled": true + } + } + }, + "ms": { + "version": "2.1.1", + "bundled": true + }, + "mute-stream": { + "version": "0.0.7", + "bundled": true + }, + "node-fetch-npm": { + "version": "2.0.2", + "bundled": true, + "requires": { + "encoding": "^0.1.11", + "json-parse-better-errors": "^1.0.0", + "safe-buffer": "^5.1.1" + } + }, + "node-gyp": { + "version": "5.1.0", + "bundled": true, + "requires": { + "env-paths": "^2.2.0", + "glob": "^7.1.4", + "graceful-fs": "^4.2.2", + "mkdirp": "^0.5.1", + "nopt": "^4.0.1", + "npmlog": "^4.1.2", + "request": "^2.88.0", + "rimraf": "^2.6.3", + "semver": "^5.7.1", + "tar": "^4.4.12", + "which": "^1.3.1" + } + }, + "nopt": { + "version": "4.0.3", + "bundled": true, + "requires": { + "abbrev": "1", + "osenv": "^0.1.4" + } + }, + "normalize-package-data": { + "version": "2.5.0", + "bundled": true, + "requires": { + "hosted-git-info": "^2.1.4", + "resolve": "^1.10.0", + "semver": "2 || 3 || 4 || 5", + "validate-npm-package-license": "^3.0.1" + }, + "dependencies": { + "resolve": { + "version": "1.10.0", + "bundled": true, + "requires": { + "path-parse": "^1.0.6" + } + } + } + }, + "npm-audit-report": { + "version": "1.3.3", + "bundled": true, + "requires": { + "cli-table3": "^0.5.0", + "console-control-strings": "^1.1.0" + } + }, + "npm-bundled": { + "version": "1.1.1", + "bundled": true, + "requires": { + "npm-normalize-package-bin": "^1.0.1" + } + }, + "npm-cache-filename": { + "version": "1.0.2", + "bundled": true + }, + "npm-install-checks": { + "version": "3.0.2", + "bundled": true, + "requires": { + "semver": "^2.3.0 || 3.x || 4 || 5" + } + }, + "npm-lifecycle": { + "version": "3.1.5", + "bundled": true, + "requires": { + "byline": "^5.0.0", + "graceful-fs": "^4.1.15", + "node-gyp": "^5.0.2", + "resolve-from": "^4.0.0", + "slide": "^1.1.6", + "uid-number": "0.0.6", + "umask": "^1.1.0", + "which": "^1.3.1" + } + }, + "npm-logical-tree": { + "version": "1.2.1", + "bundled": true + }, + "npm-normalize-package-bin": { + "version": "1.0.1", + "bundled": true + }, + "npm-package-arg": { + "version": "6.1.1", + "bundled": true, + "requires": { + "hosted-git-info": "^2.7.1", + "osenv": "^0.1.5", + "semver": "^5.6.0", + "validate-npm-package-name": "^3.0.0" + } + }, + "npm-packlist": { + "version": "1.4.8", + "bundled": true, + "requires": { + "ignore-walk": "^3.0.1", + "npm-bundled": "^1.0.1", + "npm-normalize-package-bin": "^1.0.1" + } + }, + "npm-pick-manifest": { + "version": "3.0.2", + "bundled": true, + "requires": { + "figgy-pudding": "^3.5.1", + "npm-package-arg": "^6.0.0", + "semver": "^5.4.1" + } + }, + "npm-profile": { + "version": "4.0.4", + "bundled": true, + "requires": { + "aproba": "^1.1.2 || 2", + "figgy-pudding": "^3.4.1", + "npm-registry-fetch": "^4.0.0" + } + }, + "npm-registry-fetch": { + "version": "4.0.5", + "bundled": true, + "requires": { + "JSONStream": "^1.3.4", + "bluebird": "^3.5.1", + "figgy-pudding": "^3.4.1", + "lru-cache": "^5.1.1", + "make-fetch-happen": "^5.0.0", + "npm-package-arg": "^6.1.0", + "safe-buffer": "^5.2.0" + }, + "dependencies": { + "safe-buffer": { + "version": "5.2.1", + "bundled": true + } + } + }, + "npm-run-path": { + "version": "2.0.2", + "bundled": true, + "requires": { + "path-key": "^2.0.0" + } + }, + "npm-user-validate": { + "version": "1.0.0", + "bundled": true + }, + "npmlog": { + "version": "4.1.2", + "bundled": true, + "requires": { + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" + } + }, + "number-is-nan": { + "version": "1.0.1", + "bundled": true + }, + "oauth-sign": { + "version": "0.9.0", + "bundled": true + }, + "object-assign": { + "version": "4.1.1", + "bundled": true + }, + "object-keys": { + "version": "1.0.12", + "bundled": true + }, + "object.getownpropertydescriptors": { + "version": "2.0.3", + "bundled": true, + "requires": { + "define-properties": "^1.1.2", + "es-abstract": "^1.5.1" + } + }, + "once": { + "version": "1.4.0", + "bundled": true, + "requires": { + "wrappy": "1" + } + }, + "opener": { + "version": "1.5.1", + "bundled": true + }, + "os-homedir": { + "version": "1.0.2", + "bundled": true + }, + "os-tmpdir": { + "version": "1.0.2", + "bundled": true + }, + "osenv": { + "version": "0.1.5", + "bundled": true, + "requires": { + "os-homedir": "^1.0.0", + "os-tmpdir": "^1.0.0" + } + }, + "p-finally": { + "version": "1.0.0", + "bundled": true + }, + "package-json": { + "version": "4.0.1", + "bundled": true, + "requires": { + "got": "^6.7.1", + "registry-auth-token": "^3.0.1", + "registry-url": "^3.0.3", + "semver": "^5.1.0" + } + }, + "pacote": { + "version": "9.5.12", + "bundled": true, + "requires": { + "bluebird": "^3.5.3", + "cacache": "^12.0.2", + "chownr": "^1.1.2", + "figgy-pudding": "^3.5.1", + "get-stream": "^4.1.0", + "glob": "^7.1.3", + "infer-owner": "^1.0.4", + "lru-cache": "^5.1.1", + "make-fetch-happen": "^5.0.0", + "minimatch": "^3.0.4", + "minipass": "^2.3.5", + "mississippi": "^3.0.0", + "mkdirp": "^0.5.1", + "normalize-package-data": "^2.4.0", + "npm-normalize-package-bin": "^1.0.0", + "npm-package-arg": "^6.1.0", + "npm-packlist": "^1.1.12", + "npm-pick-manifest": "^3.0.0", + "npm-registry-fetch": "^4.0.0", + "osenv": "^0.1.5", + "promise-inflight": "^1.0.1", + "promise-retry": "^1.1.1", + "protoduck": "^5.0.1", + "rimraf": "^2.6.2", + "safe-buffer": "^5.1.2", + "semver": "^5.6.0", + "ssri": "^6.0.1", + "tar": "^4.4.10", + "unique-filename": "^1.1.1", + "which": "^1.3.1" + }, + "dependencies": { + "minipass": { + "version": "2.9.0", + "bundled": true, + "requires": { + "safe-buffer": "^5.1.2", + "yallist": "^3.0.0" + } + } + } + }, + "parallel-transform": { + "version": "1.1.0", + "bundled": true, + "requires": { + "cyclist": "~0.2.2", + "inherits": "^2.0.3", + "readable-stream": "^2.1.5" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "path-exists": { + "version": "3.0.0", + "bundled": true + }, + "path-is-absolute": { + "version": "1.0.1", + "bundled": true + }, + "path-is-inside": { + "version": "1.0.2", + "bundled": true + }, + "path-key": { + "version": "2.0.1", + "bundled": true + }, + "path-parse": { + "version": "1.0.6", + "bundled": true + }, + "performance-now": { + "version": "2.1.0", + "bundled": true + }, + "pify": { + "version": "3.0.0", + "bundled": true + }, + "prepend-http": { + "version": "1.0.4", + "bundled": true + }, + "process-nextick-args": { + "version": "2.0.0", + "bundled": true + }, + "promise-inflight": { + "version": "1.0.1", + "bundled": true + }, + "promise-retry": { + "version": "1.1.1", + "bundled": true, + "requires": { + "err-code": "^1.0.0", + "retry": "^0.10.0" + }, + "dependencies": { + "retry": { + "version": "0.10.1", + "bundled": true + } + } + }, + "promzard": { + "version": "0.3.0", + "bundled": true, + "requires": { + "read": "1" + } + }, + "proto-list": { + "version": "1.2.4", + "bundled": true + }, + "protoduck": { + "version": "5.0.1", + "bundled": true, + "requires": { + "genfun": "^5.0.0" + } + }, + "prr": { + "version": "1.0.1", + "bundled": true + }, + "pseudomap": { + "version": "1.0.2", + "bundled": true + }, + "psl": { + "version": "1.1.29", + "bundled": true + }, + "pump": { + "version": "3.0.0", + "bundled": true, + "requires": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "pumpify": { + "version": "1.5.1", + "bundled": true, + "requires": { + "duplexify": "^3.6.0", + "inherits": "^2.0.3", + "pump": "^2.0.0" + }, + "dependencies": { + "pump": { + "version": "2.0.1", + "bundled": true, + "requires": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + } + } + }, + "punycode": { + "version": "1.4.1", + "bundled": true + }, + "qrcode-terminal": { + "version": "0.12.0", + "bundled": true + }, + "qs": { + "version": "6.5.2", + "bundled": true + }, + "query-string": { + "version": "6.8.2", + "bundled": true, + "requires": { + "decode-uri-component": "^0.2.0", + "split-on-first": "^1.0.0", + "strict-uri-encode": "^2.0.0" + } + }, + "qw": { + "version": "1.0.1", + "bundled": true + }, + "rc": { + "version": "1.2.8", + "bundled": true, + "requires": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "dependencies": { + "minimist": { + "version": "1.2.5", + "bundled": true + } + } + }, + "read": { + "version": "1.0.7", + "bundled": true, + "requires": { + "mute-stream": "~0.0.4" + } + }, + "read-cmd-shim": { + "version": "1.0.5", + "bundled": true, + "requires": { + "graceful-fs": "^4.1.2" + } + }, + "read-installed": { + "version": "4.0.3", + "bundled": true, + "requires": { + "debuglog": "^1.0.1", + "graceful-fs": "^4.1.2", + "read-package-json": "^2.0.0", + "readdir-scoped-modules": "^1.0.0", + "semver": "2 || 3 || 4 || 5", + "slide": "~1.1.3", + "util-extend": "^1.0.1" + } + }, + "read-package-json": { + "version": "2.1.1", + "bundled": true, + "requires": { + "glob": "^7.1.1", + "graceful-fs": "^4.1.2", + "json-parse-better-errors": "^1.0.1", + "normalize-package-data": "^2.0.0", + "npm-normalize-package-bin": "^1.0.0" + } + }, + "read-package-tree": { + "version": "5.3.1", + "bundled": true, + "requires": { + "read-package-json": "^2.0.0", + "readdir-scoped-modules": "^1.0.0", + "util-promisify": "^2.1.0" + } + }, + "readable-stream": { + "version": "3.6.0", + "bundled": true, + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + }, + "readdir-scoped-modules": { + "version": "1.1.0", + "bundled": true, + "requires": { + "debuglog": "^1.0.1", + "dezalgo": "^1.0.0", + "graceful-fs": "^4.1.2", + "once": "^1.3.0" + } + }, + "registry-auth-token": { + "version": "3.4.0", + "bundled": true, + "requires": { + "rc": "^1.1.6", + "safe-buffer": "^5.0.1" + } + }, + "registry-url": { + "version": "3.1.0", + "bundled": true, + "requires": { + "rc": "^1.0.1" + } + }, + "request": { + "version": "2.88.0", + "bundled": true, + "requires": { + "aws-sign2": "~0.7.0", + "aws4": "^1.8.0", + "caseless": "~0.12.0", + "combined-stream": "~1.0.6", + "extend": "~3.0.2", + "forever-agent": "~0.6.1", + "form-data": "~2.3.2", + "har-validator": "~5.1.0", + "http-signature": "~1.2.0", + "is-typedarray": "~1.0.0", + "isstream": "~0.1.2", + "json-stringify-safe": "~5.0.1", + "mime-types": "~2.1.19", + "oauth-sign": "~0.9.0", + "performance-now": "^2.1.0", + "qs": "~6.5.2", + "safe-buffer": "^5.1.2", + "tough-cookie": "~2.4.3", + "tunnel-agent": "^0.6.0", + "uuid": "^3.3.2" + } + }, + "require-directory": { + "version": "2.1.1", + "bundled": true + }, + "require-main-filename": { + "version": "2.0.0", + "bundled": true + }, + "resolve-from": { + "version": "4.0.0", + "bundled": true + }, + "retry": { + "version": "0.12.0", + "bundled": true + }, + "rimraf": { + "version": "2.7.1", + "bundled": true, + "requires": { + "glob": "^7.1.3" + } + }, + "run-queue": { + "version": "1.0.3", + "bundled": true, + "requires": { + "aproba": "^1.1.1" + }, + "dependencies": { + "aproba": { + "version": "1.2.0", + "bundled": true + } + } + }, + "safe-buffer": { + "version": "5.1.2", + "bundled": true + }, + "safer-buffer": { + "version": "2.1.2", + "bundled": true + }, + "semver": { + "version": "5.7.1", + "bundled": true + }, + "semver-diff": { + "version": "2.1.0", + "bundled": true, + "requires": { + "semver": "^5.0.3" + } + }, + "set-blocking": { + "version": "2.0.0", + "bundled": true + }, + "sha": { + "version": "3.0.0", + "bundled": true, + "requires": { + "graceful-fs": "^4.1.2" + } + }, + "shebang-command": { + "version": "1.2.0", + "bundled": true, + "requires": { + "shebang-regex": "^1.0.0" + } + }, + "shebang-regex": { + "version": "1.0.0", + "bundled": true + }, + "signal-exit": { + "version": "3.0.2", + "bundled": true + }, + "slide": { + "version": "1.1.6", + "bundled": true + }, + "smart-buffer": { + "version": "4.1.0", + "bundled": true + }, + "socks": { + "version": "2.3.3", + "bundled": true, + "requires": { + "ip": "1.1.5", + "smart-buffer": "^4.1.0" + } + }, + "socks-proxy-agent": { + "version": "4.0.2", + "bundled": true, + "requires": { + "agent-base": "~4.2.1", + "socks": "~2.3.2" + }, + "dependencies": { + "agent-base": { + "version": "4.2.1", + "bundled": true, + "requires": { + "es6-promisify": "^5.0.0" + } + } + } + }, + "sorted-object": { + "version": "2.0.1", + "bundled": true + }, + "sorted-union-stream": { + "version": "2.1.3", + "bundled": true, + "requires": { + "from2": "^1.3.0", + "stream-iterate": "^1.1.0" + }, + "dependencies": { + "from2": { + "version": "1.3.0", + "bundled": true, + "requires": { + "inherits": "~2.0.1", + "readable-stream": "~1.1.10" + } + }, + "isarray": { + "version": "0.0.1", + "bundled": true + }, + "readable-stream": { + "version": "1.1.14", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "0.0.1", + "string_decoder": "~0.10.x" + } + }, + "string_decoder": { + "version": "0.10.31", + "bundled": true + } + } + }, + "spdx-correct": { + "version": "3.0.0", + "bundled": true, + "requires": { + "spdx-expression-parse": "^3.0.0", + "spdx-license-ids": "^3.0.0" + } + }, + "spdx-exceptions": { + "version": "2.1.0", + "bundled": true + }, + "spdx-expression-parse": { + "version": "3.0.0", + "bundled": true, + "requires": { + "spdx-exceptions": "^2.1.0", + "spdx-license-ids": "^3.0.0" + } + }, + "spdx-license-ids": { + "version": "3.0.5", + "bundled": true + }, + "split-on-first": { + "version": "1.1.0", + "bundled": true + }, + "sshpk": { + "version": "1.14.2", + "bundled": true, + "requires": { + "asn1": "~0.2.3", + "assert-plus": "^1.0.0", + "bcrypt-pbkdf": "^1.0.0", + "dashdash": "^1.12.0", + "ecc-jsbn": "~0.1.1", + "getpass": "^0.1.1", + "jsbn": "~0.1.0", + "safer-buffer": "^2.0.2", + "tweetnacl": "~0.14.0" + } + }, + "ssri": { + "version": "6.0.1", + "bundled": true, + "requires": { + "figgy-pudding": "^3.5.1" + } + }, + "stream-each": { + "version": "1.2.2", + "bundled": true, + "requires": { + "end-of-stream": "^1.1.0", + "stream-shift": "^1.0.0" + } + }, + "stream-iterate": { + "version": "1.2.0", + "bundled": true, + "requires": { + "readable-stream": "^2.1.5", + "stream-shift": "^1.0.0" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "stream-shift": { + "version": "1.0.0", + "bundled": true + }, + "strict-uri-encode": { + "version": "2.0.0", + "bundled": true + }, + "string-width": { + "version": "2.1.1", + "bundled": true, + "requires": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "bundled": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "bundled": true + }, + "strip-ansi": { + "version": "4.0.0", + "bundled": true, + "requires": { + "ansi-regex": "^3.0.0" + } + } + } + }, + "string_decoder": { + "version": "1.3.0", + "bundled": true, + "requires": { + "safe-buffer": "~5.2.0" + }, + "dependencies": { + "safe-buffer": { + "version": "5.2.0", + "bundled": true + } + } + }, + "stringify-package": { + "version": "1.0.1", + "bundled": true + }, + "strip-ansi": { + "version": "3.0.1", + "bundled": true, + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "strip-eof": { + "version": "1.0.0", + "bundled": true + }, + "strip-json-comments": { + "version": "2.0.1", + "bundled": true + }, + "supports-color": { + "version": "5.4.0", + "bundled": true, + "requires": { + "has-flag": "^3.0.0" + } + }, + "tar": { + "version": "4.4.13", + "bundled": true, + "requires": { + "chownr": "^1.1.1", + "fs-minipass": "^1.2.5", + "minipass": "^2.8.6", + "minizlib": "^1.2.1", + "mkdirp": "^0.5.0", + "safe-buffer": "^5.1.2", + "yallist": "^3.0.3" + }, + "dependencies": { + "minipass": { + "version": "2.9.0", + "bundled": true, + "requires": { + "safe-buffer": "^5.1.2", + "yallist": "^3.0.0" + } + } + } + }, + "term-size": { + "version": "1.2.0", + "bundled": true, + "requires": { + "execa": "^0.7.0" + } + }, + "text-table": { + "version": "0.2.0", + "bundled": true + }, + "through": { + "version": "2.3.8", + "bundled": true + }, + "through2": { + "version": "2.0.3", + "bundled": true, + "requires": { + "readable-stream": "^2.1.5", + "xtend": "~4.0.1" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.6", + "bundled": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "bundled": true, + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "timed-out": { + "version": "4.0.1", + "bundled": true + }, + "tiny-relative-date": { + "version": "1.3.0", + "bundled": true + }, + "tough-cookie": { + "version": "2.4.3", + "bundled": true, + "requires": { + "psl": "^1.1.24", + "punycode": "^1.4.1" + } + }, + "tunnel-agent": { + "version": "0.6.0", + "bundled": true, + "requires": { + "safe-buffer": "^5.0.1" + } + }, + "tweetnacl": { + "version": "0.14.5", + "bundled": true, + "optional": true + }, + "typedarray": { + "version": "0.0.6", + "bundled": true + }, + "uid-number": { + "version": "0.0.6", + "bundled": true + }, + "umask": { + "version": "1.1.0", + "bundled": true + }, + "unique-filename": { + "version": "1.1.1", + "bundled": true, + "requires": { + "unique-slug": "^2.0.0" + } + }, + "unique-slug": { + "version": "2.0.0", + "bundled": true, + "requires": { + "imurmurhash": "^0.1.4" + } + }, + "unique-string": { + "version": "1.0.0", + "bundled": true, + "requires": { + "crypto-random-string": "^1.0.0" + } + }, + "unpipe": { + "version": "1.0.0", + "bundled": true + }, + "unzip-response": { + "version": "2.0.1", + "bundled": true + }, + "update-notifier": { + "version": "2.5.0", + "bundled": true, + "requires": { + "boxen": "^1.2.1", + "chalk": "^2.0.1", + "configstore": "^3.0.0", + "import-lazy": "^2.1.0", + "is-ci": "^1.0.10", + "is-installed-globally": "^0.1.0", + "is-npm": "^1.0.0", + "latest-version": "^3.0.0", + "semver-diff": "^2.0.0", + "xdg-basedir": "^3.0.0" + } + }, + "url-parse-lax": { + "version": "1.0.0", + "bundled": true, + "requires": { + "prepend-http": "^1.0.1" + } + }, + "util-deprecate": { + "version": "1.0.2", + "bundled": true + }, + "util-extend": { + "version": "1.0.3", + "bundled": true + }, + "util-promisify": { + "version": "2.1.0", + "bundled": true, + "requires": { + "object.getownpropertydescriptors": "^2.0.3" + } + }, + "uuid": { + "version": "3.3.3", + "bundled": true + }, + "validate-npm-package-license": { + "version": "3.0.4", + "bundled": true, + "requires": { + "spdx-correct": "^3.0.0", + "spdx-expression-parse": "^3.0.0" + } + }, + "validate-npm-package-name": { + "version": "3.0.0", + "bundled": true, + "requires": { + "builtins": "^1.0.3" + } + }, + "verror": { + "version": "1.10.0", + "bundled": true, + "requires": { + "assert-plus": "^1.0.0", + "core-util-is": "1.0.2", + "extsprintf": "^1.2.0" + } + }, + "wcwidth": { + "version": "1.0.1", + "bundled": true, + "requires": { + "defaults": "^1.0.3" + } + }, + "which": { + "version": "1.3.1", + "bundled": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "bundled": true + }, + "wide-align": { + "version": "1.1.2", + "bundled": true, + "requires": { + "string-width": "^1.0.2" + }, + "dependencies": { + "string-width": { + "version": "1.0.2", + "bundled": true, + "requires": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + } + } + } + }, + "widest-line": { + "version": "2.0.1", + "bundled": true, + "requires": { + "string-width": "^2.1.1" + } + }, + "worker-farm": { + "version": "1.7.0", + "bundled": true, + "requires": { + "errno": "~0.1.7" + } + }, + "wrap-ansi": { + "version": "5.1.0", + "bundled": true, + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "bundled": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "bundled": true + }, + "string-width": { + "version": "3.1.0", + "bundled": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "bundled": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "wrappy": { + "version": "1.0.2", + "bundled": true + }, + "write-file-atomic": { + "version": "2.4.3", + "bundled": true, + "requires": { + "graceful-fs": "^4.1.11", + "imurmurhash": "^0.1.4", + "signal-exit": "^3.0.2" + } + }, + "xdg-basedir": { + "version": "3.0.0", + "bundled": true + }, + "xtend": { + "version": "4.0.1", + "bundled": true + }, + "y18n": { + "version": "4.0.0", + "bundled": true + }, + "yallist": { + "version": "3.0.3", + "bundled": true + }, + "yargs": { + "version": "14.2.3", + "bundled": true, + "requires": { + "cliui": "^5.0.0", + "decamelize": "^1.2.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^15.0.1" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "bundled": true + }, + "find-up": { + "version": "3.0.0", + "bundled": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "bundled": true + }, + "locate-path": { + "version": "3.0.0", + "bundled": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "p-limit": { + "version": "2.3.0", + "bundled": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "bundled": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "p-try": { + "version": "2.2.0", + "bundled": true + }, + "string-width": { + "version": "3.1.0", + "bundled": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "bundled": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } + } + }, + "yargs-parser": { + "version": "15.0.1", + "bundled": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + }, + "dependencies": { + "camelcase": { + "version": "5.3.1", + "bundled": true + } + } + } + } + }, + "or": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/or/-/or-0.2.0.tgz", + "integrity": "sha1-mQTqYeJZQ/k14g9PR0ngoUGoK2o=" + }, + "process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "readable-stream": { + "version": "2.3.7", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", + "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + }, + "dependencies": { + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + } + } + }, + "regexp-clone": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/regexp-clone/-/regexp-clone-1.0.0.tgz", + "integrity": "sha512-TuAasHQNamyyJ2hb97IuBEif4qBHGjPHBS64sZwytpLEqtBQ1gPJTnOaQ6qmpET16cK14kkjbazl6+p0RRv0yw==" + }, + "require_optional": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/require_optional/-/require_optional-1.0.1.tgz", + "integrity": "sha512-qhM/y57enGWHAe3v/NcwML6a3/vfESLe/sGM2dII+gEO0BpKRUkWZow/tyloNqJyN6kXSl3RyyM8Ll5D/sJP8g==", + "requires": { + "resolve-from": "^2.0.0", + "semver": "^5.1.0" + } + }, + "resolve-from": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-2.0.0.tgz", + "integrity": "sha1-lICrIOlP+h2egKgEx+oUdhGWa1c=" + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + }, + "saslprep": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/saslprep/-/saslprep-1.0.3.tgz", + "integrity": "sha512-/MY/PEMbk2SuY5sScONwhUDsV2p77Znkb/q3nSVstq/yQzYJOH/Azh29p9oJLsl3LnQwSvZDKagDGBsBwSooag==", + "optional": true, + "requires": { + "sparse-bitfield": "^3.0.3" + } + }, + "semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" + }, + "sift": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/sift/-/sift-7.0.1.tgz", + "integrity": "sha512-oqD7PMJ+uO6jV9EQCl0LrRw1OwsiPsiFQR5AR30heR+4Dl7jBBbDLnNvWiak20tzZlSE1H7RB30SX/1j/YYT7g==" + }, + "sliced": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/sliced/-/sliced-1.0.1.tgz", + "integrity": "sha1-CzpmK10Ewxd7GSa+qCsD+Dei70E=" + }, + "sparse-bitfield": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/sparse-bitfield/-/sparse-bitfield-3.0.3.tgz", + "integrity": "sha1-/0rm5oZWBWuks+eSqzM004JzyhE=", + "optional": true, + "requires": { + "memory-pager": "^1.0.2" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "~5.1.0" + }, + "dependencies": { + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + } + } + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" + } + } +} diff --git a/packages/copchase/package.json b/packages/copchase/package.json new file mode 100644 index 0000000..49844f0 --- /dev/null +++ b/packages/copchase/package.json @@ -0,0 +1,20 @@ +{ + "name": "copchase", + "version": "1.0.0", + "description": "", + "main": "index.js", + "dependencies": { + "bcryptjs": "^2.4.3", + "install": "^0.13.0", + "mongoose": "^5.9.26", + "npm": "^6.14.7", + "or": "^0.2.0" + }, + "devDependencies": {}, + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "keywords": [], + "author": "", + "license": "ISC" +}