├── .gitignore ├── .slipe ├── Assets ├── m4.dff └── m4.txd ├── DocFX ├── .gitignore ├── DocFX.csproj ├── _exported_templates │ └── default │ │ ├── ManagedReference.common.js │ │ ├── ManagedReference.extension.js │ │ ├── ManagedReference.html.primary.js │ │ ├── ManagedReference.html.primary.tmpl │ │ ├── RestApi.common.js │ │ ├── RestApi.extension.js │ │ ├── RestApi.html.primary.js │ │ ├── RestApi.html.primary.tmpl │ │ ├── UniversalReference.common.js │ │ ├── UniversalReference.extension.js │ │ ├── UniversalReference.html.primary.js │ │ ├── UniversalReference.html.primary.tmpl │ │ ├── common.js │ │ ├── conceptual.extension.js │ │ ├── conceptual.html.primary.js │ │ ├── conceptual.html.primary.tmpl │ │ ├── favicon.ico │ │ ├── fonts │ │ ├── glyphicons-halflings-regular.eot │ │ ├── glyphicons-halflings-regular.svg │ │ ├── glyphicons-halflings-regular.ttf │ │ ├── glyphicons-halflings-regular.woff │ │ └── glyphicons-halflings-regular.woff2 │ │ ├── layout │ │ └── _master.tmpl │ │ ├── logo.svg │ │ ├── partials │ │ ├── _affix.liquid │ │ ├── _breadcrumb.liquid │ │ ├── _footer.liquid │ │ ├── _head.liquid │ │ ├── _logo.liquid │ │ ├── _navbar.liquid │ │ ├── _scripts.liquid │ │ ├── _toc.liquid │ │ ├── affix.tmpl.partial │ │ ├── breadcrumb.tmpl.partial │ │ ├── class.header.tmpl.partial │ │ ├── class.tmpl.partial │ │ ├── classSubtitle.tmpl.partial │ │ ├── customMREFContent.tmpl.partial │ │ ├── dd-li.tmpl.partial │ │ ├── enum.tmpl.partial │ │ ├── footer.tmpl.partial │ │ ├── head.tmpl.partial │ │ ├── li.tmpl.partial │ │ ├── logo.tmpl.partial │ │ ├── namespace.tmpl.partial │ │ ├── namespaceSubtitle.tmpl.partial │ │ ├── navbar.tmpl.partial │ │ ├── rest.child.tmpl.partial │ │ ├── rest.tmpl.partial │ │ ├── scripts.tmpl.partial │ │ ├── searchResults.tmpl.partial │ │ ├── title.tmpl.partial │ │ ├── toc.tmpl.partial │ │ └── uref │ │ │ ├── class.header.tmpl.partial │ │ │ ├── class.tmpl.partial │ │ │ ├── enum.tmpl.partial │ │ │ └── parameters.tmpl.partial │ │ ├── search-stopwords.json │ │ ├── styles │ │ ├── docfx.css │ │ ├── docfx.js │ │ ├── docfx.vendor.css │ │ ├── docfx.vendor.js │ │ ├── lunr.js │ │ ├── lunr.min.js │ │ ├── main.css │ │ ├── main.js │ │ └── search-worker.js │ │ ├── toc.extension.js │ │ ├── toc.html.js │ │ ├── toc.html.tmpl │ │ └── token.json ├── docfx.json ├── docs │ ├── cli.md │ ├── exporting.md │ ├── firstResource.md │ ├── inheritance.md │ ├── installation.md │ ├── libraries.md │ ├── modules.md │ ├── roadmap.md │ ├── rpc.md │ ├── snippets.md │ ├── sql.md │ ├── toc.yml │ ├── utilities.md │ ├── visualStudio.md │ └── webhook.md ├── images │ ├── logo_large.png │ └── visualStudio │ │ ├── addReference.png │ │ ├── buildContext.png │ │ ├── buildMenu.png │ │ ├── debug.png │ │ ├── referenceManager.png │ │ ├── solutionExplorer.png │ │ └── solutionLibrary.png ├── index.md ├── template │ ├── favicon.ico │ ├── index.html.tmpl │ ├── layout │ │ └── _master.tmpl │ ├── logo.png │ ├── partials │ │ ├── _logo.liquid │ │ ├── head.tmpl.partial │ │ └── logo.tmpl.partial │ └── styles │ │ ├── main.css │ │ └── main.js └── toc.yml ├── LICENSE.md ├── README.md ├── Resource.sln ├── Slipe ├── Compiler │ ├── CSharp.lua.Launcher.deps.json │ ├── CSharp.lua.Launcher.dll │ ├── CSharp.lua.Launcher.pdb │ ├── CSharp.lua.Launcher.runtimeconfig.dev.json │ ├── CSharp.lua.Launcher.runtimeconfig.json │ ├── CSharp.lua.dll │ ├── CSharp.lua.pdb │ ├── Microsoft.CodeAnalysis.CSharp.dll │ ├── Microsoft.CodeAnalysis.dll │ ├── System.xml │ └── runtimes │ │ ├── unix │ │ └── lib │ │ │ └── netstandard1.3 │ │ │ └── System.Text.Encoding.CodePages.dll │ │ └── win │ │ └── lib │ │ ├── netcoreapp2.0 │ │ └── System.Text.Encoding.CodePages.dll │ │ └── netstandard1.3 │ │ └── System.Text.Encoding.CodePages.dll ├── Core │ ├── Lua │ │ ├── Backing │ │ │ ├── SlipeMTADfinitions │ │ │ │ ├── client.lua │ │ │ │ ├── events.lua │ │ │ │ ├── exports.lua │ │ │ │ ├── json.lua │ │ │ │ ├── server.lua │ │ │ │ └── shared.lua │ │ │ └── SlipeSql │ │ │ │ ├── Database.lua │ │ │ │ ├── MySqlConnectionString.lua │ │ │ │ ├── SqlOptions.lua │ │ │ │ └── SqlValue.lua │ │ └── SystemComponents │ │ │ ├── Array.lua │ │ │ ├── ArraySegment.lua │ │ │ ├── Boolean.lua │ │ │ ├── Char.lua │ │ │ ├── Collection.lua │ │ │ ├── Collections │ │ │ ├── Dictionary.lua │ │ │ ├── EqualityComparer.lua │ │ │ ├── HashSet.lua │ │ │ ├── LinkedList.lua │ │ │ ├── Linq.lua │ │ │ ├── List.lua │ │ │ ├── Queue.lua │ │ │ └── Stack.lua │ │ │ ├── Component.lua │ │ │ ├── Console.lua │ │ │ ├── Convert.lua │ │ │ ├── Core.lua │ │ │ ├── DateTime.lua │ │ │ ├── Debug.lua │ │ │ ├── Delegate.lua │ │ │ ├── Enum.lua │ │ │ ├── Exception.lua │ │ │ ├── Globalization │ │ │ └── Globalization.lua │ │ │ ├── IO │ │ │ └── File.lua │ │ │ ├── Interfaces.lua │ │ │ ├── Math.lua │ │ │ ├── Net │ │ │ ├── EndPoint.lua │ │ │ ├── Http │ │ │ │ ├── FormUrlEncodedContent.lua │ │ │ │ ├── HttpClient.lua │ │ │ │ ├── HttpContent.lua │ │ │ │ ├── HttpResponseMessage.lua │ │ │ │ └── StringContent.lua │ │ │ ├── IPAddress.lua │ │ │ └── Sockets │ │ │ │ └── Socket.lua │ │ │ ├── Number.lua │ │ │ ├── Numerics │ │ │ ├── Complex.lua │ │ │ ├── HashCodeHelper.lua │ │ │ ├── Matrix3x2.lua │ │ │ ├── Matrix4x4.lua │ │ │ ├── Plane.lua │ │ │ ├── Quaternion.lua │ │ │ ├── Vector2.lua │ │ │ ├── Vector3.lua │ │ │ └── Vector4.lua │ │ │ ├── Random.lua │ │ │ ├── Reflection │ │ │ └── Assembly.lua │ │ │ ├── String.lua │ │ │ ├── SystemExtensions.lua │ │ │ ├── Text │ │ │ ├── Encoding.lua │ │ │ └── StringBuilder.lua │ │ │ ├── Threads │ │ │ ├── Task.lua │ │ │ ├── Thread.lua │ │ │ └── Timer.lua │ │ │ ├── TimeSpan.lua │ │ │ ├── Timers │ │ │ ├── ElapsedEventArgs.lua │ │ │ └── Timer.lua │ │ │ ├── Type.lua │ │ │ ├── Utilities.lua │ │ │ └── Xml │ │ │ ├── XmlAttribute.lua │ │ │ ├── XmlAttributeCollection.lua │ │ │ ├── XmlDocument.lua │ │ │ ├── XmlElement.lua │ │ │ ├── XmlNode.lua │ │ │ └── XmlNodeList.lua │ └── Source │ │ ├── SlipeClient │ │ ├── Assets │ │ │ ├── Asset.cs │ │ │ ├── Col.cs │ │ │ ├── CustomAnimation.cs │ │ │ ├── DFF.cs │ │ │ ├── DownloadState.cs │ │ │ ├── IFP.cs │ │ │ ├── Mod.cs │ │ │ └── TXD.cs │ │ ├── Browsers │ │ │ ├── BlockReason.cs │ │ │ ├── Browser.cs │ │ │ ├── Events │ │ │ │ ├── OnCreatedEventArgs.cs │ │ │ │ ├── OnCursorChangeEventArgs.cs │ │ │ │ ├── OnDocumentReadEventArgs.cs │ │ │ │ ├── OnInputFocusChangeEventArgs.cs │ │ │ │ ├── OnLoadFailEventArgs.cs │ │ │ │ ├── OnLoadStartEventArgs.cs │ │ │ │ ├── OnNavigateEventArgs.cs │ │ │ │ ├── OnPopupEventArgs.cs │ │ │ │ ├── OnResourceBlockedEventArgs.cs │ │ │ │ ├── OnTooltipEventArgs.cs │ │ │ │ └── OnWhiteListChangeEventArgs.cs │ │ │ └── JavascriptVariable.cs │ │ ├── Dx │ │ │ ├── Align.cs │ │ │ ├── Circle.cs │ │ │ ├── Dx.cs │ │ │ ├── Dx2DObject.cs │ │ │ ├── Dx3DLine.cs │ │ │ ├── Dx3DMaterialLine.cs │ │ │ ├── Dx3DMaterialLineSection.cs │ │ │ ├── DxEnums.cs │ │ │ ├── Font.cs │ │ │ ├── FontQuality.cs │ │ │ ├── IDrawable.cs │ │ │ ├── Image.cs │ │ │ ├── ImageSection.cs │ │ │ ├── Line.cs │ │ │ ├── Material.cs │ │ │ ├── Rectangle.cs │ │ │ ├── ScreenSource.cs │ │ │ ├── Shader.cs │ │ │ ├── StandardFont.cs │ │ │ ├── Text.cs │ │ │ ├── Texture.cs │ │ │ ├── TexturePixels.cs │ │ │ └── Vertice.cs │ │ ├── Effects │ │ │ ├── Effect.cs │ │ │ ├── EffectType.cs │ │ │ └── Fx.cs │ │ ├── Elements │ │ │ ├── ElementExtensions.cs │ │ │ ├── Events │ │ │ │ ├── OnExplosionEventArgs.cs │ │ │ │ └── OnWorldSoundEventArgs.cs │ │ │ ├── ResourceRootElement.cs │ │ │ └── RootElement.cs │ │ ├── Events │ │ │ └── Event.cs │ │ ├── Explosions │ │ │ └── Explosion.cs │ │ ├── Game │ │ │ ├── Engine.cs │ │ │ ├── Events │ │ │ │ ├── OnFileDownloadCompleteEventArgs.cs │ │ │ │ ├── OnMinimizeEventArgs.cs │ │ │ │ ├── OnNetworkInteruptionEventArgs.cs │ │ │ │ ├── OnRestoreEventArgs.cs │ │ │ │ ├── OnStartEventArgs.cs │ │ │ │ ├── OnStopEventArgs.cs │ │ │ │ └── OnUpdateEventArgs.cs │ │ │ ├── GameClient.cs │ │ │ ├── InputMode.cs │ │ │ ├── Team.cs │ │ │ └── TrayIconType.cs │ │ ├── GameWorld │ │ │ ├── AmbientSound.cs │ │ │ ├── Events │ │ │ │ ├── OnBreakEventArgs.cs │ │ │ │ └── OnDamageEventArgs.cs │ │ │ ├── Fire.cs │ │ │ ├── Garage.cs │ │ │ ├── RoomFurniture.cs │ │ │ ├── SurfaceMaterialEnums.cs │ │ │ ├── SwatRope.cs │ │ │ ├── Water.cs │ │ │ ├── World.cs │ │ │ ├── WorldObject.cs │ │ │ ├── WorldSoundGroup.cs │ │ │ └── WorldSpecialProperty.cs │ │ ├── Gui │ │ │ ├── Button.cs │ │ │ ├── CheckBox.cs │ │ │ ├── ComboBox.cs │ │ │ ├── ComboBoxItem.cs │ │ │ ├── Edit.cs │ │ │ ├── EditableGuiElement.cs │ │ │ ├── Events │ │ │ │ ├── OnAcceptedEventArgs.cs │ │ │ │ ├── OnBlurEventArgs.cs │ │ │ │ ├── OnChangedEventArgs.cs │ │ │ │ ├── OnClickEventArgs.cs │ │ │ │ ├── OnDoubleClickEventArgs.cs │ │ │ │ ├── OnFocusEventArgs.cs │ │ │ │ ├── OnMouseDownEventArgs.cs │ │ │ │ ├── OnMouseEnterEventArgs.cs │ │ │ │ ├── OnMouseLeaveEventArgs.cs │ │ │ │ ├── OnMouseMoveEventArgs.cs │ │ │ │ ├── OnMouseUpEventArgs.cs │ │ │ │ ├── OnMouseWheelEventArgs.cs │ │ │ │ ├── OnMoveEventArgs.cs │ │ │ │ ├── OnOpenEventArgs.cs │ │ │ │ ├── OnResizeEventArgs.cs │ │ │ │ └── OnScrollEventArgs.cs │ │ │ ├── GridColumn.cs │ │ │ ├── GridItem.cs │ │ │ ├── GridList.cs │ │ │ ├── GridRow.cs │ │ │ ├── GuiAlign.cs │ │ │ ├── GuiBrowser.cs │ │ │ ├── GuiElement.cs │ │ │ ├── GuiFont.cs │ │ │ ├── Label.cs │ │ │ ├── Memo.cs │ │ │ ├── ProgressBar.cs │ │ │ ├── RadioButton.cs │ │ │ ├── ScrollBar.cs │ │ │ ├── ScrollPane.cs │ │ │ ├── SelectionMode.cs │ │ │ ├── StandardGuiFont.cs │ │ │ ├── StaticImage.cs │ │ │ ├── Tab.cs │ │ │ ├── TabPanel.cs │ │ │ └── Window.cs │ │ ├── Helpers │ │ │ ├── EagerAttachableObject.cs │ │ │ └── LazyAttachableObject.cs │ │ ├── IO │ │ │ ├── ChatBox.cs │ │ │ ├── ChatBoxEnums.cs │ │ │ ├── CommandHandler.cs │ │ │ ├── Cursor.cs │ │ │ ├── Events │ │ │ │ ├── OnCharacterEventArgs.cs │ │ │ │ ├── OnChatMessageEventArgs.cs │ │ │ │ ├── OnClickEventArgs.cs │ │ │ │ ├── OnDebugMessageEventArgs.cs │ │ │ │ ├── OnDoubleClickEventArgs.cs │ │ │ │ ├── OnKeyEventArgs.cs │ │ │ │ └── OnMoveEventArgs.cs │ │ │ ├── Input.cs │ │ │ ├── MTAConsole.cs │ │ │ └── MTADebug.cs │ │ ├── Lights │ │ │ ├── Light.cs │ │ │ ├── LightType.cs │ │ │ └── SearchLight.cs │ │ ├── Markers │ │ │ └── Marker.cs │ │ ├── Peds │ │ │ ├── Events │ │ │ │ ├── OnChokeEventArgs.cs │ │ │ │ ├── OnConsoleEventArgs.cs │ │ │ │ ├── OnDamageEventArgs.cs │ │ │ │ ├── OnHeliKilledEventArgs.cs │ │ │ │ ├── OnJoinEventArgs.cs │ │ │ │ ├── OnNicknameChangedEventArgs.cs │ │ │ │ ├── OnPickupHitEventArgs.cs │ │ │ │ ├── OnPickupLeaveEventArgs.cs │ │ │ │ ├── OnQuitEventArgs.cs │ │ │ │ ├── OnRadioSwitchEventArgs.cs │ │ │ │ ├── OnSpawnEventArgs.cs │ │ │ │ ├── OnStealthKillEventArgs.cs │ │ │ │ ├── OnStepEventArgs.cs │ │ │ │ ├── OnStuntFinishEventArgs.cs │ │ │ │ ├── OnStuntStartEventArgs.cs │ │ │ │ ├── OnTargetEventArgs.cs │ │ │ │ ├── OnVehicleEnterEventArgs.cs │ │ │ │ ├── OnVehicleExitEventArgs.cs │ │ │ │ ├── OnVoicePausedEventArgs.cs │ │ │ │ ├── OnVoiceResumedEventArgs.cs │ │ │ │ ├── OnVoiceStartEventArgs.cs │ │ │ │ ├── OnVoiceStopEventArgs.cs │ │ │ │ ├── OnWastedEventArgs.cs │ │ │ │ ├── OnWeaponFireEventArgs.cs │ │ │ │ └── OnWeaponSwitchEventArgs.cs │ │ │ ├── LocalPlayer.cs │ │ │ ├── MoveState.cs │ │ │ ├── Ped.cs │ │ │ ├── PedVoice.cs │ │ │ ├── Player.cs │ │ │ └── Tasks.cs │ │ ├── Pickups │ │ │ └── Pickup.cs │ │ ├── Radar │ │ │ ├── Blip.cs │ │ │ └── RadarArea.cs │ │ ├── Rendering │ │ │ ├── Camera.cs │ │ │ ├── CameraEnums.cs │ │ │ ├── Events │ │ │ │ ├── OnHudRenderEventArgs.cs │ │ │ │ └── OnRenderEventArgs.cs │ │ │ ├── RenderEnums.cs │ │ │ ├── RenderTarget.cs │ │ │ ├── Renderer.cs │ │ │ └── Status.cs │ │ ├── Resources │ │ │ └── Resource.cs │ │ ├── Rpc │ │ │ └── RpcManager.cs │ │ ├── SightLines │ │ │ ├── SightLine.cs │ │ │ └── SightLineData.cs │ │ ├── SlipeClient.csproj │ │ ├── Sounds │ │ │ ├── Events │ │ │ │ ├── OnBeatEventArgs.cs │ │ │ │ ├── OnDownloadFinishedEventArgs.cs │ │ │ │ ├── OnMetaChangedEventArgs.cs │ │ │ │ ├── OnStartEventArgs.cs │ │ │ │ ├── OnStopEventArgs.cs │ │ │ │ └── OnStreamEventArgs.cs │ │ │ ├── Sound.cs │ │ │ ├── SoundEffects.cs │ │ │ ├── SoundEnums.cs │ │ │ ├── SoundMeta.cs │ │ │ ├── SoundProperties.cs │ │ │ └── WorldSound.cs │ │ ├── Vehicles │ │ │ ├── BaseVehicle.cs │ │ │ ├── Boat.cs │ │ │ ├── Component.cs │ │ │ ├── ComponentEnums.cs │ │ │ ├── Events │ │ │ │ ├── OnAttachEventArgs.cs │ │ │ │ ├── OnCollisionEventArgs.cs │ │ │ │ ├── OnDamageEventArgs.cs │ │ │ │ ├── OnDetachEventArgs.cs │ │ │ │ ├── OnEnterEventArgs.cs │ │ │ │ ├── OnExitEventArgs.cs │ │ │ │ ├── OnExplodeEventArgs.cs │ │ │ │ ├── OnNitroStateChangeEventArgs.cs │ │ │ │ ├── OnPedHitEventArgs.cs │ │ │ │ ├── OnRespawnEventArgs.cs │ │ │ │ ├── OnStartEnterEventArgs.cs │ │ │ │ ├── OnStartExitEventArgs.cs │ │ │ │ └── OnWeaponHitEventArgs.cs │ │ │ ├── Helicopter.cs │ │ │ ├── Plane.cs │ │ │ ├── Taxi.cs │ │ │ ├── Trailer.cs │ │ │ ├── Train.cs │ │ │ ├── TurretedVehicle.cs │ │ │ ├── Vehicle.cs │ │ │ ├── VehicleModel.cs │ │ │ └── VehicleModelDummy.cs │ │ └── Weapons │ │ │ ├── CustomWeapon.cs │ │ │ ├── Events │ │ │ ├── OnCreatedEventArgs.cs │ │ │ └── OnFireEventArgs.cs │ │ │ ├── Projectile.cs │ │ │ └── ProjectileType.cs │ │ ├── SlipeMTADefinitions │ │ ├── MTAAccount.cs │ │ ├── MTAAcl.cs │ │ ├── MTAAclGroup.cs │ │ ├── MTABan.cs │ │ ├── MTAClient.cs │ │ ├── MTAElement.cs │ │ ├── MTAException.cs │ │ ├── MTAPasswords.cs │ │ ├── MTAResource.cs │ │ ├── MTAServer.cs │ │ ├── MTAShared.cs │ │ ├── MTATimer.cs │ │ ├── MtaExports.cs │ │ ├── MtaJson.cs │ │ └── SlipeMTADefinitions.csproj │ │ ├── SlipeServer │ │ ├── Accounts │ │ │ ├── Account.cs │ │ │ ├── AccountException.cs │ │ │ ├── Ban.cs │ │ │ └── Events │ │ │ │ ├── OnAddedEventArgs.cs │ │ │ │ ├── OnDataChangeEventArgs.cs │ │ │ │ └── OnRemovedEventArgs.cs │ │ ├── Acl │ │ │ ├── AclEntry.cs │ │ │ ├── AclFile.cs │ │ │ ├── AclGroup.cs │ │ │ ├── AclRequest.cs │ │ │ ├── AclRightEnum.cs │ │ │ └── IAclObject.cs │ │ ├── Displays │ │ │ ├── Display.cs │ │ │ ├── DisplayEnums.cs │ │ │ └── Item.cs │ │ ├── Elements │ │ │ ├── ElementExtensions.cs │ │ │ ├── ResourceRootElement.cs │ │ │ └── RootElement.cs │ │ ├── Events │ │ │ └── Event.cs │ │ ├── Explosions │ │ │ └── Explosion.cs │ │ ├── Game │ │ │ ├── Announcement.cs │ │ │ ├── BandwidthReduction.cs │ │ │ ├── Config.cs │ │ │ ├── Events │ │ │ │ ├── OnPlayerConnectEventArgs.cs │ │ │ │ ├── OnPreStartEventArgs.cs │ │ │ │ ├── OnSettingChangeEventArgs.cs │ │ │ │ ├── OnStartEventArgs.cs │ │ │ │ └── OnStopEventArgs.cs │ │ │ ├── GameServer.cs │ │ │ ├── Glitch.cs │ │ │ ├── Settings.cs │ │ │ └── Team.cs │ │ ├── GameWorld │ │ │ ├── Garage.cs │ │ │ ├── Water.cs │ │ │ ├── World.cs │ │ │ └── WorldObject.cs │ │ ├── IO │ │ │ ├── ChatBox.cs │ │ │ ├── CommandHandler.cs │ │ │ ├── Events │ │ │ │ ├── OnChatMessageEventArgs.cs │ │ │ │ └── OnDebugMessageEventArgs.cs │ │ │ ├── Input.cs │ │ │ ├── MTAConsole.cs │ │ │ ├── MTADebug.cs │ │ │ └── ServerLog.cs │ │ ├── Markers │ │ │ └── Marker.cs │ │ ├── Peds │ │ │ ├── Events │ │ │ │ ├── OnAcInfoEventArgs.cs │ │ │ │ ├── OnBanAddedEventArgs.cs │ │ │ │ ├── OnBannedEventArgs.cs │ │ │ │ ├── OnChatEventArgs.cs │ │ │ │ ├── OnClickEventArgs.cs │ │ │ │ ├── OnCommandEventArgs.cs │ │ │ │ ├── OnConsoleEventArgs.cs │ │ │ │ ├── OnContactEventArgs.cs │ │ │ │ ├── OnDamageEventArgs.cs │ │ │ │ ├── OnJoinEventArgs.cs │ │ │ │ ├── OnLoginEventArgs.cs │ │ │ │ ├── OnLogoutEventArgs.cs │ │ │ │ ├── OnMarkerHitEventArgs.cs │ │ │ │ ├── OnMarkerLeaveEventArgs.cs │ │ │ │ ├── OnModInfoEventArgs.cs │ │ │ │ ├── OnMutedEventArgs.cs │ │ │ │ ├── OnNetworkInteruptionEventArgs.cs │ │ │ │ ├── OnNicknameChangedEventArgs.cs │ │ │ │ ├── OnPickupHitEventArgs.cs │ │ │ │ ├── OnPickupLeaveEventArgs.cs │ │ │ │ ├── OnPickupUseEventArgs.cs │ │ │ │ ├── OnPrivateMessageEventArgs.cs │ │ │ │ ├── OnQuitEventArgs.cs │ │ │ │ ├── OnScreenShotEventArgs.cs │ │ │ │ ├── OnSpawnEventArgs.cs │ │ │ │ ├── OnStealthKillEventArgs.cs │ │ │ │ ├── OnTargetEventArgs.cs │ │ │ │ ├── OnUnmutedEventArgs.cs │ │ │ │ ├── OnVehicleEnterEventArgs.cs │ │ │ │ ├── OnVehicleExitEventArgs.cs │ │ │ │ ├── OnVoiceStartEventArgs.cs │ │ │ │ ├── OnVoiceStopEventArgs.cs │ │ │ │ ├── OnWastedEventArgs.cs │ │ │ │ ├── OnWeaponFireEventArgs.cs │ │ │ │ └── OnWeaponSwitchEventArgs.cs │ │ │ ├── Ped.cs │ │ │ └── Player.cs │ │ ├── Pickups │ │ │ ├── Events │ │ │ │ ├── OnSpawnEventArgs.cs │ │ │ │ └── OnUseEventArgs.cs │ │ │ └── Pickup.cs │ │ ├── Radar │ │ │ ├── Blip.cs │ │ │ └── RadarArea.cs │ │ ├── Rendering │ │ │ └── Camera.cs │ │ ├── Resources │ │ │ └── Resource.cs │ │ ├── Rpc │ │ │ └── RpcManager.cs │ │ ├── SlipeServer.csproj │ │ ├── Vehicles │ │ │ ├── BaseVehicle.cs │ │ │ ├── Boat.cs │ │ │ ├── Events │ │ │ │ ├── OnAttachEventArgs.cs │ │ │ │ ├── OnDamageEventArgs.cs │ │ │ │ ├── OnDetachEventArgs.cs │ │ │ │ ├── OnEnterEventArgs.cs │ │ │ │ ├── OnExitEventArgs.cs │ │ │ │ ├── OnExplodeEventArgs.cs │ │ │ │ ├── OnRespawnEventArgs.cs │ │ │ │ ├── OnStartEnterEventArgs.cs │ │ │ │ └── OnStartExitEventArgs.cs │ │ │ ├── Helicopter.cs │ │ │ ├── ModelHandling.cs │ │ │ ├── Plane.cs │ │ │ ├── Sirens.cs │ │ │ ├── Taxi.cs │ │ │ ├── Trailer.cs │ │ │ ├── Train.cs │ │ │ ├── TurretedVehicle.cs │ │ │ ├── Vehicle.cs │ │ │ └── VehicleModel.cs │ │ └── Weapons │ │ │ └── WeaponModel.cs │ │ ├── SlipeShared │ │ ├── CollisionShapes │ │ │ ├── CollisionCircle.cs │ │ │ ├── CollisionCuboid.cs │ │ │ ├── CollisionRectangle.cs │ │ │ ├── CollisionShape.cs │ │ │ ├── CollisionSphere.cs │ │ │ ├── CollisionTube.cs │ │ │ └── Events │ │ │ │ ├── OnHitEventArgs.cs │ │ │ │ └── OnLeaveEventArgs.cs │ │ ├── Cryptography │ │ │ ├── Base64.cs │ │ │ ├── Bcrypt.cs │ │ │ ├── Md5.cs │ │ │ ├── Sha1.cs │ │ │ ├── Sha224.cs │ │ │ ├── Sha256.cs │ │ │ ├── Sha384.cs │ │ │ ├── Sha512.cs │ │ │ └── Tea.cs │ │ ├── Elements │ │ │ ├── DefaultElementClassAttribute.cs │ │ │ ├── Element.cs │ │ │ ├── ElementManager.cs │ │ │ ├── ElementType.cs │ │ │ ├── Events │ │ │ │ ├── OnClickedEventArgs.cs │ │ │ │ ├── OnCollisionShapeHitEventArgs.cs │ │ │ │ ├── OnCollisionShapeLeaveEventArgs.cs │ │ │ │ ├── OnDestroyEventArgs.cs │ │ │ │ ├── OnModelChangeEventArgs.cs │ │ │ │ ├── OnStartSyncEventArgs.cs │ │ │ │ ├── OnStopSyncEventArgs.cs │ │ │ │ ├── OnStreamInEventArgs.cs │ │ │ │ └── OnStreamOutEventArgs.cs │ │ │ └── PhysicalElement.cs │ │ ├── Exceptions │ │ │ └── NullElementException.cs │ │ ├── Explosions │ │ │ └── ExplosionType.cs │ │ ├── Exports │ │ │ └── ExportAttribute.cs │ │ ├── GameWorld │ │ │ ├── GameTime.cs │ │ │ ├── GarageLocation.cs │ │ │ ├── HeatHaze.cs │ │ │ ├── SharedGarage.cs │ │ │ ├── SharedWater.cs │ │ │ ├── SharedWorld.cs │ │ │ ├── SharedWorldObject.cs │ │ │ ├── TrafficLightState.cs │ │ │ ├── Weather.cs │ │ │ └── WeatherType.cs │ │ ├── Helpers │ │ │ ├── EasingFunction.cs │ │ │ ├── NumericHelper.cs │ │ │ ├── StatusCode.cs │ │ │ └── Version.cs │ │ ├── IO │ │ │ ├── DebugMessageLevel.cs │ │ │ ├── KeyEnum.cs │ │ │ ├── MessageType.cs │ │ │ ├── MouseEnum.cs │ │ │ └── SharedMTADebug.cs │ │ ├── Markers │ │ │ ├── Events │ │ │ │ ├── OnHitEventArgs.cs │ │ │ │ └── OnLeaveEventArgs.cs │ │ │ ├── MarkerIcon.cs │ │ │ ├── MarkerType.cs │ │ │ └── SharedMarker.cs │ │ ├── Peds │ │ │ ├── AnalogControl.cs │ │ │ ├── Animation.cs │ │ │ ├── BodyPart.cs │ │ │ ├── Bone.cs │ │ │ ├── DamageType.cs │ │ │ ├── FightingStyle.cs │ │ │ ├── FrontEndSound.cs │ │ │ ├── HudComponent.cs │ │ │ ├── PedClothes.cs │ │ │ ├── PedModel.cs │ │ │ ├── PedStat.cs │ │ │ ├── QuitType.cs │ │ │ ├── SharedPed.cs │ │ │ └── WalkingStyle.cs │ │ ├── Pickups │ │ │ ├── Events │ │ │ │ ├── OnHitArgs.cs │ │ │ │ └── OnLeaveArgs.cs │ │ │ ├── PickupModel.cs │ │ │ ├── PickupType.cs │ │ │ └── SharedPickup.cs │ │ ├── RPC │ │ │ ├── AsyncRpc.cs │ │ │ ├── BaseRPC.cs │ │ │ ├── ElementRpc.cs │ │ │ ├── EmptyRpc.cs │ │ │ ├── IRPC.cs │ │ │ └── SingleCastRpc.cs │ │ ├── Radar │ │ │ ├── BlipType.cs │ │ │ ├── SharedBlip.cs │ │ │ └── SharedRadarArea.cs │ │ ├── Rendering │ │ │ └── CameraFade.cs │ │ ├── Resources │ │ │ └── SharedResource.cs │ │ ├── Rpc │ │ │ └── RpcEnums.cs │ │ ├── SlipeShared.csproj │ │ ├── Utilities │ │ │ └── Color.cs │ │ ├── Vehicles │ │ │ ├── Handling.cs │ │ │ ├── HandlingEnums.cs │ │ │ ├── SharedSirens.cs │ │ │ ├── SharedVehicle.cs │ │ │ ├── SharedVehicleModel.cs │ │ │ ├── Siren.cs │ │ │ └── VehicleEnums.cs │ │ ├── Weapons │ │ │ ├── SharedWeaponModel.cs │ │ │ └── WeaponEnums.cs │ │ └── doc.xml │ │ └── SlipeSql │ │ ├── Database.cs │ │ ├── MySqlConnectionString.cs │ │ ├── SlipeSql.csproj │ │ ├── SqlOptions.cs │ │ └── SqlValue.cs └── Lua │ └── Main │ └── main.lua ├── Source ├── ClientSide │ ├── ClientSide.csproj │ ├── Program.cs │ └── Properties │ │ └── launchSettings.json └── ServerSide │ ├── ExampleManager.cs │ ├── Program.cs │ ├── Properties │ └── launchSettings.json │ └── ServerSide.csproj ├── azure-pipelines.yml └── test.xml /.gitignore: -------------------------------------------------------------------------------- 1 | Dist/ 2 | Slipe/Build/ 3 | Build/ 4 | InternalModules/ 5 | ExportedModules/ 6 | BuildOutput/ 7 | meta.xml 8 | 9 | DocFX/api 10 | DocFX/log.txt 11 | 12 | 13 | .vs/ 14 | [Dd]ebug/ 15 | [Dd]ebugPublic/ 16 | [Rr]elease/ 17 | [Rr]eleases/ 18 | x64/ 19 | x86/ 20 | [Aa][Rr][Mm]/ 21 | [Aa][Rr][Mm]64/ 22 | bld/ 23 | [Bb]in/ 24 | [Oo]bj/ 25 | [Ll]og/ 26 | 27 | # The lines below are only meant to be here for the slipe core project 28 | Slipe/Core/Lua/Compiled/ 29 | Slipe/Core/DLL 30 | 31 | 32 | # NuGet Packages 33 | *.nupkg 34 | # The packages folder can be ignored because of Package Restore 35 | **/[Pp]ackages/* 36 | # except build/, which is used as an MSBuild target. 37 | !**/[Pp]ackages/build/ 38 | # Uncomment if necessary however generally it will be regenerated when needed 39 | #!**/[Pp]ackages/repositories.config 40 | # NuGet v3's project.json files produces more ignorable files 41 | *.nuget.props 42 | *.nuget.targets -------------------------------------------------------------------------------- /Assets/m4.dff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Assets/m4.dff -------------------------------------------------------------------------------- /Assets/m4.txd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Assets/m4.txd -------------------------------------------------------------------------------- /DocFX/.gitignore: -------------------------------------------------------------------------------- 1 | ############### 2 | # folder # 3 | ############### 4 | /**/DROP/ 5 | /**/TEMP/ 6 | /**/packages/ 7 | /**/bin/ 8 | /**/obj/ 9 | _site 10 | -------------------------------------------------------------------------------- /DocFX/DocFX.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | netcoreapp3.1 5 | 6 | 7 | 8 | 9 | all 10 | runtime; build; native; contentfiles; analyzers; buildtransitive 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/ManagedReference.extension.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | 3 | /** 4 | * This method will be called at the start of exports.transform in ManagedReference.html.primary.js 5 | */ 6 | exports.preTransform = function (model) { 7 | return model; 8 | } 9 | 10 | /** 11 | * This method will be called at the end of exports.transform in ManagedReference.html.primary.js 12 | */ 13 | exports.postTransform = function (model) { 14 | return model; 15 | } -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/ManagedReference.html.primary.tmpl: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | {{!master(layout/_master.tmpl)}} 3 | 4 | {{#isNamespace}} 5 | {{>partials/namespace}} 6 | {{/isNamespace}} 7 | {{#isClass}} 8 | {{>partials/class}} 9 | {{/isClass}} 10 | {{#isEnum}} 11 | {{>partials/enum}} 12 | {{/isEnum}} 13 | {{>partials/customMREFContent}} -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/RestApi.extension.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | 3 | /** 4 | * This method will be called at the start of exports.transform in RestApi.html.primary.js 5 | */ 6 | exports.preTransform = function (model) { 7 | return model; 8 | } 9 | 10 | /** 11 | * This method will be called at the end of exports.transform in RestApi.html.primary.js 12 | */ 13 | exports.postTransform = function (model) { 14 | return model; 15 | } -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/RestApi.html.primary.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | 3 | var restApiCommon = require('./RestApi.common.js'); 4 | var extension = require('./RestApi.extension.js') 5 | 6 | exports.transform = function (model) { 7 | if (extension && extension.preTransform) { 8 | model = extension.preTransform(model); 9 | } 10 | 11 | if (restApiCommon && restApiCommon.transform) { 12 | model = restApiCommon.transform(model); 13 | } 14 | model._disableToc = model._disableToc || !model._tocPath || (model._navPath === model._tocPath); 15 | 16 | if (extension && extension.postTransform) { 17 | model = extension.postTransform(model); 18 | } 19 | 20 | return model; 21 | } 22 | 23 | exports.getOptions = function (model) { 24 | return { "bookmarks": restApiCommon.getBookmarks(model) }; 25 | } -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/RestApi.html.primary.tmpl: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | {{!master(layout/_master.tmpl)}} 3 | {{>partials/rest}} -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/UniversalReference.extension.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | 3 | /** 4 | * This method will be called at the start of exports.transform in UniversalReference.html.primary.js 5 | */ 6 | exports.preTransform = function (model) { 7 | return model; 8 | } 9 | 10 | /** 11 | * This method will be called at the end of exports.transform in UniversalReference.html.primary.js 12 | */ 13 | exports.postTransform = function (model) { 14 | return model; 15 | } -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/UniversalReference.html.primary.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | 3 | var urefCommon = require('./UniversalReference.common.js'); 4 | var extension = require('./UniversalReference.extension.js'); 5 | 6 | exports.transform = function (model) { 7 | if (extension && extension.preTransform) { 8 | model = extension.preTransform(model); 9 | } 10 | 11 | if (urefCommon && urefCommon.transform) { 12 | model = urefCommon.transform(model); 13 | } 14 | 15 | model._disableToc = model._disableToc || !model._tocPath || (model._navPath === model._tocPath); 16 | 17 | if (extension && extension.postTransform) { 18 | model = extension.postTransform(model); 19 | } 20 | 21 | return model; 22 | } 23 | 24 | exports.getOptions = function (model) { 25 | return { 26 | "bookmarks": urefCommon.getBookmarks(model) 27 | }; 28 | } -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/UniversalReference.html.primary.tmpl: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | {{!master(layout/_master.tmpl)}} 3 | 4 | {{#isNamespace}} 5 | {{>partials/namespace}} 6 | {{/isNamespace}} 7 | {{#isClass}} 8 | {{>partials/uref/class}} 9 | {{/isClass}} 10 | {{#isEnum}} 11 | {{>partials/enum}} 12 | {{/isEnum}} 13 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/conceptual.extension.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | 3 | /** 4 | * This method will be called at the start of exports.transform in conceptual.html.primary.js 5 | */ 6 | exports.preTransform = function (model) { 7 | return model; 8 | } 9 | 10 | /** 11 | * This method will be called at the end of exports.transform in conceptual.html.primary.js 12 | */ 13 | exports.postTransform = function (model) { 14 | return model; 15 | } -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/conceptual.html.primary.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | 3 | var common = require('./common.js'); 4 | var extension = require('./conceptual.extension.js') 5 | 6 | exports.transform = function (model) { 7 | if (extension && extension.preTransform) { 8 | model = extension.preTransform(model); 9 | } 10 | 11 | model._disableToc = model._disableToc || !model._tocPath || (model._navPath === model._tocPath); 12 | model.docurl = model.docurl || common.getImproveTheDocHref(model, model._gitContribute, model._gitUrlPattern); 13 | 14 | if (extension && extension.postTransform) { 15 | model = extension.postTransform(model); 16 | } 17 | 18 | return model; 19 | } -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/conceptual.html.primary.tmpl: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | {{!master(layout/_master.tmpl)}} 3 | {{{rawTitle}}} 4 | {{{conceptual}}} -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/_exported_templates/default/favicon.ico -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/_exported_templates/default/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/_exported_templates/default/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/_exported_templates/default/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/_exported_templates/default/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/_breadcrumb.liquid: -------------------------------------------------------------------------------- 1 | {% comment -%}Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.{% endcomment -%} 2 | 9 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/_footer.liquid: -------------------------------------------------------------------------------- 1 | {% comment -%}Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.{% endcomment -%} 2 | 17 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/_logo.liquid: -------------------------------------------------------------------------------- 1 | {% comment -%}Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.{% endcomment -%} 2 | 3 | {%- if _appLogoPath -%} 4 | 5 | {%- else -%} 6 | 7 | {%- endif -%} 8 | 9 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/_scripts.liquid: -------------------------------------------------------------------------------- 1 | {% comment -%}Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.{% endcomment -%} 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/_toc.liquid: -------------------------------------------------------------------------------- 1 | {% comment -%}Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.{% endcomment -%} 2 | 8 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/affix.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 | 26 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/breadcrumb.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 | 10 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/classSubtitle.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | {{#inConstructor}} 3 | {{__global.constructorsInSubtitle}} 4 | {{/inConstructor}} 5 | {{#inField}} 6 | {{__global.fieldsInSubtitle}} 7 | {{/inField}} 8 | {{#inProperty}} 9 | {{__global.propertiesInSubtitle}} 10 | {{/inProperty}} 11 | {{#inMethod}} 12 | {{__global.methodsInSubtitle}} 13 | {{/inMethod}} 14 | {{#inEvent}} 15 | {{__global.eventsInSubtitle}} 16 | {{/inEvent}} 17 | {{#inOperator}} 18 | {{__global.operatorsInSubtitle}} 19 | {{/inOperator}} 20 | {{#inEii}} 21 | {{__global.eiisInSubtitle}} 22 | {{/inEii}} 23 | {{#inFunction}} 24 | {{__global.functionsInSubtitle}} 25 | {{/inFunction}} 26 | {{#inMember}} 27 | {{__global.membersInSubtitle}} 28 | {{/inMember}} -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/customMREFContent.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | {{!Add your own custom template for the content for ManagedReference here}} -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/dd-li.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{#items}} 2 |
  • {{name}}
  • 3 | {{/items}} 4 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/footer.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 | 15 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/logo.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/namespace.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 |

    {{>partials/title}}

    4 |
    {{{summary}}}
    5 |
    {{{conceptual}}}
    6 |
    {{{remarks}}}
    7 | {{#children}} 8 |

    {{>partials/namespaceSubtitle}}

    9 | {{#children}} 10 |

    11 |
    {{{summary}}}
    12 | {{/children}} 13 | {{/children}} 14 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/namespaceSubtitle.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | {{#inClass}} 3 | {{__global.classesInSubtitle}} 4 | {{/inClass}} 5 | {{#inStruct}} 6 | {{__global.structsInSubtitle}} 7 | {{/inStruct}} 8 | {{#inInterface}} 9 | {{__global.interfacesInSubtitle}} 10 | {{/inInterface}} 11 | {{#inEnum}} 12 | {{__global.enumsInSubtitle}} 13 | {{/inEnum}} 14 | {{#inDelegate}} 15 | {{__global.delegatesInSubtitle}} 16 | {{/inDelegate}} -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/scripts.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/searchResults.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 |
    4 |
    5 |
    6 |

    7 |
    8 | 9 |
    10 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/toc.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 | 9 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/partials/uref/parameters.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 | {{#properties.0}} 4 |
    Properties
    5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | {{/properties.0}} 15 | {{#properties}} 16 | 17 | 18 | 19 | 23 | 24 | {{/properties}} 25 | {{#properties.0}} 26 | 27 |
    {{__global.type}}{{__global.name}}{{__global.description}}
    {{{type.specName.0.value}}}{{{id}}} 20 | {{{description}}} 21 | {{>partials/parameters}} 22 |
    28 | {{/properties.0}} -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/styles/main.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/_exported_templates/default/styles/main.css -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/styles/main.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/toc.extension.js: -------------------------------------------------------------------------------- 1 | // Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information. 2 | 3 | /** 4 | * This method will be called at the start of exports.transform in toc.html.js 5 | */ 6 | exports.preTransform = function (model) { 7 | return model; 8 | } 9 | 10 | /** 11 | * This method will be called at the end of exports.transform in toc.html.js 12 | */ 13 | exports.postTransform = function (model) { 14 | return model; 15 | } -------------------------------------------------------------------------------- /DocFX/_exported_templates/default/toc.html.tmpl: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 |
    4 |
    5 | {{^_disableSideFilter}} 6 |
    7 |
    8 | 9 | 10 |
    11 |
    12 | {{/_disableSideFilter}} 13 |
    14 |
    15 | {{^leaf}} 16 | {{>partials/li}} 17 | {{/leaf}} 18 |
    19 |
    20 |
    21 |
    -------------------------------------------------------------------------------- /DocFX/docs/toc.yml: -------------------------------------------------------------------------------- 1 | - name: Getting started 2 | items: 3 | - name: Installation 4 | href: installation.md 5 | - name: Creating your first resource 6 | href: firstResource.md 7 | - name: Slipe CLI 8 | href: cli.md 9 | - name: Visual Studio 10 | href: visualStudio.md 11 | - name: Webhook 12 | href: webhook.md 13 | - name: Features 14 | items: 15 | - name: Libraries 16 | href: libraries.md 17 | - name: Utilities 18 | href: utilities.md 19 | - name: SQL 20 | href: sql.md 21 | - name: Remote procedure calls 22 | href: rpc.md 23 | - name: Inheritance 24 | href: inheritance.md 25 | - name: Snippets 26 | href: snippets.md 27 | - name: Exports 28 | href: exporting.md 29 | - name: Modules 30 | href: modules.md 31 | - name: Roadmap 32 | href: roadmap.md -------------------------------------------------------------------------------- /DocFX/images/logo_large.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/images/logo_large.png -------------------------------------------------------------------------------- /DocFX/images/visualStudio/addReference.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/images/visualStudio/addReference.png -------------------------------------------------------------------------------- /DocFX/images/visualStudio/buildContext.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/images/visualStudio/buildContext.png -------------------------------------------------------------------------------- /DocFX/images/visualStudio/buildMenu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/images/visualStudio/buildMenu.png -------------------------------------------------------------------------------- /DocFX/images/visualStudio/debug.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/images/visualStudio/debug.png -------------------------------------------------------------------------------- /DocFX/images/visualStudio/referenceManager.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/images/visualStudio/referenceManager.png -------------------------------------------------------------------------------- /DocFX/images/visualStudio/solutionExplorer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/images/visualStudio/solutionExplorer.png -------------------------------------------------------------------------------- /DocFX/images/visualStudio/solutionLibrary.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/images/visualStudio/solutionLibrary.png -------------------------------------------------------------------------------- /DocFX/template/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/template/favicon.ico -------------------------------------------------------------------------------- /DocFX/template/index.html.tmpl: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | {{!include(/^styles/.*/)}} 3 | {{!include(/^fonts/.*/)}} 4 | {{!include(favicon.ico)}} 5 | {{!include(logo.svg)}} 6 | 7 | 8 | 9 | {{>partials/head}} 10 | 11 |
    12 |
    13 | {{>partials/navbar}} 14 |
    15 | {{{conceptual}}} 16 | {{>partials/footer}} 17 |
    18 | {{>partials/scripts}} 19 | 20 | -------------------------------------------------------------------------------- /DocFX/template/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/DocFX/template/logo.png -------------------------------------------------------------------------------- /DocFX/template/partials/_logo.liquid: -------------------------------------------------------------------------------- 1 | {% comment -%}Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.{% endcomment -%} 2 | 3 | {%- if _appLogoPath -%} 4 | 5 | {%- else -%} 6 | 7 | {%- endif -%} 8 | 9 | -------------------------------------------------------------------------------- /DocFX/template/partials/logo.tmpl.partial: -------------------------------------------------------------------------------- 1 | {{!Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. See LICENSE file in the project root for full license information.}} 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /DocFX/toc.yml: -------------------------------------------------------------------------------- 1 | - name: Docs 2 | href: docs/ 3 | - name: Shared Library 4 | href: api/shared/ 5 | - name: Client Library 6 | href: api/client/ 7 | - name: Server Library 8 | href: api/server/ -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | Copyright 2019 Bob van Hooff & Mathijs Sonnemans 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. -------------------------------------------------------------------------------- /Slipe/Compiler/CSharp.lua.Launcher.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/CSharp.lua.Launcher.dll -------------------------------------------------------------------------------- /Slipe/Compiler/CSharp.lua.Launcher.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/CSharp.lua.Launcher.pdb -------------------------------------------------------------------------------- /Slipe/Compiler/CSharp.lua.Launcher.runtimeconfig.dev.json: -------------------------------------------------------------------------------- 1 | { 2 | "runtimeOptions": { 3 | "additionalProbingPaths": [ 4 | "C:\\Users\\Bob-laptop\\.dotnet\\store\\|arch|\\|tfm|", 5 | "C:\\Users\\Bob-laptop\\.nuget\\packages", 6 | "C:\\Program Files\\dotnet\\sdk\\NuGetFallbackFolder" 7 | ] 8 | } 9 | } -------------------------------------------------------------------------------- /Slipe/Compiler/CSharp.lua.Launcher.runtimeconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "runtimeOptions": { 3 | "tfm": "netcoreapp3.1", 4 | "framework": { 5 | "name": "Microsoft.NETCore.App", 6 | "version": "3.1.0" 7 | } 8 | } 9 | } -------------------------------------------------------------------------------- /Slipe/Compiler/CSharp.lua.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/CSharp.lua.dll -------------------------------------------------------------------------------- /Slipe/Compiler/CSharp.lua.pdb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/CSharp.lua.pdb -------------------------------------------------------------------------------- /Slipe/Compiler/Microsoft.CodeAnalysis.CSharp.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/Microsoft.CodeAnalysis.CSharp.dll -------------------------------------------------------------------------------- /Slipe/Compiler/Microsoft.CodeAnalysis.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/Microsoft.CodeAnalysis.dll -------------------------------------------------------------------------------- /Slipe/Compiler/runtimes/unix/lib/netstandard1.3/System.Text.Encoding.CodePages.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/runtimes/unix/lib/netstandard1.3/System.Text.Encoding.CodePages.dll -------------------------------------------------------------------------------- /Slipe/Compiler/runtimes/win/lib/netcoreapp2.0/System.Text.Encoding.CodePages.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/runtimes/win/lib/netcoreapp2.0/System.Text.Encoding.CodePages.dll -------------------------------------------------------------------------------- /Slipe/Compiler/runtimes/win/lib/netstandard1.3/System.Text.Encoding.CodePages.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mta-slipe/Slipe-Core/f317338221f501e2fe6cdc1e93949d3811f664f2/Slipe/Compiler/runtimes/win/lib/netstandard1.3/System.Text.Encoding.CodePages.dll -------------------------------------------------------------------------------- /Slipe/Core/Lua/Backing/SlipeMTADfinitions/exports.lua: -------------------------------------------------------------------------------- 1 | local System = System 2 | 3 | local Export = {} 4 | 5 | Export.Invoke = function (resource, func, ...) 6 | local export = exports[resource] 7 | 8 | local varargs = {...} 9 | if (#varargs == 1 and System.is(varargs[1], ArrayObject) ) then 10 | iprint(varargs) 11 | return export[func](export, unpack(varargs[1])) 12 | end 13 | 14 | return export[func](export, ...) 15 | end 16 | 17 | System.define("Slipe.Exports.Export", Export) -------------------------------------------------------------------------------- /Slipe/Core/Lua/Backing/SlipeSql/SqlValue.lua: -------------------------------------------------------------------------------- 1 | local System = System 2 | local SqlValue = {} 3 | 4 | SqlValue.__ctor__ = function(this, value) 5 | this.value = value 6 | end 7 | 8 | SqlValue.op_Implicit = function (this, value) 9 | return System.cast(System.String, this.value) 10 | end 11 | SqlValue.op_Implicit1 = function (this, value) 12 | return System.cast(System.Int32, this.value) 13 | end 14 | SqlValue.op_Implicit2 = function (this, value) 15 | return System.cast(System.Single, this.value) 16 | end 17 | 18 | System.define("Slipe.Sql.SqlValue", SqlValue) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/ArraySegment.lua: -------------------------------------------------------------------------------- 1 | local ArraySegment = {} 2 | 3 | ArraySegment.__ctor__ = function(this, array) 4 | this.array = array 5 | end 6 | 7 | ArraySegment.get = function(this, i) 8 | return this.array[i] 9 | end 10 | 11 | ArraySegment.set = function(this, i, value) 12 | this.array[i] = value 13 | end 14 | 15 | ArraySegment.op_Implicit = function(array) 16 | return ArraySegment(array) 17 | end 18 | 19 | ArraySegment.getLength = function(this) 20 | return this.array:getLength() 21 | end 22 | 23 | System.defStc("System.ArraySegment", ArraySegment) 24 | System.defStc("System.ArraySegment_1", ArraySegment) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Globalization/Globalization.lua: -------------------------------------------------------------------------------- 1 | local System = System 2 | local emptyFn = System.emptyFn 3 | local define = System.define 4 | 5 | define("System.Globalization.NumberFormatInfo", { 6 | getInvariantInfo = emptyFn, 7 | getCurrentInfo = emptyFn, 8 | }) 9 | 10 | define("System.Globalization.CultureInfo", { 11 | getInvariantCulture = emptyFn, 12 | }) 13 | 14 | define("System.Globalization.DateTimeFormatInfo", { 15 | getInvariantInfo = emptyFn, 16 | }) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Net/EndPoint.lua: -------------------------------------------------------------------------------- 1 | local EndPoint = {} 2 | 3 | EndPoint.__ctor__ = function (this, ip, port) 4 | this.ip = ip 5 | this.port = port 6 | end 7 | 8 | System.define("System.Net.EndPoint", EndPoint) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Net/Http/FormUrlEncodedContent.lua: -------------------------------------------------------------------------------- 1 | 2 | 3 | local FormUrlEncodedContent = {} 4 | 5 | FormUrlEncodedContent.__ctor__ = function(this, kvPairList) 6 | this.kvPairs = kvPairList 7 | 8 | end 9 | 10 | FormUrlEncodedContent.ToString = function(this) 11 | local returnValue = "" 12 | 13 | for _, kvPair in System.each(this.kvPairs) do 14 | returnValue = returnValue .. kvPair.Key .. "=" .. kvPair.Value .. "&" 15 | end 16 | 17 | return returnValue 18 | end 19 | 20 | FormUrlEncodedContent.getFormFields = function(this) 21 | local returnValue = {} 22 | 23 | for _, kvPair in System.each(this.kvPairs) do 24 | returnValue[kvPair.Key] = kvPair.Value 25 | end 26 | 27 | return returnValue 28 | end 29 | 30 | System.define("System.Net.Http.FormUrlEncodedContent", FormUrlEncodedContent) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Net/Http/HttpContent.lua: -------------------------------------------------------------------------------- 1 | 2 | 3 | local HttpContent = {} 4 | 5 | HttpContent.ReadAsStringAsync = function(this) 6 | return Task.Instant(this.stringValue) 7 | end 8 | 9 | HttpContent.ToString = function(this) 10 | return this.stringValue 11 | end 12 | 13 | System.define("System.Net.Http.HttpContent", HttpContent) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Net/Http/StringContent.lua: -------------------------------------------------------------------------------- 1 | 2 | 3 | local StringContent = {} 4 | 5 | StringContent.__ctor__ = function(this, value) 6 | this.stringvalue = value 7 | end 8 | 9 | System.define("System.Net.Http.StringContent", StringContent) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Net/IPAddress.lua: -------------------------------------------------------------------------------- 1 | local IPAddress = {} 2 | 3 | IPAddress.__ctor__ = function (this, address) 4 | if type(address) == "table" then 5 | 6 | else 7 | this.ip = address 8 | end 9 | end 10 | 11 | IPAddress.Parse = function (ipString) 12 | return IPAddress(ipString) 13 | end 14 | 15 | IPAddress.TryParse = function (ipString) 16 | return true, IPAddress(ipString) 17 | end 18 | 19 | IPAddress.ToString = function (this) 20 | return this.ip 21 | end 22 | 23 | System.define("System.Net.IPAddress", IPAddress) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Numerics/HashCodeHelper.lua: -------------------------------------------------------------------------------- 1 | local System = System 2 | local bitLShift = bitLShift 3 | local bitNot = bitNot 4 | 5 | local HashCodeHelper = {} 6 | 7 | function HashCodeHelper.CombineHashCodes(h1, h2) 8 | return (bitLShift(h1, 5) + h1) * bitNot(h2) 9 | end 10 | 11 | System.define("System.Numerics.HashCodeHelper", HashCodeHelper) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/SystemExtensions.lua: -------------------------------------------------------------------------------- 1 | local System = System 2 | 3 | local Empty, EventArgs, static 4 | 5 | static = function (this) 6 | Empty = EventArgs() 7 | this.Empty = Empty 8 | end 9 | 10 | EventArgs = { 11 | static = static, 12 | __metadata__ = function (out) 13 | return { 14 | fields = { 15 | { "Empty", 0xE, EventArgs } 16 | } 17 | } 18 | end 19 | } 20 | 21 | System.define("System.EventArgs", EventArgs) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Text/Encoding.lua: -------------------------------------------------------------------------------- 1 | local Encoding = {} 2 | 3 | Encoding.__ctor__ = function (this, type) 4 | this.type = type 5 | end 6 | 7 | Encoding.getASCII = function(this) 8 | if Encoding.ascii == nil then 9 | Encoding.ascii = Encoding("ascii") 10 | end 11 | return Encoding.ascii 12 | end 13 | 14 | Encoding.GetString = function(this, bytes, start, count) 15 | local value = "" 16 | start = start or 0 17 | count = count or (bytes:getLength() - start) - 1 18 | for i = start, start + count do 19 | value = value .. string.char(bytes:get(i)) 20 | end 21 | return value 22 | end 23 | 24 | Encoding.GetBytes = function(this, value) 25 | local list = System.Array(System.Byte):new(value:len()) 26 | for i = 1, value:len() do 27 | list:set(i - 1, value:byte(i)) 28 | end 29 | return list 30 | end 31 | 32 | System.define("System.Text.Encoding", Encoding) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Timers/ElapsedEventArgs.lua: -------------------------------------------------------------------------------- 1 | local System = System 2 | local SystemComponentModel = System.ComponentModel 3 | local System_Timers = System.Timers 4 | local getRealTime = getRealTime 5 | 6 | local getSignalTime, __ctor__ 7 | 8 | __ctor__ = function (this, low, high) 9 | System.base(this).__ctor__(this) 10 | --local fileTime = System.toInt64(bitOr(bitLShift(high, 32), bitAnd(low, 0xffffffff))) 11 | local res = getRealTime() 12 | this.signalTime = System.DateTime(res.year + 1900, res.month + 1, res.monthday, res.hour, res.minute, res.second)--System.DateTime.FromFileTime(fileTime) 13 | end 14 | 15 | getSignalTime = function (this) 16 | return this.signalTime 17 | end 18 | 19 | System.define("System.Timers.ElapsedEventArgs", { 20 | __inherits__ = function (out) 21 | return { 22 | System.EventArgs 23 | } 24 | end, 25 | signalTime = System.default(System.DateTime), 26 | getSignalTime = getSignalTime, 27 | __ctor__ = __ctor__ 28 | }) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Xml/XmlAttribute.lua: -------------------------------------------------------------------------------- 1 | local XmlAttribute = {} 2 | 3 | XmlAttribute.__inherits__ = { System.Xml.XmlNode } 4 | 5 | XmlAttribute.__ctor__ = function(this, prefix, name, nameSpace, document) 6 | this.owner = document 7 | this.children = {} 8 | this.attributes = System.Xml.XmlAttributeCollection() 9 | if prefix == "" or prefix == nil then 10 | this.name = name 11 | else 12 | this.name = prefix .. ":" .. name 13 | end 14 | this.namespaceURI = namespace 15 | end 16 | 17 | System.define("System.Xml.XmlAttribute", XmlAttribute) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Xml/XmlAttributeCollection.lua: -------------------------------------------------------------------------------- 1 | local XmlAttributeCollection = {} 2 | 3 | 4 | XmlAttributeCollection.__ctor__ = function(this) 5 | this.values = {} 6 | end 7 | 8 | XmlAttributeCollection.get = function(this, key) 9 | return this.values[key] 10 | end 11 | 12 | XmlAttributeCollection.set = function(this, key, value) 13 | this.values[key] = value 14 | end 15 | 16 | XmlAttributeCollection.GetEnumerator = function(this) 17 | local valueTable = {} 18 | for key, value in pairs(this.values) do 19 | valueTable[#valueTable + 1] = value 20 | end 21 | return System.Array.GetEnumerator(valueTable, System.Xml.XmlAttribute) 22 | end 23 | 24 | System.define("System.Xml.XmlAttributeCollection", XmlAttributeCollection) -------------------------------------------------------------------------------- /Slipe/Core/Lua/SystemComponents/Xml/XmlNodeList.lua: -------------------------------------------------------------------------------- 1 | local XmlNodeList = {} 2 | 3 | 4 | XmlNodeList.__ctor__ = function(this) 5 | this.values = {} 6 | end 7 | 8 | XmlNodeList.get = function(this, key) 9 | return this.values[key] 10 | end 11 | 12 | XmlNodeList.getCount = function(this) 13 | return #this.values 14 | end 15 | 16 | XmlNodeList.Item = function(this, index) 17 | return this.values[key] 18 | end 19 | 20 | XmlNodeList.GetEnumerator = function(this) 21 | return System.Array.GetEnumerator(this.values, System.Xml.XmlNode) 22 | end 23 | 24 | System.define("System.Xml.XmlNodeList", XmlNodeList) -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Assets/DownloadState.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Assets 6 | { 7 | /// 8 | /// Indicates the download state of an asset file 9 | /// 10 | public enum DownloadState 11 | { 12 | Default, 13 | Downloading, 14 | Downloaded, 15 | Failed 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Assets/IFP.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.Assets 7 | { 8 | public class Ifp : Asset 9 | { 10 | private MtaElement ifp; 11 | 12 | public Ifp(string filepath): base(filepath) 13 | { 14 | 15 | } 16 | 17 | /// 18 | /// Loads the IFP file into the animation block 19 | /// 20 | /// 21 | public void Load(string customBlockName) 22 | { 23 | this.ifp = MtaClient.EngineLoadIFP(this.filepath, customBlockName); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/BlockReason.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers 6 | { 7 | /// 8 | /// The reason why the resource was blocked 9 | /// 10 | public enum BlockReason 11 | { 12 | NotAllowedYet, 13 | Blacklisted, 14 | BlockedProtocolScheme 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnCreatedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnCreatedEventArgs 8 | { 9 | internal OnCreatedEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnCursorChangeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnCursorChangeEventArgs 8 | { 9 | /// 10 | /// Cursor ID, check https://wiki.multitheftauto.com/wiki/OnClientBrowserCursorChange 11 | /// 12 | public int CursorId { get; } 13 | 14 | internal OnCursorChangeEventArgs(dynamic cursorId) 15 | { 16 | CursorId = (int) cursorId; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnDocumentReadEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnDocumentReadEventArgs 8 | { 9 | /// 10 | /// The url that was loaded 11 | /// 12 | public string Url { get; } 13 | 14 | internal OnDocumentReadEventArgs(dynamic url) 15 | { 16 | Url = (string) url; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnInputFocusChangeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnInputFocusChangeEventArgs 8 | { 9 | /// 10 | /// True if the focus was received, false otherwise 11 | /// 12 | public bool DidGainFocus { get; } 13 | 14 | internal OnInputFocusChangeEventArgs(dynamic gainedFocus) 15 | { 16 | DidGainFocus = (bool) gainedFocus; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnLoadFailEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnLoadFailEventArgs 8 | { 9 | /// 10 | /// The url that was loaded 11 | /// 12 | public string Url { get; } 13 | 14 | /// 15 | /// The error code that was thrown 16 | /// 17 | public int ErrorCode { get; } 18 | 19 | /// 20 | /// The description of the error 21 | /// 22 | public string Description { get; } 23 | 24 | internal OnLoadFailEventArgs(dynamic url, dynamic errorCode, dynamic errorDescription) 25 | { 26 | Url = (string) url; 27 | ErrorCode = (int) errorCode; 28 | Description = (string) errorDescription; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnLoadStartEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnLoadStartEventArgs 8 | { 9 | /// 10 | /// The url that is being loaded 11 | /// 12 | public string Url { get; } 13 | 14 | internal OnLoadStartEventArgs(dynamic url) 15 | { 16 | Url = (string)url; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnNavigateEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnNavigateEventArgs 8 | { 9 | /// 10 | /// The target 11 | /// 12 | public string Url { get; } 13 | 14 | /// 15 | /// If the browser was created with isLocal set to true, and the browser tried to load a remote page, this would be set to true (and vice-versa). 16 | /// 17 | public bool IsBlocked { get; } 18 | internal OnNavigateEventArgs(dynamic target, dynamic isBlocked) 19 | { 20 | Url = (string)target; 21 | IsBlocked = (bool)isBlocked; 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnPopupEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnPopupEventArgs 8 | { 9 | /// 10 | /// The target url 11 | /// 12 | public string Url { get; } 13 | 14 | public string Opener { get; } 15 | 16 | public bool IsPopup { get; } 17 | 18 | internal OnPopupEventArgs(dynamic target, dynamic opener, bool isPopup) 19 | { 20 | Url = (string)target; 21 | Opener = (string)opener; 22 | IsPopup = (bool)isPopup; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnResourceBlockedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnResourceBlockedEventArgs 8 | { 9 | /// 10 | /// The url that was blocked 11 | /// 12 | public string Url { get; } 13 | 14 | /// 15 | /// The domain 16 | /// 17 | public string Domain { get; } 18 | 19 | /// 20 | /// The reason why the resource was blocked 21 | /// 22 | public BlockReason Reason { get; } 23 | 24 | internal OnResourceBlockedEventArgs(dynamic url, dynamic domain, dynamic reason) 25 | { 26 | Url = (string)url; 27 | Domain = (string)domain; 28 | Reason = (BlockReason)reason; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnTooltipEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Browsers.Events 6 | { 7 | public class OnTooltipEventArgs 8 | { 9 | /// 10 | /// The tooltip message 11 | /// 12 | public string Tooltip { get; } 13 | internal OnTooltipEventArgs(dynamic tooltip) 14 | { 15 | Tooltip = (string)tooltip; 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Browsers/Events/OnWhiteListChangeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.Browsers.Events 7 | { 8 | public class OnWhiteListChangeEventArgs 9 | { 10 | /// 11 | /// All the domains that were changed 12 | /// 13 | public string[] ChangedDomains { get; } 14 | 15 | internal OnWhiteListChangeEventArgs(dynamic list) 16 | { 17 | ChangedDomains = MtaShared.GetArrayFromTable(list, "System.String"); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Dx/Align.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Dx 6 | { 7 | /// 8 | /// Represents a horizontal alignment 9 | /// 10 | public enum HorizontalAlign 11 | { 12 | Left, 13 | Center, 14 | Right 15 | } 16 | 17 | /// 18 | /// Represents a vertical alignment 19 | /// 20 | public enum VerticalAlign 21 | { 22 | Top, 23 | Center, 24 | Bottom 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Dx/FontQuality.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Enums 6 | { 7 | /// 8 | /// Enum representing different font qualities used with Dx Font 9 | /// 10 | public enum FontQuality 11 | { 12 | Default, 13 | Draft, 14 | Proof, 15 | NonAntiAliased, 16 | AntiAliased, 17 | ClearType, 18 | ClearType_Natural 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Dx/IDrawable.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Elements; 2 | using Slipe.Client.Rendering.Events; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Dx 8 | { 9 | /// 10 | /// Interface for drawable objects on render 11 | /// 12 | public interface IDrawable 13 | { 14 | bool Draw(RootElement source, OnRenderEventArgs eventArgs); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Dx/StandardFont.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Dx 6 | { 7 | /// 8 | /// Represents the standard fonts built into GTA 9 | /// 10 | public enum StandardFont 11 | { 12 | Default, 13 | Clear, 14 | Arial, 15 | Sans, 16 | Pricedown, 17 | BankGothic, 18 | Diploma, 19 | Beckett 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Elements/Events/OnExplosionEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.Explosions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Numerics; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Elements.Events 8 | { 9 | public class OnExplosionEventArgs 10 | { 11 | /// 12 | /// The position of the explosion 13 | /// 14 | public Vector3 Position { get; } 15 | 16 | /// 17 | /// The type of the explosion 18 | /// 19 | public ExplosionType Type { get; } 20 | 21 | internal OnExplosionEventArgs(dynamic x, dynamic y, dynamic z, dynamic type) 22 | { 23 | Position = new Vector3((float)x, (float)y, (float)z); 24 | Type = (ExplosionType)type; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Elements/ResourceRootElement.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Elements 8 | { 9 | [DefaultElementClass(ElementType.Resource)] 10 | public class ResourceRootElement : Element 11 | { 12 | public ResourceRootElement(MtaElement element) : base(element) 13 | { 14 | 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Events/Event.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Client.Events 7 | { 8 | /// 9 | /// Class that wraps event utility methods 10 | /// 11 | public static class Event 12 | { 13 | /// 14 | /// Cancel the current event 15 | /// 16 | public static void Cancel() 17 | { 18 | MtaClient.CancelEvent(); 19 | } 20 | 21 | /// 22 | /// Check if the current event was canceled 23 | /// 24 | public static bool WasCancelled 25 | { 26 | get 27 | { 28 | return MtaShared.WasEventCancelled(); 29 | } 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Explosions/Explosion.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Numerics; 5 | using System.Text; 6 | using Slipe.Shared.Explosions; 7 | 8 | namespace Slipe.Client.Explosions 9 | { 10 | /// 11 | /// An explosion in the physical world 12 | /// 13 | public class Explosion 14 | { 15 | /// 16 | /// Create an explosion of a specific type at a certain position 17 | /// 18 | public static bool Create(Vector3 position, ExplosionType type, bool makeSound = true, float camShake = -1) 19 | { 20 | return MtaClient.CreateExplosion(position.X, position.Y, position.Z, (int)type, makeSound, camShake); 21 | } 22 | 23 | private Explosion() 24 | { 25 | 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/Events/OnFileDownloadCompleteEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Game.Events 6 | { 7 | public class OnFileDownloadCompleteEventArgs 8 | { 9 | /// 10 | /// The path of the downloaded file 11 | /// 12 | public string Path { get; } 13 | 14 | /// 15 | /// True if the download was a success 16 | /// 17 | public bool Success { get; } 18 | 19 | internal OnFileDownloadCompleteEventArgs(dynamic path, dynamic success) 20 | { 21 | Path = (string)path; 22 | Success = (bool)success; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/Events/OnMinimizeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Game.Events 6 | { 7 | public class OnMinimizeEventArgs 8 | { 9 | internal OnMinimizeEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/Events/OnNetworkInteruptionEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.Helpers; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.Game.Events 7 | { 8 | public class OnNetworkInteruptionEventArgs 9 | { 10 | /// 11 | /// The status of the interuption 12 | /// 13 | public NetworkInteruptionStatus Status { get; } 14 | 15 | /// 16 | /// Ticks since the start of the interuption 17 | /// 18 | public int Ticks { get; } 19 | 20 | internal OnNetworkInteruptionEventArgs(dynamic status, dynamic ticksSinceInteruptionStarted) 21 | { 22 | Status = (NetworkInteruptionStatus)status; 23 | Ticks = (int)ticksSinceInteruptionStarted; 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/Events/OnRestoreEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Game.Events 6 | { 7 | public class OnRestoreEventArgs 8 | { 9 | /// 10 | /// True if the rendertargets are cleared 11 | /// 12 | public bool RenderTargetsCleared { get; } 13 | 14 | internal OnRestoreEventArgs(dynamic cleared) 15 | { 16 | RenderTargetsCleared = (bool)cleared; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/Events/OnStartEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Resources; 2 | using Slipe.MtaDefinitions; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Game.Events 8 | { 9 | public class OnStartEventArgs 10 | { 11 | /// 12 | /// The started resource 13 | /// 14 | Resource Resource { get; } 15 | 16 | internal OnStartEventArgs(MtaResource resource) 17 | { 18 | Resource = Resource.Get(resource); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/Events/OnStopEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Resources; 2 | using Slipe.MtaDefinitions; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Game.Events 8 | { 9 | public class OnStopEventArgs 10 | { 11 | /// 12 | /// The stopped resource 13 | /// 14 | Resource Resource { get; } 15 | 16 | internal OnStopEventArgs(MtaResource resource) 17 | { 18 | Resource = Resource.Get(resource); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/Events/OnUpdateEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Game.Events 6 | { 7 | public class OnUpdateEventArgs 8 | { 9 | /// 10 | /// The interval between this frame and the previous one in milliseconds. 11 | /// 12 | public float TimeSlice { get; } 13 | 14 | /// 15 | /// The interval between this frame and the previous one in seconds 16 | /// 17 | public float DeltaTime { get; } 18 | 19 | internal OnUpdateEventArgs(dynamic timeSlice) 20 | { 21 | TimeSlice = timeSlice; 22 | DeltaTime = timeSlice / 1000; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/InputMode.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Game 6 | { 7 | /// 8 | /// Represents the input mode for Gui's 9 | /// 10 | public enum InputMode 11 | { 12 | Allow_Binds, 13 | No_Binds, 14 | No_Binds_When_Editing 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Game/TrayIconType.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Game 6 | { 7 | /// 8 | /// Represents windows notificatoin tray icons 9 | /// 10 | public enum TrayIconType 11 | { 12 | Default, 13 | Info, 14 | Warning, 15 | Error 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/GameWorld/AmbientSound.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.GameWorld 6 | { 7 | /// 8 | /// Represents an ambient sound 9 | /// 10 | public enum AmbientSound 11 | { 12 | GunFire, 13 | General 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/GameWorld/Events/OnBreakEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.GameWorld.Events 8 | { 9 | public class OnBreakEventArgs 10 | { 11 | /// 12 | /// The responsible element for breaking this WorldObject 13 | /// 14 | public PhysicalElement Attacker { get; } 15 | 16 | /// 17 | /// The amount of health lost 18 | /// 19 | public float Loss { get; } 20 | 21 | internal OnBreakEventArgs(dynamic loss, MtaElement target) 22 | { 23 | Attacker = ElementManager.Instance.GetElement(target); 24 | Loss = (float)loss; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/GameWorld/Events/OnDamageEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.GameWorld.Events 8 | { 9 | public class OnDamageEventArgs 10 | { 11 | /// 12 | /// The responsible element for damaging this WorldObject 13 | /// 14 | public PhysicalElement Attacker { get; } 15 | 16 | internal OnDamageEventArgs(MtaElement target) 17 | { 18 | Attacker = ElementManager.Instance.GetElement(target); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/GameWorld/Fire.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Numerics; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.GameWorld 8 | { 9 | public static class Fire 10 | { 11 | public static bool Create(Vector3 position, float size) 12 | { 13 | return MtaClient.CreateFire(position.X, position.Y, position.Z, size); 14 | } 15 | 16 | public static bool Extinguish(Vector3 position, float radius) 17 | { 18 | return MtaClient.ExtinguishFire(position.X, position.Y, position.Z, radius); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/GameWorld/RoomFurniture.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Enums 6 | { 7 | /// 8 | /// Represents a room used in setInteriorFurnitureEnabled 9 | /// 10 | public enum RoomFurniture 11 | { 12 | Shop, 13 | Office, 14 | Lounge, 15 | Bedroom, 16 | Kitchen 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/GameWorld/SwatRope.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | using System.Numerics; 6 | 7 | namespace Slipe.Client.GameWorld 8 | { 9 | /// 10 | /// Represents a SWAT rope that can be created 11 | /// 12 | public class SwatRope 13 | { 14 | public SwatRope(Vector3 position, int duration) 15 | { 16 | MtaClient.CreateSWATRope(position.X, position.Y, position.Z, duration); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/GameWorld/WorldSpecialProperty.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.GameWorld 6 | { 7 | /// 8 | /// Represents different properties of setWorldSpecialPropertyEnabled 9 | /// 10 | public enum WorldSpecialProperty 11 | { 12 | HoverCars, 13 | AirCars, 14 | ExtraBunny, 15 | ExtraJump, 16 | RandomFoliage, 17 | SniperMoon, 18 | ExtraAiResistance, 19 | UnderWorldWarp 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Button.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Text; 5 | using Slipe.Shared.Elements; 6 | using Slipe.MtaDefinitions; 7 | using System.Numerics; 8 | 9 | namespace Slipe.Client.Gui 10 | { 11 | /// 12 | /// Represents a Cegui button 13 | /// 14 | [DefaultElementClass(ElementType.GuiButton)] 15 | public class Button : GuiElement 16 | { 17 | [EditorBrowsable(EditorBrowsableState.Never)] 18 | public Button(MtaElement element) : base(element) 19 | { 20 | 21 | } 22 | 23 | /// 24 | /// Create a new button 25 | /// 26 | public Button(Vector2 position, Vector2 dimensions, string content, bool relative = false, GuiElement parent = null) 27 | : this(MtaClient.GuiCreateButton(position.X, position.Y, dimensions.X, dimensions.Y, content, relative, parent?.MTAElement)) { } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/EditableGuiElement.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Text; 5 | using Slipe.Client.Gui.Events; 6 | using Slipe.MtaDefinitions; 7 | 8 | namespace Slipe.Client.Gui 9 | { 10 | /// 11 | /// Represents an editable Gui element 12 | /// 13 | public abstract class EditableGuiElement : GuiElement 14 | { 15 | [EditorBrowsable(EditorBrowsableState.Never)] 16 | public EditableGuiElement(MtaElement element) : base(element) 17 | { 18 | 19 | } 20 | 21 | #region Events 22 | 23 | #pragma warning disable 67 24 | 25 | public delegate void OnChangedHandler(EditableGuiElement source, OnChangedEventArgs eventArgs); 26 | public event OnChangedHandler OnChanged; 27 | 28 | #pragma warning restore 67 29 | 30 | #endregion 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnAcceptedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Gui.Events 8 | { 9 | public class OnAcceptedEventArgs 10 | { 11 | /// 12 | /// The element which had focus 13 | /// 14 | public GuiElement Element { get; } 15 | 16 | internal OnAcceptedEventArgs(MtaElement element) 17 | { 18 | Element = ElementManager.Instance.GetElement(element); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnBlurEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui.Events 6 | { 7 | public class OnBlurEventArgs 8 | { 9 | internal OnBlurEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnChangedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Gui.Events 8 | { 9 | public class OnChangedEventArgs 10 | { 11 | /// 12 | /// The Gui element which was changed 13 | /// 14 | public EditableGuiElement Element { get; } 15 | 16 | internal OnChangedEventArgs(MtaElement element) 17 | { 18 | Element = ElementManager.Instance.GetElement(element); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnFocusEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui.Events 6 | { 7 | public class OnFocusEventArgs 8 | { 9 | internal OnFocusEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnMouseDownEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.IO; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Numerics; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Gui.Events 8 | { 9 | public class OnMouseDownEventArgs 10 | { 11 | /// 12 | /// The mouse button that was pressed. 13 | /// 14 | public MouseButton MouseButton { get; } 15 | 16 | /// 17 | /// Position on the screen the player clicked on. 18 | /// 19 | public Vector2 ScreenPosition { get; } 20 | 21 | internal OnMouseDownEventArgs(dynamic mouseButton, dynamic x, dynamic y) 22 | { 23 | MouseButton = (MouseButton)Enum.Parse(typeof(MouseButton), (string)mouseButton, true); 24 | ScreenPosition = new Vector2((float)x, (float)y); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnMouseEnterEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Numerics; 6 | using System.Text; 7 | 8 | namespace Slipe.Client.Gui.Events 9 | { 10 | public class OnMouseEnterEventArgs 11 | { 12 | /// 13 | /// The 2D position of the mouse 14 | /// 15 | public Vector2 Position { get; } 16 | 17 | /// 18 | /// The previous gui element the mouse was on 19 | /// 20 | public GuiElement Element { get; } 21 | 22 | internal OnMouseEnterEventArgs(dynamic x, dynamic y, MtaElement element) 23 | { 24 | Position = new Vector2((float)x, (float)y); 25 | Element = ElementManager.Instance.GetElement(element); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnMouseLeaveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Numerics; 6 | using System.Text; 7 | 8 | namespace Slipe.Client.Gui.Events 9 | { 10 | public class OnMouseLeaveEventArgs 11 | { 12 | /// 13 | /// The 2D position of the mouse 14 | /// 15 | public Vector2 Position { get; } 16 | 17 | /// 18 | /// The new gui element the mouse is on 19 | /// 20 | public GuiElement Element { get; } 21 | 22 | internal OnMouseLeaveEventArgs(dynamic x, dynamic y, MtaElement element) 23 | { 24 | Position = new Vector2((float)x, (float)y); 25 | Element = ElementManager.Instance.GetElement(element); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnMouseMoveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Numerics; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.Gui.Events 7 | { 8 | public class OnMouseMoveEventArgs 9 | { 10 | /// 11 | /// The 2D position of the mouse 12 | /// 13 | public Vector2 Position { get; } 14 | 15 | internal OnMouseMoveEventArgs(dynamic x, dynamic y) 16 | { 17 | Position = new Vector2((float)x, (float)y); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnMouseUpEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.IO; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Numerics; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Gui.Events 8 | { 9 | public class OnMouseUpEventArgs 10 | { 11 | /// 12 | /// The mouse button that was pressed. 13 | /// 14 | public MouseButton MouseButton { get; } 15 | 16 | /// 17 | /// Position on the screen the player clicked on. 18 | /// 19 | public Vector2 ScreenPosition { get; } 20 | 21 | internal OnMouseUpEventArgs(dynamic mouseButton, dynamic x, dynamic y) 22 | { 23 | MouseButton = (MouseButton)Enum.Parse(typeof(MouseButton), (string)mouseButton, true); 24 | ScreenPosition = new Vector2((float)x, (float)y); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnMouseWheelEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.IO; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.Gui.Events 7 | { 8 | public class OnMouseWheelEventArgs 9 | { 10 | /// 11 | /// The state of the mouse wheel 12 | /// 13 | public MouseWheelState State { get; } 14 | 15 | internal OnMouseWheelEventArgs(dynamic state) 16 | { 17 | State = (MouseWheelState)state; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnMoveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui.Events 6 | { 7 | public class OnMoveEventArgs 8 | { 9 | internal OnMoveEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnOpenEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui.Events 6 | { 7 | public class OnOpenEventArgs 8 | { 9 | internal OnOpenEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnResizeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui.Events 6 | { 7 | public class OnResizeEventArgs 8 | { 9 | internal OnResizeEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/Events/OnScrollEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui.Events 6 | { 7 | public class OnScrollEventArgs 8 | { 9 | internal OnScrollEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/GuiAlign.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui 6 | { 7 | /// 8 | /// Represents text alignment in gui's 9 | /// 10 | public enum HorizontalAlign 11 | { 12 | Left, 13 | Center, 14 | Right 15 | } 16 | 17 | public enum VerticalAlign 18 | { 19 | Top, 20 | Center, 21 | Bottom 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/GuiFont.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Text; 5 | using Slipe.MtaDefinitions; 6 | using Slipe.Shared.Elements; 7 | 8 | namespace Slipe.Client.Gui 9 | { 10 | /// 11 | /// Represents a custom Gui Font 12 | /// 13 | public class GuiFont : Element 14 | { 15 | [EditorBrowsable(EditorBrowsableState.Never)] 16 | public GuiFont(MtaElement element) : base(element) 17 | { 18 | 19 | } 20 | 21 | public GuiFont(string filePath, int size = 9) 22 | : this(MtaClient.GuiCreateFont(filePath, size)) { } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/SelectionMode.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui 6 | { 7 | /// 8 | /// Represents the selection mode for gui grid lists 9 | /// 10 | public enum SelectionMode 11 | { 12 | SingleRow, 13 | MultipleRow, 14 | SingleCell, 15 | MultipleCell, 16 | NominatedSingleColumnSection, 17 | NominatedMultipleColumnSection, 18 | SingleColumnSection, 19 | MultipleColumnSection, 20 | NominatedSingleRowSection, 21 | NominatedMultipleRowSection 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Gui/StandardGuiFont.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Gui 6 | { 7 | /// 8 | /// Represents standard Gui fonts 9 | /// 10 | public enum StandardGuiFont 11 | { 12 | Default_Normal, 13 | Default_Small, 14 | Default_Bold_Small, 15 | Clear_Normal, 16 | Sa_Header, 17 | Sa_Gothic 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Helpers/EagerAttachableObject.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.Elements; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Numerics; 5 | using System.Text; 6 | using Slipe.Client.Game; 7 | 8 | namespace Slipe.Client.Helpers 9 | { 10 | /// 11 | /// Abstract class that implements attaching functionality in an eager way (updates on PreRender) 12 | /// 13 | public abstract class EagerAttachableObject : LazyAttachableObject 14 | { 15 | protected override void OnAttach() 16 | { 17 | GameClient.OnUpdate += Update; 18 | } 19 | 20 | protected override void OnDetach() 21 | { 22 | GameClient.OnUpdate -= Update; 23 | base.OnDetach(); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/IO/ChatBoxEnums.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.IO 6 | { 7 | /// 8 | /// Represents fonts for chatboxes 9 | /// 10 | public enum ChatBoxFont 11 | { 12 | Tahoma, 13 | Verdana, 14 | TahomaBold, 15 | Arial 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/IO/Events/OnCharacterEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.IO.Events 6 | { 7 | public class OnCharacterEventArgs 8 | { 9 | /// 10 | /// The character that was entered 11 | /// 12 | public string Character { get; } 13 | 14 | internal OnCharacterEventArgs(dynamic character) 15 | { 16 | Character = (string)character; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/IO/Events/OnChatMessageEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.Utilities; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.IO.Events 7 | { 8 | public class OnChatMessageEventArgs 9 | { 10 | /// 11 | /// The text of the message 12 | /// 13 | public string Text { get; } 14 | 15 | /// 16 | /// The color of the message 17 | /// 18 | public Color Color { get; } 19 | 20 | internal OnChatMessageEventArgs(dynamic text, dynamic r, dynamic g, dynamic b) 21 | { 22 | Text = (string)text; 23 | Color = new Color((byte)r, (byte)g, (byte)b); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/IO/Events/OnKeyEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.IO.Events 6 | { 7 | public class OnKeyEventArgs 8 | { 9 | /// 10 | /// The string representation of the key 11 | /// 12 | public string Key { get; } 13 | 14 | /// 15 | /// True if the key was pressed 16 | /// 17 | public bool IsPressed { get; } 18 | 19 | internal OnKeyEventArgs(dynamic key, dynamic isPressed) 20 | { 21 | Key = (string)key; 22 | IsPressed = (bool)isPressed; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/IO/MTAConsole.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.IO 7 | { 8 | public class MtaConsole 9 | { 10 | internal MtaConsole() 11 | { 12 | 13 | } 14 | 15 | public bool Active 16 | { 17 | get 18 | { 19 | return MtaClient.IsConsoleActive(); 20 | } 21 | } 22 | 23 | public void WriteLine(string line) 24 | { 25 | MtaClient.OutputConsole(line); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/IO/MTADebug.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Elements; 2 | using Slipe.Client.IO.Events; 3 | using Slipe.MtaDefinitions; 4 | using Slipe.Shared.IO; 5 | using Slipe.Shared.Utilities; 6 | using System; 7 | using System.Collections.Generic; 8 | using System.Text; 9 | 10 | namespace Slipe.Client.IO 11 | { 12 | public class MtaDebug : SharedMtaDebug 13 | { 14 | public static bool Active 15 | { 16 | get 17 | { 18 | return MtaClient.IsDebugViewActive(); 19 | } 20 | set 21 | { 22 | MtaClient.SetDebugViewActive(value); 23 | } 24 | } 25 | 26 | #pragma warning disable 67 27 | 28 | public delegate void OnMessageHandler(RootElement source, OnDebugMessageEventArgs eventArgs); 29 | public static event OnMessageHandler OnMessage; 30 | 31 | #pragma warning enable 67 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Lights/LightType.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Lights 6 | { 7 | /// 8 | /// Represents different types of lights 9 | /// 10 | public enum LightType 11 | { 12 | Point, 13 | Spot, 14 | Dark 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnChokeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using Slipe.Shared.Weapons; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Client.Peds.Events 9 | { 10 | public class OnChokeEventArgs 11 | { 12 | /// 13 | /// The weapon that caused the choking 14 | /// 15 | SharedWeaponModel WeaponModel { get; } 16 | 17 | /// 18 | /// The ped responsible for the choking 19 | /// 20 | Ped ResponsiblePed { get; } 21 | 22 | internal OnChokeEventArgs(dynamic model, MtaElement ped) 23 | { 24 | WeaponModel = new SharedWeaponModel((int)model); 25 | ResponsiblePed = ElementManager.Instance.GetElement(ped); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnConsoleEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnConsoleEventArgs 8 | { 9 | /// 10 | /// Message entered into the console. 11 | /// 12 | public string Message { get; } 13 | 14 | internal OnConsoleEventArgs(dynamic message) 15 | { 16 | Message = (string) message; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnHeliKilledEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Vehicles; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Client.Peds.Events 9 | { 10 | public class OnHeliKilledEventArgs 11 | { 12 | /// 13 | /// The helicopter responsible 14 | /// 15 | public Helicopter ResponsibleHelicopter { get; } 16 | 17 | internal OnHeliKilledEventArgs(MtaElement element) 18 | { 19 | ResponsibleHelicopter = ElementManager.Instance.GetElement(element); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnJoinEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnJoinEventArgs 8 | { 9 | internal OnJoinEventArgs() 10 | { 11 | 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnNicknameChangedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnNicknameChangedEventArgs 8 | { 9 | /// 10 | /// The nickname the player had before. 11 | /// 12 | public string OldNickname { get; } 13 | 14 | /// 15 | /// The new nickname of the player. 16 | /// 17 | public string NewNickname { get; } 18 | 19 | internal OnNicknameChangedEventArgs(dynamic oldNickname, dynamic newNickname) 20 | { 21 | OldNickname = (string) oldNickname; 22 | NewNickname = (string) newNickname; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnPickupHitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Pickups; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Client.Peds.Events 9 | { 10 | public class OnPickupHitEventArgs 11 | { 12 | /// 13 | /// The pickup 14 | /// 15 | public Pickup Pickup { get; } 16 | 17 | /// 18 | /// True if the dimensions of the elements are the same 19 | /// 20 | public bool IsDimensionMatching { get; } 21 | 22 | internal OnPickupHitEventArgs(MtaElement pickup, dynamic dim) 23 | { 24 | Pickup = ElementManager.Instance.GetElement(pickup); 25 | IsDimensionMatching = (bool)dim; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnPickupLeaveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Pickups; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Client.Peds.Events 9 | { 10 | public class OnPickupLeaveEventArgs 11 | { 12 | /// 13 | /// The pickup 14 | /// 15 | public Pickup Pickup { get; } 16 | 17 | /// 18 | /// True if the dimensions of the elements are the same 19 | /// 20 | public bool IsDimensionMatching { get; } 21 | 22 | internal OnPickupLeaveEventArgs(MtaElement pickup, dynamic dim) 23 | { 24 | Pickup = ElementManager.Instance.GetElement(pickup); 25 | IsDimensionMatching = (bool)dim; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnQuitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using Slipe.Shared.Peds; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Client.Peds.Events 9 | { 10 | public class OnQuitEventArgs 11 | { 12 | /// 13 | /// How the player left. 14 | /// 15 | public QuitType QuitType { get; } 16 | 17 | internal OnQuitEventArgs(dynamic quitType) 18 | { 19 | QuitType = (QuitType)Enum.Parse(typeof(QuitType), (string)quitType); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnRadioSwitchEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Sounds; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.Peds.Events 7 | { 8 | public class OnRadioSwitchEventArgs 9 | { 10 | /// 11 | /// The station switched to 12 | /// 13 | public RadioStation RadioStation { get; } 14 | 15 | internal OnRadioSwitchEventArgs(dynamic station) 16 | { 17 | RadioStation = (RadioStation)station; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnSpawnEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Game; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Numerics; 7 | using System.Text; 8 | 9 | namespace Slipe.Client.Peds.Events 10 | { 11 | public class OnSpawnEventArgs 12 | { 13 | /// 14 | /// The team in which this player spawned 15 | /// 16 | public Team Team { get; } 17 | 18 | internal OnSpawnEventArgs(MtaElement team) 19 | { 20 | Team = ElementManager.Instance.GetElement(team); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnStealthKillEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Peds.Events 8 | { 9 | public class OnStealthKillEventArgs 10 | { 11 | /// 12 | /// The victim of the stealth kill 13 | /// 14 | public Ped Victim { get; } 15 | 16 | internal OnStealthKillEventArgs(MtaElement element) 17 | { 18 | Victim = ElementManager.Instance.GetElement(element); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnStepEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnStepEventArgs 8 | { 9 | /// 10 | /// True if the step was taken with the left foot, false for right 11 | /// 12 | public bool LeftFoot { get; } 13 | internal OnStepEventArgs(dynamic left) 14 | { 15 | LeftFoot = (bool)left; 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnStuntFinishEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnStuntFinishEventArgs 8 | { 9 | /// 10 | /// The type of stunt the player has performed 11 | /// 12 | public string StuntType { get; } 13 | 14 | /// 15 | /// The duration of the stunt 16 | /// 17 | public int Time { get; } 18 | 19 | /// 20 | /// The distance of the stunt 21 | /// 22 | public float Distance { get; } 23 | 24 | internal OnStuntFinishEventArgs(dynamic t, dynamic time, dynamic d) 25 | { 26 | StuntType = (string)t; 27 | Time = (int)time; 28 | Distance = (float)d; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnStuntStartEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnStuntStartEventArgs 8 | { 9 | /// 10 | /// The type of stunt the player is starting to perform. 11 | /// 12 | public string StuntType { get; } 13 | 14 | internal OnStuntStartEventArgs(dynamic t) 15 | { 16 | StuntType = (string)t; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnTargetEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Peds.Events 8 | { 9 | public class OnTargetEventArgs 10 | { 11 | /// 12 | /// The element that is targeted, can be null 13 | /// 14 | public PhysicalElement Target { get; } 15 | 16 | internal OnTargetEventArgs(MtaElement target) 17 | { 18 | Target = ElementManager.Instance.GetElement(target); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnVehicleEnterEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Vehicles; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using Slipe.Shared.Vehicles; 5 | using System; 6 | using System.Collections.Generic; 7 | using System.Text; 8 | 9 | namespace Slipe.Client.Peds.Events 10 | { 11 | public class OnVehicleEnterEventArgs 12 | { 13 | /// 14 | /// The vehicle that is entered 15 | /// 16 | public BaseVehicle Vehicle { get; } 17 | 18 | /// 19 | /// The seat that is entered 20 | /// 21 | public Seat Seat { get; } 22 | 23 | internal OnVehicleEnterEventArgs(MtaElement vehicle, dynamic seat) 24 | { 25 | Vehicle = ElementManager.Instance.GetElement(vehicle); 26 | Seat = (Seat) seat; 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnVehicleExitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Vehicles; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using Slipe.Shared.Vehicles; 5 | using System; 6 | using System.Collections.Generic; 7 | using System.Text; 8 | 9 | namespace Slipe.Client.Peds.Events 10 | { 11 | public class OnVehicleExitEventArgs 12 | { 13 | /// 14 | /// The vehicle that is exited 15 | /// 16 | public BaseVehicle Vehicle { get; } 17 | 18 | /// 19 | /// The seat that is exited 20 | /// 21 | public Seat Seat { get; } 22 | 23 | internal OnVehicleExitEventArgs(MtaElement vehicle, dynamic seat) 24 | { 25 | Vehicle = ElementManager.Instance.GetElement(vehicle); 26 | Seat = (Seat)seat; 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnVoicePausedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnVoicePausedEventArgs 8 | { 9 | internal OnVoicePausedEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnVoiceResumedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnVoiceResumedEventArgs 8 | { 9 | internal OnVoiceResumedEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnVoiceStartEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnVoiceStartEventArgs 8 | { 9 | internal OnVoiceStartEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnVoiceStopEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds.Events 6 | { 7 | public class OnVoiceStopEventArgs 8 | { 9 | internal OnVoiceStopEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/Events/OnWeaponSwitchEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.Weapons; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Client.Peds.Events 7 | { 8 | public class OnWeaponSwitchEventArgs 9 | { 10 | /// 11 | /// The weapon switched from 12 | /// 13 | public SharedWeaponModel PreviousWeapon { get; } 14 | 15 | /// 16 | /// The weapon switched to 17 | /// 18 | public SharedWeaponModel NewWeapon { get; } 19 | 20 | internal OnWeaponSwitchEventArgs(dynamic previousWeapon, dynamic newWeapon) 21 | { 22 | PreviousWeapon = new SharedWeaponModel((int)previousWeapon); 23 | NewWeapon = new SharedWeaponModel((int)newWeapon); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Peds/MoveState.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Peds 6 | { 7 | /// 8 | /// Represents a move state of a ped 9 | /// 10 | public enum MoveState 11 | { 12 | stand, 13 | walk, 14 | powerwalk, 15 | jog, 16 | sprint, 17 | crouch, 18 | crawl, 19 | jump, 20 | fall, 21 | climb 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Rendering/CameraEnums.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Rendering 6 | { 7 | /// 8 | /// Represents different google view effects 9 | /// 10 | public enum GoggleEffects 11 | { 12 | Normal, 13 | NightVision, 14 | ThermalVision 15 | } 16 | 17 | /// 18 | /// Represents different vehicle camera view modes 19 | /// 20 | public enum CameraViewMode 21 | { 22 | Bumper = 0, 23 | CloseExternal = 1, 24 | MiddleExternal = 2, 25 | FarExternal = 3, 26 | LowExternal = 4, 27 | Cinematic = 5 28 | } 29 | 30 | /// 31 | /// Represents different camera modes for the player 32 | /// 33 | public enum CameraMode 34 | { 35 | Player, 36 | Vehicle, 37 | Vehicle_Max 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Rendering/Events/OnHudRenderEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Rendering.Events 6 | { 7 | public class OnHudRenderEventArgs 8 | { 9 | OnHudRenderEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Rendering/Events/OnRenderEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Rendering.Events 6 | { 7 | public class OnRenderEventArgs 8 | { 9 | internal OnRenderEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Rendering/RenderEnums.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Rendering 6 | { 7 | /// 8 | /// Represents Dx draw blendmodes 9 | /// 10 | public enum BlendMode 11 | { 12 | blend, 13 | add, 14 | modulate_add, 15 | overwrite 16 | } 17 | 18 | /// 19 | /// Represents dx testmodes to simulate different memory states 20 | /// 21 | public enum TestMode 22 | { 23 | none, 24 | no_mem, 25 | low_mem, 26 | no_shader 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Rendering/RenderTarget.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using System.Numerics; 5 | using Slipe.MtaDefinitions; 6 | using Slipe.Client.Dx; 7 | 8 | namespace Slipe.Client.Rendering 9 | { 10 | /// 11 | /// A special type of texture that can be drawn on with the dx functions 12 | /// 13 | public class RenderTarget : Texture 14 | { 15 | public RenderTarget(Vector2 dimensions, bool withAlpha = false) : base() 16 | { 17 | materialElement = MtaClient.DxCreateRenderTarget((int)dimensions.X, (int)dimensions.Y, withAlpha); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/SlipeClient.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | netcoreapp3.1 5 | Slipe.Client 6 | OnOutputUpdated 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Sounds/Events/OnBeatEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Sounds.Events 6 | { 7 | public class OnBeatEventArgs 8 | { 9 | /// 10 | /// The position in the song of the beat 11 | /// 12 | public float Time { get; } 13 | 14 | internal OnBeatEventArgs(dynamic t) 15 | { 16 | Time = (float)t; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Sounds/Events/OnDownloadFinishedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Sounds.Events 6 | { 7 | public class OnDownloadFinishedEventArgs 8 | { 9 | public int Length { get; } 10 | 11 | internal OnDownloadFinishedEventArgs(dynamic l) 12 | { 13 | Length = (int)l; 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Sounds/Events/OnMetaChangedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Sounds.Events 6 | { 7 | public class OnMetaChangedEventArgs 8 | { 9 | /// 10 | /// The title of the stream 11 | /// 12 | public string StreamTitle { get; } 13 | 14 | internal OnMetaChangedEventArgs(dynamic t) 15 | { 16 | StreamTitle = (string)t; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Sounds/Events/OnStartEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Sounds.Events 6 | { 7 | public class OnStartEventArgs 8 | { 9 | public string Reason { get; } 10 | 11 | internal OnStartEventArgs(dynamic r) 12 | { 13 | Reason = (string)r; 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Sounds/Events/OnStopEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Sounds.Events 6 | { 7 | public class OnStopEventArgs 8 | { 9 | public string Reason { get; } 10 | 11 | internal OnStopEventArgs(dynamic r) 12 | { 13 | Reason = (string)r; 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Sounds/Events/OnStreamEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Sounds.Events 6 | { 7 | public class OnStreamEventArgs 8 | { 9 | public bool Success { get; } 10 | public int Length { get; } 11 | public string Name { get; } 12 | public string ErrorMessage { get; } 13 | 14 | internal OnStreamEventArgs(dynamic s, dynamic l, dynamic n, dynamic e) 15 | { 16 | Success = (bool)s; 17 | Length = (int)l; 18 | Name = (string)n; 19 | ErrorMessage = (string)e; 20 | } 21 | 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Vehicles/Events/OnAttachEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Vehicles.Events 8 | { 9 | public class OnAttachEventArgs 10 | { 11 | /// 12 | /// The truck the trailer is attached to 13 | /// 14 | public Vehicle Truck { get; } 15 | 16 | internal OnAttachEventArgs(MtaElement truck) 17 | { 18 | Truck = ElementManager.Instance.GetElement(truck); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Vehicles/Events/OnDetachEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Vehicles.Events 8 | { 9 | public class OnDetachEventArgs 10 | { 11 | /// 12 | /// The truck the trailer is detached from 13 | /// 14 | public Vehicle Truck { get; } 15 | 16 | internal OnDetachEventArgs(MtaElement truck) 17 | { 18 | Truck = ElementManager.Instance.GetElement(truck); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Vehicles/Events/OnEnterEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Peds; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using Slipe.Shared.Vehicles; 5 | using System; 6 | using System.Collections.Generic; 7 | using System.Text; 8 | 9 | namespace Slipe.Client.Vehicles.Events 10 | { 11 | public class OnEnterEventArgs 12 | { 13 | /// 14 | /// The player 15 | /// 16 | public Player Player { get; } 17 | 18 | /// 19 | /// The seat 20 | /// 21 | public Seat Seat { get; } 22 | 23 | internal OnEnterEventArgs(MtaElement player, dynamic seat) 24 | { 25 | Player = ElementManager.Instance.GetElement(player); 26 | Seat = (Seat)seat; 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Vehicles/Events/OnExitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Peds; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using Slipe.Shared.Vehicles; 5 | using System; 6 | using System.Collections.Generic; 7 | using System.Text; 8 | 9 | namespace Slipe.Client.Vehicles.Events 10 | { 11 | public class OnExitEventArgs 12 | { 13 | /// 14 | /// The player 15 | /// 16 | public Player Player { get; } 17 | 18 | /// 19 | /// The seat 20 | /// 21 | public Seat Seat { get; } 22 | 23 | internal OnExitEventArgs(MtaElement player, dynamic seat) 24 | { 25 | Player = ElementManager.Instance.GetElement(player); 26 | Seat = (Seat)seat; 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Vehicles/Events/OnExplodeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Vehicles.Events 6 | { 7 | public class OnExplodeEventArgs 8 | { 9 | internal OnExplodeEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Vehicles/Events/OnNitroStateChangeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Vehicles.Events 6 | { 7 | public class OnNitroStateChangeEventArgs 8 | { 9 | /// 10 | /// True if nitro was activated, false otherwise 11 | /// 12 | public bool State { get; } 13 | 14 | internal OnNitroStateChangeEventArgs(dynamic b) 15 | { 16 | State = (bool)b; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Vehicles/Events/OnPedHitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Client.Peds; 2 | using Slipe.MtaDefinitions; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Client.Vehicles.Events 9 | { 10 | public class OnPedHitEventArgs 11 | { 12 | /// 13 | /// The ped that was hit 14 | /// 15 | public Ped Ped { get; } 16 | 17 | internal OnPedHitEventArgs(MtaElement ped) 18 | { 19 | Ped = ElementManager.Instance.GetElement(ped); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Vehicles/Events/OnRespawnEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Vehicles.Events 6 | { 7 | public class OnRespawnEventArgs 8 | { 9 | /// 10 | /// True if the respawning vehicle exploded 11 | /// 12 | public bool Exploded { get; } 13 | 14 | internal OnRespawnEventArgs(dynamic b) 15 | { 16 | Exploded = (bool)b; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Weapons/Events/OnCreatedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Client.Weapons.Events 8 | { 9 | public class OnCreatedEventArgs 10 | { 11 | /// 12 | /// The creator 13 | /// 14 | public PhysicalElement Creator { get; } 15 | 16 | internal OnCreatedEventArgs(MtaElement element) 17 | { 18 | Creator = ElementManager.Instance.GetElement(element); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeClient/Weapons/ProjectileType.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Client.Weapons 6 | { 7 | /// 8 | /// Represents different projectiles 9 | /// 10 | public enum ProjectileType 11 | { 12 | Grenade = 16, 13 | TearGasGrenade, 14 | Molotov, 15 | RocketSimple, 16 | RocketHs, 17 | AirBomb, 18 | SatchelCharge = 39 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTAAccount.cs: -------------------------------------------------------------------------------- 1 | namespace Slipe.MtaDefinitions { 2 | public class MtaAccount{} 3 | } -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTAAcl.cs: -------------------------------------------------------------------------------- 1 | namespace Slipe.MtaDefinitions { 2 | public class MtaAcl{} 3 | } -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTAAclGroup.cs: -------------------------------------------------------------------------------- 1 | namespace Slipe.MtaDefinitions { 2 | public class MtaAclGroup{} 3 | } -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTABan.cs: -------------------------------------------------------------------------------- 1 | namespace Slipe.MtaDefinitions { 2 | public class MtaBan{} 3 | } -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTAElement.cs: -------------------------------------------------------------------------------- 1 | namespace Slipe.MtaDefinitions { 2 | public class MtaElement{} 3 | } -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTAException.cs: -------------------------------------------------------------------------------- 1 | namespace Slipe.MtaDefinitions { 2 | public class MtaException: System.Exception{} 3 | } -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTAPasswords.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Threading.Tasks; 3 | 4 | namespace Slipe.MtaDefinitions 5 | { 6 | public static class MtaPasswords 7 | { 8 | public static Task Hash(string input, int cost) 9 | { 10 | throw new NotImplementedException(); 11 | } 12 | 13 | public static Task Verify(string input, string hash) 14 | { 15 | throw new NotImplementedException(); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTAResource.cs: -------------------------------------------------------------------------------- 1 | namespace Slipe.MtaDefinitions { 2 | public class MtaResource{} 3 | } -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MTATimer.cs: -------------------------------------------------------------------------------- 1 | namespace Slipe.MtaDefinitions { 2 | public class MtaTimer{} 3 | } -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MtaExports.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Exports 6 | { 7 | public static class Export 8 | { 9 | public static object Invoke(string resourceName, string functionName, params object[] parameters) 10 | { 11 | throw new NotImplementedException(); 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/MtaJson.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Json 7 | { 8 | public static class Json 9 | { 10 | public static string Serialize(object value, bool compact = false, JsonPrettyType prettyType = JsonPrettyType.None) 11 | { 12 | throw new NotImplementedException(); 13 | } 14 | 15 | public static T Deserialize(string json) 16 | { 17 | throw new NotImplementedException(); 18 | } 19 | } 20 | 21 | public enum JsonPrettyType 22 | { 23 | None, 24 | Spaces, 25 | Tabs 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeMTADefinitions/SlipeMTADefinitions.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | netcoreapp3.1 5 | Slipe.MtaDefinitions 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Accounts/AccountException.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Accounts 6 | { 7 | public class AccountException : Exception 8 | { 9 | public AccountException(string message) : base(message) { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Accounts/Events/OnAddedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Server.Accounts.Events 7 | { 8 | public class OnAddedEventArgs 9 | { 10 | /// 11 | /// The ban that was added 12 | /// 13 | public Ban Ban { get; } 14 | 15 | internal OnAddedEventArgs(MtaBan ban) 16 | { 17 | Ban = new Ban(ban); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Accounts/Events/OnDataChangeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Server.Accounts.Events 7 | { 8 | public class OnDataChangeEventArgs 9 | { 10 | /// 11 | /// The account that had data changed 12 | /// 13 | public Account Account { get; } 14 | 15 | /// 16 | /// The changed key 17 | /// 18 | public string Key { get; } 19 | 20 | /// 21 | /// The new value 22 | /// 23 | public string Value { get; } 24 | 25 | internal OnDataChangeEventArgs(MtaAccount account, dynamic key, dynamic value) 26 | { 27 | Account = Account.Get(account); 28 | Key = (string) key; 29 | Value = (string) value; 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Accounts/Events/OnRemovedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Peds; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.Accounts.Events 9 | { 10 | public class OnRemovedEventArgs 11 | { 12 | /// 13 | /// The ban that was removed 14 | /// 15 | public Ban Ban { get; } 16 | 17 | /// 18 | /// The player responsible for removing the ban or null 19 | /// 20 | public Player ResponsiblePlayer { get; } 21 | 22 | internal OnRemovedEventArgs(MtaBan ban, MtaElement player) 23 | { 24 | Ban = new Ban(ban); 25 | ResponsiblePlayer = ElementManager.Instance.GetElement(player); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Acl/AclRightEnum.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Acl 6 | { 7 | /// 8 | /// Represents different types of ACL rights 9 | /// 10 | public enum AclRightEnum 11 | { 12 | GENERAL, 13 | FUNCTION, 14 | RESOURCE, 15 | COMMAND 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Acl/IAclObject.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Acl 6 | { 7 | /// 8 | /// Interface representing objects that can be entries in an MTA ACL 9 | /// 10 | public interface IAclObject 11 | { 12 | /// 13 | /// Formatted ACL entry; example: user.{name} or resource.{name} 14 | /// 15 | string AclIdentifier 16 | { 17 | get; 18 | } 19 | 20 | /// 21 | /// Check if the object has access to a given action 22 | /// 23 | bool HasPermissionTo(string action, bool defaultPermission = true); 24 | 25 | /// 26 | /// Check if the object is in a certain ACL group 27 | /// 28 | bool IsInACLGroup(AclGroup group); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Displays/DisplayEnums.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Displays 6 | { 7 | /// 8 | /// Represents the priority at which a display should be updates 9 | /// 10 | public enum Priority 11 | { 12 | Low, 13 | Medium, 14 | High 15 | } 16 | 17 | /// 18 | /// Represents the horizontal alignment 19 | /// 20 | public enum HorizontalAlignment 21 | { 22 | Left, 23 | Center, 24 | Right 25 | } 26 | 27 | /// 28 | /// Represents the vertical alignment 29 | /// 30 | public enum VerticalAlignment 31 | { 32 | Top, 33 | Center, 34 | Bottom 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Elements/ResourceRootElement.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Game; 3 | using Slipe.Server.Resources; 4 | using Slipe.Shared.Elements; 5 | using System; 6 | using System.Collections.Generic; 7 | using System.Text; 8 | 9 | namespace Slipe.Server.Elements 10 | { 11 | [DefaultElementClass(ElementType.Resource)] 12 | public class ResourceRootElement: Element 13 | { 14 | public ResourceRootElement(MtaElement element) : base(element) { } 15 | 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Events/Event.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Server.Events 7 | { 8 | /// 9 | /// Class that wraps event utility methods 10 | /// 11 | public static class Event 12 | { 13 | /// 14 | /// Cancel the current event 15 | /// 16 | public static void Cancel(string reason = "", bool cancel = true) 17 | { 18 | MtaServer.CancelEvent(cancel, reason); 19 | } 20 | 21 | /// 22 | /// Check if the current event was canceled 23 | /// 24 | public static bool WasCancelled 25 | { 26 | get 27 | { 28 | return MtaShared.WasEventCancelled(); 29 | } 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Explosions/Explosion.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Numerics; 5 | using System.Text; 6 | using Slipe.Shared.Elements; 7 | using Slipe.Shared.Explosions; 8 | 9 | namespace Slipe.Server.Explosions 10 | { 11 | /// 12 | /// An explosion in the world 13 | /// 14 | public class Explosion 15 | { 16 | /// 17 | /// Creates an explosion at a certain position of a certain type 18 | /// 19 | public static bool Create(Vector3 position, ExplosionType type, Element creator = null) 20 | { 21 | return MtaServer.CreateExplosion(position.X, position.Y, position.Z, (int)type, creator?.MTAElement); 22 | } 23 | 24 | private Explosion() 25 | { 26 | 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Game/Announcement.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Server.Game 7 | { 8 | public class Announcement 9 | { 10 | public string GameType 11 | { 12 | get => MtaServer.GetGameType(); 13 | set => MtaServer.SetGameType(value); 14 | } 15 | 16 | public string MapName 17 | { 18 | get => MtaServer.GetMapName(); 19 | set => MtaServer.SetGameType(value); 20 | } 21 | 22 | public bool SetRuleValue(string key, string value) => MtaServer.SetRuleValue(key, value); 23 | public string GetRuleValue(string key) => MtaServer.GetRuleValue(key); 24 | public bool RemoveRuleValue(string key) => MtaServer.RemoveRuleValue(key); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Game/BandwidthReduction.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Game 6 | { 7 | /// 8 | /// Represents a server config bandwidth reduction setting 9 | /// 10 | public enum BandwidthReduction 11 | { 12 | None, 13 | Medium, 14 | Maximum 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Game/Events/OnPreStartEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Resources; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Game.Events 8 | { 9 | public class OnPreStartEventArgs 10 | { 11 | /// 12 | /// The resource that was started 13 | /// 14 | public Resource Resource { get; } 15 | 16 | internal OnPreStartEventArgs(MtaResource resource) 17 | { 18 | Resource = Resource.Get(resource); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Game/Events/OnSettingChangeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Game.Events 6 | { 7 | public class OnSettingChangeEventArgs 8 | { 9 | /// 10 | /// The name of the setting that changed 11 | /// 12 | public string Setting { get; } 13 | 14 | /// 15 | /// The old value of this setting 16 | /// 17 | public string OldValue { get; } 18 | 19 | /// 20 | /// The new value of this setting 21 | /// 22 | public string NewValue { get; } 23 | 24 | internal OnSettingChangeEventArgs(dynamic setting, dynamic oldValue, dynamic newValue) 25 | { 26 | Setting = (string) setting; 27 | OldValue = (string) oldValue; 28 | NewValue = (string) newValue; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Game/Events/OnStartEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Resources; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Game.Events 8 | { 9 | public class OnStartEventArgs 10 | { 11 | /// 12 | /// The resource that was started 13 | /// 14 | public Resource Resource { get; } 15 | 16 | internal OnStartEventArgs(MtaResource resource) 17 | { 18 | Resource = Resource.Get(resource); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Game/Events/OnStopEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Resources; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Game.Events 8 | { 9 | public class OnStopEventArgs 10 | { 11 | /// 12 | /// The resource that was stopped 13 | /// 14 | public Resource Resource { get; } 15 | 16 | internal OnStopEventArgs(MtaResource resource) 17 | { 18 | Resource = Resource.Get(resource); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Game/Glitch.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Game 6 | { 7 | /// 8 | /// Represents different glitches in MTA 9 | /// 10 | public enum Glitch 11 | { 12 | QuickReload, 13 | FastMove, 14 | FastFire, 15 | CrouchBug, 16 | HighCloserRangeDamage, 17 | HitAnim, 18 | FastSprint, 19 | BadDriveByHitbox, 20 | QuickStand 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Game/Settings.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Game 6 | { 7 | public static class Settings 8 | { 9 | /// 10 | /// Stores arbitrary data in settings registry 11 | /// 12 | /// 13 | /// 14 | public static void Set(string setting, dynamic value) 15 | { 16 | Slipe.MtaDefinitions.MtaServer.Set(setting, value); 17 | } 18 | 19 | /// 20 | /// Retrieves arbitrary data from settings registry 21 | /// 22 | /// 23 | /// 24 | public static dynamic Get(string setting) 25 | { 26 | return Slipe.MtaDefinitions.MtaServer.Get(setting); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/GameWorld/Garage.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.Shared.GameWorld; 5 | 6 | namespace Slipe.Server.GameWorld 7 | { 8 | /// 9 | /// Class wrapping a garage as seen in singleplayer 10 | /// 11 | public class Garage : SharedGarage 12 | { 13 | public Garage(GarageLocation garage) : base(garage) { } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/IO/Events/OnChatMessageEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.Elements; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Server.IO.Events 7 | { 8 | public class OnChatMessageEventArgs 9 | { 10 | /// 11 | /// The text message that was broadcasted 12 | /// 13 | public string Message { get; } 14 | 15 | internal OnChatMessageEventArgs(dynamic message) 16 | { 17 | Message = (string) message; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/IO/MTAConsole.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Peds; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.IO 9 | { 10 | public class MtaConsole 11 | { 12 | internal MtaConsole() 13 | { 14 | 15 | } 16 | 17 | public void WriteLine(string line, Player player) 18 | { 19 | MtaServer.OutputConsole(line, player.MTAElement); 20 | } 21 | 22 | public void WriteLine(string line) 23 | { 24 | MtaServer.OutputConsole(line, Element.Root.MTAElement); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/IO/MTADebug.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.IO; 2 | using System; 3 | using System.Collections.Generic; 4 | using Slipe.Shared.Utilities; 5 | using System.Text; 6 | using Slipe.Server.IO.Events; 7 | using Slipe.Server.Elements; 8 | using Slipe.Shared.Elements; 9 | 10 | namespace Slipe.Server.IO 11 | { 12 | public class MtaDebug: SharedMtaDebug 13 | { 14 | internal MtaDebug() { } 15 | 16 | #pragma warning disable 67 17 | public delegate void OnMessageHandler(Element source, OnDebugMessageEventArgs eventArgs); 18 | public static event OnMessageHandler OnMessage; 19 | #pragma warning enable 67 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/IO/ServerLog.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Peds; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.IO 9 | { 10 | public class ServerLog 11 | { 12 | internal ServerLog() 13 | { 14 | 15 | } 16 | 17 | public void WriteLine(string line) 18 | { 19 | MtaServer.OutputServerLog(line); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnBanAddedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Accounts; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Peds.Events 8 | { 9 | public class OnBanAddedEventArgs 10 | { 11 | /// 12 | /// The ban which was added. 13 | /// 14 | public Ban Ban { get; } 15 | 16 | internal OnBanAddedEventArgs(MtaBan ban) 17 | { 18 | Ban = new Ban(ban); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnBannedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Accounts; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.Peds.Events 9 | { 10 | public class OnBannedEventArgs 11 | { 12 | /// 13 | /// The ban that was added 14 | /// 15 | public Ban Ban { get; } 16 | 17 | /// 18 | /// The player who added the ban 19 | /// 20 | public Player ResponsiblePlayer { get; } 21 | 22 | internal OnBannedEventArgs(MtaBan ban, MtaElement responsibleBanner) 23 | { 24 | Ban = new Ban(ban); 25 | ResponsiblePlayer = ElementManager.Instance.GetElement(responsibleBanner); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnChatEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.IO; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Server.Peds.Events 7 | { 8 | public class OnChatEventArgs 9 | { 10 | /// 11 | /// The message typed into the chat. 12 | /// 13 | public string Message { get; } 14 | 15 | /// 16 | /// The message type 17 | /// 18 | public MessageType MessageType { get; } 19 | 20 | internal OnChatEventArgs(dynamic message, dynamic type) 21 | { 22 | Message = (string) message; 23 | MessageType = (MessageType) type; 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnCommandEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Peds.Events 6 | { 7 | public class OnCommandEventArgs 8 | { 9 | /// 10 | /// The command that the player entered 11 | /// 12 | public string Command { get; } 13 | 14 | internal OnCommandEventArgs(dynamic command) 15 | { 16 | Command = (string) command; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnConsoleEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Peds.Events 6 | { 7 | public class OnConsoleEventArgs 8 | { 9 | /// 10 | /// Message entered into the console. 11 | /// 12 | public string Message { get; } 13 | 14 | internal OnConsoleEventArgs(dynamic message) 15 | { 16 | Message = (string) message; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnContactEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Peds.Events 8 | { 9 | public class OnContactEventArgs 10 | { 11 | /// 12 | /// The element the player was previously standing on (can be null) 13 | /// 14 | public PhysicalElement PreviousElement { get; } 15 | 16 | /// 17 | /// The new element the player is standing on (can be null) 18 | /// 19 | public PhysicalElement NewElement { get; } 20 | 21 | internal OnContactEventArgs(MtaElement previousElement, MtaElement newElement) 22 | { 23 | PreviousElement = ElementManager.Instance.GetElement(previousElement); 24 | NewElement = ElementManager.Instance.GetElement(newElement); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnJoinEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Peds.Events 6 | { 7 | public class OnJoinEventArgs 8 | { 9 | internal OnJoinEventArgs() 10 | { 11 | 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnLoginEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Accounts; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Peds.Events 8 | { 9 | public class OnLoginEventArgs 10 | { 11 | /// 12 | /// The previous account the player was signed in with 13 | /// 14 | public Account PreviousAccount { get; } 15 | 16 | /// 17 | /// The new account the player has signed in to 18 | /// 19 | public Account NewAccount { get; } 20 | 21 | internal OnLoginEventArgs(MtaAccount previousAccount, MtaAccount newAccount) 22 | { 23 | PreviousAccount = Account.Get(previousAccount); 24 | NewAccount = Account.Get(newAccount); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnLogoutEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Accounts; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Peds.Events 8 | { 9 | public class OnLogoutEventArgs 10 | { 11 | /// 12 | /// The previous account the player was signed in with 13 | /// 14 | public Account PreviousAccount { get; } 15 | 16 | /// 17 | /// The new account the player has signed in to 18 | /// 19 | public Account NewAccount { get; } 20 | 21 | internal OnLogoutEventArgs(MtaAccount previousAccount, MtaAccount newAccount) 22 | { 23 | PreviousAccount = Account.Get(previousAccount); 24 | NewAccount = Account.Get(newAccount); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnMarkerHitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Markers; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.Peds.Events 9 | { 10 | public class OnMarkerHitEventArgs 11 | { 12 | /// 13 | /// The marker that was hit 14 | /// 15 | public Marker Marker { get; } 16 | 17 | /// 18 | /// True if the dimensions of the elements are matching, false otherwise 19 | /// 20 | public bool IsDimensionMatching { get; } 21 | 22 | internal OnMarkerHitEventArgs(MtaElement markerHit, dynamic matchingDimension) 23 | { 24 | Marker = ElementManager.Instance.GetElement(markerHit); 25 | IsDimensionMatching = (bool) matchingDimension; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnMarkerLeaveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Markers; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.Peds.Events 9 | { 10 | public class OnMarkerLeaveEventArgs 11 | { 12 | /// 13 | /// The marker that was left 14 | /// 15 | public Marker Marker { get; } 16 | 17 | /// 18 | /// True if the elements are in the same dimension, false otherwise 19 | /// 20 | public bool IsDimensionMatching { get; } 21 | 22 | internal OnMarkerLeaveEventArgs(MtaElement markerLeft, dynamic matchingDimension) 23 | { 24 | Marker = ElementManager.Instance.GetElement(markerLeft); 25 | IsDimensionMatching = (bool)matchingDimension; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnModInfoEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Peds.Events 6 | { 7 | public class OnModInfoEventArgs 8 | { 9 | /// 10 | /// The filename of the modified file. 11 | /// 12 | public string FileName { get; } 13 | 14 | /// 15 | /// Details of each modification within the file 16 | /// See https://wiki.multitheftauto.com/wiki/OnPlayerModInfo 17 | /// 18 | public dynamic[] Items { get; } 19 | 20 | internal OnModInfoEventArgs(dynamic fileName, dynamic[] items) 21 | { 22 | FileName = (string) fileName; 23 | Items = items; 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnMutedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Peds.Events 6 | { 7 | public class OnMutedEventArgs 8 | { 9 | internal OnMutedEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnNetworkInteruptionEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.Helpers; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Server.Peds.Events 7 | { 8 | public class OnNetworkInteruptionEventArgs 9 | { 10 | /// 11 | /// The status of the network interuption 12 | /// 13 | public NetworkInteruptionStatus Status { get; } 14 | 15 | /// 16 | /// The ticks since the interruption started. 17 | /// 18 | public int Ticks { get; } 19 | 20 | internal OnNetworkInteruptionEventArgs(dynamic status, dynamic ticksSinceInteruptionStarted) 21 | { 22 | Status = (NetworkInteruptionStatus) status; 23 | Ticks = (int) ticksSinceInteruptionStarted; 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnPickupHitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Pickups; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.Peds.Events 9 | { 10 | public class OnPickupHitEventArgs 11 | { 12 | /// 13 | /// The pickup 14 | /// 15 | public Pickup Pickup { get; } 16 | 17 | internal OnPickupHitEventArgs(MtaElement pickup) 18 | { 19 | Pickup = ElementManager.Instance.GetElement(pickup); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnPickupLeaveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Pickups; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.Peds.Events 9 | { 10 | public class OnPickupLeaveEventArgs 11 | { 12 | /// 13 | /// The pickup 14 | /// 15 | public Pickup Pickup { get; } 16 | 17 | internal OnPickupLeaveEventArgs(MtaElement pickup) 18 | { 19 | Pickup = ElementManager.Instance.GetElement(pickup); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnPickupUseEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Pickups; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.Peds.Events 9 | { 10 | public class OnPickupUseEventArgs 11 | { 12 | /// 13 | /// The pickup 14 | /// 15 | public Pickup Pickup { get; } 16 | 17 | internal OnPickupUseEventArgs(MtaElement pickup) 18 | { 19 | Pickup = ElementManager.Instance.GetElement(pickup); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnPrivateMessageEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Peds.Events 8 | { 9 | public class OnPrivateMessageEventArgs 10 | { 11 | /// 12 | /// The message that was sent 13 | /// 14 | public string Message { get; } 15 | 16 | /// 17 | /// The player receiving the PM 18 | /// 19 | public Player Recipient { get; } 20 | 21 | internal OnPrivateMessageEventArgs(dynamic message, MtaElement recipient) 22 | { 23 | Message = (string) message; 24 | Recipient = ElementManager.Instance.GetElement(recipient); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnStealthKillEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Peds.Events 8 | { 9 | public class OnStealthKillEventArgs 10 | { 11 | /// 12 | /// The victim of the stealth kill 13 | /// 14 | public Ped Victim { get; } 15 | 16 | internal OnStealthKillEventArgs(MtaElement victim) 17 | { 18 | Victim = ElementManager.Instance.GetElement(victim); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnTargetEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Peds.Events 8 | { 9 | public class OnTargetEventArgs 10 | { 11 | /// 12 | /// The element that is targeted, can be null 13 | /// 14 | public PhysicalElement Target { get; } 15 | 16 | internal OnTargetEventArgs(MtaElement target) 17 | { 18 | Target = ElementManager.Instance.GetElement(target); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnUnmutedEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Peds.Events 6 | { 7 | public class OnUnmutedEventArgs 8 | { 9 | internal OnUnmutedEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnVoiceStartEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Peds.Events 6 | { 7 | public class OnVoiceStartEventArgs 8 | { 9 | internal OnVoiceStartEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnVoiceStopEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Peds.Events 6 | { 7 | public class OnVoiceStopEventArgs 8 | { 9 | internal OnVoiceStopEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Peds/Events/OnWeaponSwitchEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Server.Weapons; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Server.Peds.Events 7 | { 8 | public class OnWeaponSwitchEventArgs 9 | { 10 | /// 11 | /// The weapon switched from 12 | /// 13 | public WeaponModel PreviousWeapon { get; } 14 | 15 | /// 16 | /// The weapon switched to 17 | /// 18 | public WeaponModel NewWeapon { get; } 19 | 20 | internal OnWeaponSwitchEventArgs(dynamic previousWeapon, dynamic newWeapon) 21 | { 22 | PreviousWeapon = new WeaponModel((int)previousWeapon); 23 | NewWeapon = new WeaponModel((int)newWeapon); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Pickups/Events/OnSpawnEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Pickups.Events 6 | { 7 | public class OnSpawnEventArgs 8 | { 9 | internal OnSpawnEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Pickups/Events/OnUseEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Server.Peds; 3 | using Slipe.Shared.Elements; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Server.Pickups.Events 9 | { 10 | public class OnUseEventArgs 11 | { 12 | /// 13 | /// The player that is using the pickup 14 | /// 15 | public Player Player { get; } 16 | 17 | internal OnUseEventArgs(MtaElement usingPlayer) 18 | { 19 | Player = ElementManager.Instance.GetElement(usingPlayer); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/SlipeServer.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | Library 5 | netcoreapp3.1 6 | 7 | 8 | Slipe.Server 9 | OnOutputUpdated 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Vehicles/Events/OnAttachEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Vehicles.Events 8 | { 9 | public class OnAttachEventArgs 10 | { 11 | /// 12 | /// The truck the trailer is attached to 13 | /// 14 | public Vehicle Truck { get; } 15 | 16 | internal OnAttachEventArgs(MtaElement truck) 17 | { 18 | Truck = ElementManager.Instance.GetElement(truck); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Vehicles/Events/OnDamageEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Vehicles.Events 6 | { 7 | public class OnDamageEventArgs 8 | { 9 | /// 10 | /// The damage taken 11 | /// 12 | public float Loss { get; } 13 | 14 | internal OnDamageEventArgs(dynamic loss) 15 | { 16 | Loss = (float) loss; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Vehicles/Events/OnDetachEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Server.Vehicles.Events 8 | { 9 | public class OnDetachEventArgs 10 | { 11 | /// 12 | /// The truck the trailer is detached from 13 | /// 14 | public Vehicle Truck { get; } 15 | 16 | internal OnDetachEventArgs(MtaElement truck) 17 | { 18 | Truck = ElementManager.Instance.GetElement(truck); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Vehicles/Events/OnExplodeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Vehicles.Events 6 | { 7 | public class OnExplodeEventArgs 8 | { 9 | internal OnExplodeEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Vehicles/Events/OnRespawnEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Server.Vehicles.Events 6 | { 7 | public class OnRespawnEventArgs 8 | { 9 | /// 10 | /// True if the vehicle respawns after being exploded 11 | /// 12 | public bool IsExploded { get; } 13 | 14 | internal OnRespawnEventArgs(dynamic exploded) 15 | { 16 | IsExploded = (bool) exploded; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeServer/Vehicles/ModelHandling.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | using Slipe.Shared.Vehicles; 6 | 7 | namespace Slipe.Server.Vehicles 8 | { 9 | public class ModelHandling : Handling 10 | { 11 | protected int model; 12 | 13 | /// 14 | /// Builds vehicle handling from a vehicle model 15 | /// 16 | public ModelHandling(int targetModel) : base() 17 | { 18 | model = targetModel; 19 | } 20 | 21 | protected override void UpdateFromGame() 22 | { 23 | BuildFromTable(MtaShared.GetDictionaryFromTable(MtaServer.GetModelHandling((int) model), "System.String", "System.Dynamic")); 24 | } 25 | 26 | protected override void UpdateToGame(string key, dynamic value) 27 | { 28 | MtaServer.SetModelHandling(model, key, value); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/CollisionShapes/CollisionSphere.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | using System.Numerics; 6 | using Slipe.Shared.Elements; 7 | using System.ComponentModel; 8 | 9 | namespace Slipe.Shared.CollisionShapes 10 | { 11 | /// 12 | /// This is a shape that has a position and a radius. 13 | /// 14 | public class CollisionSphere: CollisionShape 15 | { 16 | [EditorBrowsable(EditorBrowsableState.Never)] 17 | public CollisionSphere(MtaElement element) : base(element) 18 | { 19 | 20 | } 21 | 22 | /// 23 | /// Creates a collision sphere from a position and radius 24 | /// 25 | public CollisionSphere(Vector3 position, float radius) 26 | : this(MtaShared.CreateColSphere(position.X, position.Y, position.Z, radius)) { } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/CollisionShapes/CollisionTube.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | using System.Numerics; 6 | using Slipe.Shared.Elements; 7 | using System.ComponentModel; 8 | 9 | namespace Slipe.Shared.CollisionShapes 10 | { 11 | /// 12 | /// This is a shape that has a position and a 2D (X/Y) radius and a height. 13 | /// 14 | public class CollisionTube: CollisionShape 15 | { 16 | [EditorBrowsable(EditorBrowsableState.Never)] 17 | public CollisionTube(MtaElement element) : base(element) 18 | { 19 | 20 | } 21 | 22 | /// 23 | /// Creates a collision tube from a position, radius and height 24 | /// 25 | public CollisionTube(Vector3 position, float radius, float height) 26 | :this(MtaShared.CreateColTube(position.X, position.Y, position.Z, radius, height)) { } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/CollisionShapes/Events/OnHitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.CollisionShapes.Events 8 | { 9 | public class OnHitEventArgs 10 | { 11 | /// 12 | /// The element that hit the collision shape 13 | /// 14 | public PhysicalElement Element { get; } 15 | 16 | /// 17 | /// True if the dimensions of the collision shape and the element are matching 18 | /// 19 | public bool IsDimensionMatching { get; } 20 | 21 | internal OnHitEventArgs(MtaElement element, dynamic matchingDimension) 22 | { 23 | Element = ElementManager.Instance.GetElement(element); 24 | IsDimensionMatching = (bool) matchingDimension; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/CollisionShapes/Events/OnLeaveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.CollisionShapes.Events 8 | { 9 | public class OnLeaveEventArgs 10 | { 11 | /// 12 | /// The element that left the collision shape 13 | /// 14 | public PhysicalElement Element { get; } 15 | 16 | /// 17 | /// True if the dimensions of the collision shape and the element are matching 18 | /// 19 | public bool IsDimensionMatching { get; } 20 | 21 | internal OnLeaveEventArgs(MtaElement element, dynamic matchingDimension) 22 | { 23 | Element = ElementManager.Instance.GetElement(element); 24 | IsDimensionMatching = (bool) matchingDimension; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Cryptography/Base64.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Shared.Cryptography 7 | { 8 | /// 9 | /// Represents static wrappers for the Base64 encoding algorithm 10 | /// 11 | public static class Base64 12 | { 13 | /// 14 | /// Encode a string with Base64 15 | /// 16 | public static string Encode(string input) 17 | { 18 | return MtaShared.Base64Encode(input); 19 | } 20 | 21 | /// 22 | /// Decode a string with Base64 23 | /// 24 | public static string Decode(string input) 25 | { 26 | return MtaShared.Base64Decode(input); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Cryptography/Bcrypt.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using System.Threading.Tasks; 5 | using Slipe.MtaDefinitions; 6 | 7 | namespace Slipe.Shared.Cryptography 8 | { 9 | /// 10 | /// Represents static wrappers for hasing strings with Bcrypt 11 | /// 12 | public static class Bcrypt 13 | { 14 | /// 15 | /// Hash a string with the Bcrypt algorithm 16 | /// 17 | public static Task Hash(string input, int cost = 10) 18 | { 19 | return MtaPasswords.Hash(input, cost); 20 | } 21 | 22 | /// 23 | /// Verify an input string against a Bcrypt hash 24 | /// 25 | public static Task Verify(string input, string hash) 26 | { 27 | return MtaPasswords.Verify(input, hash); 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Cryptography/Md5.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Shared.Cryptography 7 | { 8 | /// 9 | /// Represents static wrappers for Md5 methods 10 | /// 11 | public static class Md5 12 | { 13 | /// 14 | /// Hash a string with the Md5 algorithm 15 | /// 16 | public static string Hash(string input) 17 | { 18 | return MtaShared.Hash("md5", input); 19 | } 20 | 21 | /// 22 | /// Verify an input string against a Md5 hash 23 | /// 24 | public static bool Verify(string input, string hash) 25 | { 26 | return (Hash(input) == hash); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Cryptography/Sha1.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Shared.Cryptography 7 | { 8 | /// 9 | /// Represents static wrappers for Sha1 methods 10 | /// 11 | public static class Sha1 12 | { 13 | /// 14 | /// Hash a string with the Sha1 algorithm 15 | /// 16 | public static string Hash(string input) 17 | { 18 | return MtaShared.Hash("sha1", input); 19 | } 20 | 21 | /// 22 | /// Verify an input string against a Sha1 hash 23 | /// 24 | public static bool Verify(string input, string hash) 25 | { 26 | return (Hash(input) == hash); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Cryptography/Sha224.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Shared.Cryptography 7 | { 8 | /// 9 | /// Represents static wrappers for Sha224 methods 10 | /// 11 | public static class Sha224 12 | { 13 | /// 14 | /// Hash a string with the Sha224 algorithm 15 | /// 16 | public static string Hash(string input) 17 | { 18 | return MtaShared.Hash("sha224", input); 19 | } 20 | 21 | /// 22 | /// Verify an input string against a Sha224 hash 23 | /// 24 | public static bool Verify(string input, string hash) 25 | { 26 | return (Hash(input) == hash); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Cryptography/Sha256.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Shared.Cryptography 7 | { 8 | /// 9 | /// Represents static wrappers for Sha256 methods 10 | /// 11 | public static class Sha256 12 | { 13 | /// 14 | /// Hash a string with the Sha256 algorithm 15 | /// 16 | public static string Hash(string input) 17 | { 18 | return MtaShared.Hash("sha256", input); 19 | } 20 | 21 | /// 22 | /// Verify an input string against a Sha256 hash 23 | /// 24 | public static bool Verify(string input, string hash) 25 | { 26 | return (Hash(input) == hash); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Cryptography/Sha384.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Shared.Cryptography 7 | { 8 | /// 9 | /// Represents static wrappers for Sha384 methods 10 | /// 11 | public static class Sha384 12 | { 13 | /// 14 | /// Hash a string with the Sha384 algorithm 15 | /// 16 | public static string Hash(string input) 17 | { 18 | return MtaShared.Hash("sha384", input); 19 | } 20 | 21 | /// 22 | /// Verify an input string against a Sha384 hash 23 | /// 24 | public static bool Verify(string input, string hash) 25 | { 26 | return (Hash(input) == hash); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Cryptography/Sha512.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using Slipe.MtaDefinitions; 5 | 6 | namespace Slipe.Shared.Cryptography 7 | { 8 | /// 9 | /// Represents static wrappers for Sha512 methods 10 | /// 11 | public static class Sha512 12 | { 13 | /// 14 | /// Hash a string with the Sha512 algorithm 15 | /// 16 | public static string Hash(string input) 17 | { 18 | return MtaShared.Hash("sha512", input); 19 | } 20 | 21 | /// 22 | /// Verify an input string against a Sha512 hash 23 | /// 24 | public static bool Verify(string input, string hash) 25 | { 26 | return (Hash(input) == hash); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Elements/Events/OnCollisionShapeHitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.CollisionShapes; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.Elements.Events 8 | { 9 | public class OnCollisionShapeHitEventArgs 10 | { 11 | /// 12 | /// The collision shape that was hit 13 | /// 14 | public CollisionShape CollisionShape { get; } 15 | 16 | /// 17 | /// True if the dimension of both elements are matching, false otherwise 18 | /// 19 | public bool IsDimensionMatching { get; } 20 | 21 | internal OnCollisionShapeHitEventArgs(MtaElement colshape, dynamic matchingDimension) 22 | { 23 | CollisionShape = ElementManager.Instance.GetElement(colshape); 24 | IsDimensionMatching = (bool) matchingDimension; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Elements/Events/OnCollisionShapeLeaveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.CollisionShapes; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.Elements.Events 8 | { 9 | public class OnCollisionShapeLeaveEventArgs 10 | { 11 | /// 12 | /// The collision shape that was left 13 | /// 14 | public CollisionShape CollisionShape { get; } 15 | 16 | /// 17 | /// True if the dimension of both elements are matching, false otherwise 18 | /// 19 | public bool IsDimensionMatching { get; } 20 | 21 | internal OnCollisionShapeLeaveEventArgs(MtaElement colshape, dynamic matchingDimension) 22 | { 23 | CollisionShape = ElementManager.Instance.GetElement(colshape); 24 | IsDimensionMatching = (bool) matchingDimension; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Elements/Events/OnDestroyEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Elements.Events 6 | { 7 | public class OnDestroyEventArgs 8 | { 9 | internal OnDestroyEventArgs() 10 | { 11 | 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Elements/Events/OnModelChangeEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Elements.Events 6 | { 7 | public class OnModelChangeEventArgs 8 | { 9 | /// 10 | /// The old model 11 | /// 12 | int OldModel { get; } 13 | 14 | /// 15 | /// The new model 16 | /// 17 | int NewModel { get; } 18 | 19 | internal OnModelChangeEventArgs(dynamic oldModel, dynamic newModel) 20 | { 21 | OldModel = (int) oldModel; 22 | NewModel = (int) newModel; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Elements/Events/OnStartSyncEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Peds; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.Elements.Events 8 | { 9 | public class OnStartSyncEventArgs 10 | { 11 | /// 12 | /// The new player that started syncing this element 13 | /// 14 | public SharedPed NewSyncer { get; } 15 | 16 | internal OnStartSyncEventArgs(MtaElement newSyncer) 17 | { 18 | NewSyncer = ElementManager.Instance.GetElement(newSyncer); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Elements/Events/OnStopSyncEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Peds; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.Elements.Events 8 | { 9 | public class OnStopSyncEventArgs 10 | { 11 | /// 12 | /// The old player that stopped syncing this element 13 | /// 14 | public SharedPed OldSyncer { get; } 15 | 16 | internal OnStopSyncEventArgs(MtaElement oldSyncer) 17 | { 18 | OldSyncer = ElementManager.Instance.GetElement(oldSyncer); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Elements/Events/OnStreamInEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Elements.Events 6 | { 7 | public class OnStreamInEventArgs 8 | { 9 | internal OnStreamInEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Elements/Events/OnStreamOutEventArgs.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Elements.Events 6 | { 7 | public class OnStreamOutEventArgs 8 | { 9 | internal OnStreamOutEventArgs() { } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Exceptions/NullElementException.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Exceptions 6 | { 7 | /// 8 | /// Exception raised when a wrapped MTA function cannot find a requested element 9 | /// 10 | public class NullElementException : System.Exception 11 | { 12 | public NullElementException(string message) : base (message) { } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Explosions/ExplosionType.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Explosions 6 | { 7 | /// 8 | /// Represents different types of explosions 9 | /// 10 | public enum ExplosionType 11 | { 12 | Grenade, 13 | Molotov, 14 | Rocket, 15 | RocketWeak, 16 | Car, 17 | CarQuick, 18 | Boat, 19 | Heli, 20 | Mine, 21 | Object, 22 | TankGrenade, 23 | Small, 24 | Tiny 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Exports/ExportAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Exports 6 | { 7 | [AttributeUsage(AttributeTargets.Method, Inherited = false, AllowMultiple = false)] 8 | public sealed class ExportAttribute : Attribute 9 | { 10 | public string Name { get; set; } 11 | public bool IsHttp { get; set; } 12 | 13 | public ExportAttribute(string name = null, bool isHttp = false) 14 | { 15 | this.Name = name; 16 | this.IsHttp = isHttp; 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/GameWorld/GameTime.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.GameWorld 6 | { 7 | /// 8 | /// Class representing a game time, contrary to real time 9 | /// 10 | public struct GameTime 11 | { 12 | public int Hour { get; set; } 13 | public int Minute { get; set; } 14 | 15 | /// 16 | /// Create a game time from hours and minutes 17 | /// 18 | public GameTime(int hour, int minute) 19 | { 20 | Hour = Math.Clamp(hour, 0, 23); 21 | Minute = Math.Clamp(minute, 0, 59); 22 | } 23 | 24 | /// 25 | /// Create a game time from a datetime 26 | /// 27 | public GameTime(DateTime time) 28 | { 29 | Hour = time.Hour; 30 | Minute = time.Minute; 31 | } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/GameWorld/TrafficLightState.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.GameWorld 6 | { 7 | /// 8 | /// Represents the different states of traffic lights in the world 9 | /// 10 | public enum TrafficLightState 11 | { 12 | NSGreen, 13 | NSYellow, 14 | AllRed, 15 | EWGreen, 16 | EWYellow, 17 | AllGreen, 18 | AllYellow, 19 | NSYellowEWGreen, 20 | EWYellowNSGreen, 21 | Disabled, 22 | Auto 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Helpers/StatusCode.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Helpers 6 | { 7 | /// 8 | /// Represents a status code for the player screenshot event 9 | /// 10 | public enum StatusCode 11 | { 12 | Ok, 13 | Disabled, 14 | Minimized 15 | } 16 | 17 | /// 18 | /// Represents a status code for the player network status event 19 | /// 20 | public enum NetworkInteruptionStatus 21 | { 22 | Begin, 23 | End 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/IO/DebugMessageLevel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.IO 6 | { 7 | public enum DebugMessageLevel 8 | { 9 | Custom, 10 | Error, 11 | Warning, 12 | Information 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/IO/KeyEnum.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.IO 6 | { 7 | public enum KeyState 8 | { 9 | Down, 10 | Up, 11 | Both 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/IO/MessageType.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.IO 6 | { 7 | /// 8 | /// Represents different types of messages that can be send by players 9 | /// 10 | public enum MessageType 11 | { 12 | Normal, 13 | Action, 14 | Team 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/IO/MouseEnum.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.IO 6 | { 7 | /// 8 | /// Represents different mouse buttons 9 | /// 10 | public enum MouseButton 11 | { 12 | Left, 13 | Middle, 14 | Right, 15 | } 16 | 17 | /// 18 | /// Represents different mouse button states 19 | /// 20 | public enum MouseButtonState 21 | { 22 | Up, 23 | Down 24 | } 25 | 26 | /// 27 | /// Represents the scroll direction of the mouse wheel 28 | /// 29 | public enum MouseWheelState 30 | { 31 | Down = -1, 32 | Up = 1 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/IO/SharedMTADebug.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Utilities; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.IO 8 | { 9 | public class SharedMtaDebug 10 | { 11 | protected internal SharedMtaDebug() 12 | { 13 | 14 | } 15 | 16 | public void WriteLine(string line, DebugMessageLevel level = DebugMessageLevel.Information) 17 | { 18 | MtaShared.OutputDebugString(line, (int) level, 255, 255, 255); 19 | } 20 | 21 | public void WriteLine(string line, Color color) 22 | { 23 | MtaShared.OutputDebugString(line, (int)DebugMessageLevel.Custom, color.R, color.G, color.B); 24 | } 25 | 26 | public void WriteLine(string line, DebugMessageLevel level, Color color) 27 | { 28 | MtaShared.OutputDebugString(line, (int)level, color.R, color.G, color.B); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Markers/Events/OnHitEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.Markers.Events 8 | { 9 | public class OnHitEventArgs 10 | { 11 | /// 12 | /// The element that hit this marker 13 | /// 14 | public PhysicalElement Element { get; } 15 | 16 | /// 17 | /// True if the dimensions of the two elements are matching, false otherwise 18 | /// 19 | public bool IsDimensionMatching { get; } 20 | 21 | internal OnHitEventArgs(MtaElement hitElement, dynamic matchingDimension) 22 | { 23 | Element = ElementManager.Instance.GetElement(hitElement); 24 | IsDimensionMatching = (bool) matchingDimension; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Markers/Events/OnLeaveEventArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Text; 6 | 7 | namespace Slipe.Shared.Markers.Events 8 | { 9 | public class OnLeaveEventArgs 10 | { 11 | /// 12 | /// The element that left the marker 13 | /// 14 | public PhysicalElement Element { get; } 15 | 16 | /// 17 | /// True if the dimensions of the elements are matching, false otherwise 18 | /// 19 | public bool IsDimensionMatching { get; } 20 | 21 | internal OnLeaveEventArgs(MtaElement leaveElement, dynamic matchingDimension) 22 | { 23 | Element = ElementManager.Instance.GetElement(leaveElement); 24 | IsDimensionMatching = (bool) matchingDimension; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Markers/MarkerIcon.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Markers 6 | { 7 | public enum MarkerIcon 8 | { 9 | None, 10 | Arrow, 11 | Finish 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Markers/MarkerType.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Markers 6 | { 7 | /// 8 | /// Represents different types of markers 9 | /// 10 | public enum MarkerType 11 | { 12 | Checkpoint, 13 | Ring, 14 | Cylinder, 15 | Arrow, 16 | Corona 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Peds/BodyPart.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Peds 6 | { 7 | /// 8 | /// Represents either a ped body part 9 | /// 10 | public enum BodyPart 11 | { 12 | Torso = 3, 13 | Ass, 14 | LeftArm, 15 | RightArm, 16 | LeftLeg, 17 | RightLeg, 18 | Head, 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Peds/Bone.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Peds 6 | { 7 | /// 8 | /// Represents different bones on a ped 9 | /// 10 | public enum Bone 11 | { 12 | Pelvis1 = 1, 13 | Pelvis, 14 | Spine1, 15 | UpperTorso, 16 | Neck, 17 | Head2, 18 | Head1, 19 | Head, 20 | RightUpperTorso = 21, 21 | RightShoulder, 22 | RightElbow, 23 | RightWrist, 24 | RightHand, 25 | RightThumb, 26 | LeftUpperTorso = 31, 27 | LeftShoulder, 28 | LeftElbow, 29 | LeftWrist, 30 | LeftHand, 31 | LeftThumb, 32 | LeftHip = 41, 33 | LeftKnee, 34 | LeftAnkle, 35 | LeftFoot, 36 | RightHip = 51, 37 | RightKnee, 38 | RightAnkle, 39 | RightFoot 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Peds/FightingStyle.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Peds 6 | { 7 | /// 8 | /// Represents the fighting style of a ped 9 | /// 10 | public enum FightingStyle 11 | { 12 | Standard = 4, 13 | Boxing, 14 | Kung_Fu, 15 | Knee_Head, 16 | Grab_Kick = 15, 17 | Elbows 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Peds/HudComponent.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Peds 6 | { 7 | /// 8 | /// Represents different HUD components 9 | /// 10 | public enum HudComponent 11 | { 12 | all, 13 | ammo, 14 | area_name, 15 | armour, 16 | breath, 17 | clock, 18 | health, 19 | money, 20 | radar, 21 | vehicle_name, 22 | weapon, 23 | radio, 24 | wanted, 25 | crosshair 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Peds/QuitType.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Peds 6 | { 7 | /// 8 | /// Represents the type with which the player quit 9 | /// 10 | public enum QuitType 11 | { 12 | Unknown, 13 | Quit, 14 | Kicked, 15 | Banned, 16 | Bad_Connection, 17 | Timed_Out 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Pickups/Events/OnHitArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using Slipe.Shared.Peds; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Shared.Pickups.Events 9 | { 10 | public class OnHitArgs 11 | { 12 | /// 13 | /// The player that hit this pickup 14 | /// 15 | public SharedPed Player { get; } 16 | 17 | /// 18 | /// True if the dimensions of the two elements are matching, false otherwise 19 | /// 20 | public bool IsDimensionMatching { get; } 21 | 22 | internal OnHitArgs(MtaElement hitPlayer, dynamic matchingDimension) 23 | { 24 | Player = ElementManager.Instance.GetElement(hitPlayer); 25 | IsDimensionMatching = (bool) matchingDimension; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Pickups/Events/OnLeaveArgs.cs: -------------------------------------------------------------------------------- 1 | using Slipe.MtaDefinitions; 2 | using Slipe.Shared.Elements; 3 | using Slipe.Shared.Peds; 4 | using System; 5 | using System.Collections.Generic; 6 | using System.Text; 7 | 8 | namespace Slipe.Shared.Pickups.Events 9 | { 10 | public class OnLeaveArgs 11 | { 12 | /// 13 | /// The player that left the pickup 14 | /// 15 | public SharedPed Player { get; } 16 | 17 | /// 18 | /// True if the dimensions of the elements are matching, false otherwise 19 | /// 20 | public bool IsDimensionMatching { get; } 21 | 22 | internal OnLeaveArgs(MtaElement leavePlayer, dynamic matchingDimension) 23 | { 24 | Player = ElementManager.Instance.GetElement(leavePlayer); 25 | IsDimensionMatching = (bool) matchingDimension; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Pickups/PickupModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Pickups 6 | { 7 | /// 8 | /// Represents different types of custom pickup models 9 | /// 10 | public enum PickupModel 11 | { 12 | CashMoney = 1212, 13 | Health = 1240, 14 | Armour = 1242, 15 | InfoIcon = 1239, 16 | HouseBlue = 1272, 17 | HouseGreen = 1273, 18 | Adrenaline = 1241, 19 | Bribe = 1247, 20 | GtaIIISign = 1248, 21 | GtaIIIBomb = 1252, 22 | PhotoOp = 1253, 23 | Skull = 1254, 24 | MoneyIcon = 1274, 25 | BlueTShirt = 1275, 26 | Savedisk = 1277, 27 | Skulls = 1313, 28 | CoopIcon = 1314, 29 | TikiStatue = 1276, 30 | Parachute = 1310, 31 | DownArrow = 1318, 32 | DrugBundle = 1279 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Pickups/PickupType.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Pickups 6 | { 7 | /// 8 | /// Represents different types of pickups 9 | /// 10 | public enum PickupType 11 | { 12 | Health, 13 | Armour, 14 | Weapon, 15 | Custom 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/RPC/AsyncRpc.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Rpc 6 | { 7 | public class AsyncRpc: IRpc 8 | { 9 | public ClientRpcFailedAction OnClientRpcFailed { get; set; } 10 | 11 | public string Identifier { get; set; } 12 | public IRpc Rpc { get; set; } 13 | 14 | public AsyncRpc() 15 | { 16 | 17 | } 18 | 19 | public AsyncRpc(string identifier, IRpc rpc) 20 | { 21 | Identifier = identifier; 22 | Rpc = rpc; 23 | } 24 | 25 | public void Parse(dynamic value) 26 | { 27 | this.Identifier = value.Identifier; 28 | this.Rpc = value.Rpc; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/RPC/EmptyRpc.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Rpc 6 | { 7 | public class EmptyRpc: IRpc 8 | { 9 | private ClientRpcFailedAction rpcFailedAction; 10 | public ClientRpcFailedAction OnClientRpcFailed 11 | { 12 | get 13 | { 14 | return rpcFailedAction; 15 | } 16 | set 17 | { 18 | rpcFailedAction = value; 19 | } 20 | } 21 | 22 | public EmptyRpc() 23 | { 24 | rpcFailedAction = ClientRpcFailedAction.Ignore; 25 | } 26 | 27 | public void Parse(dynamic value) 28 | { 29 | 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/RPC/IRPC.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Rpc 6 | { 7 | public interface IRpc 8 | { 9 | ClientRpcFailedAction OnClientRpcFailed { get; set; } 10 | void Parse(dynamic value); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/RPC/SingleCastRpc.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Shared.Elements; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace Slipe.Shared.Rpc 7 | { 8 | public class SingleCastRpc: BaseRpc 9 | { 10 | public T Value { get; set; } 11 | 12 | public SingleCastRpc() 13 | { 14 | 15 | } 16 | 17 | public SingleCastRpc(T value) 18 | { 19 | this.Value = value; 20 | } 21 | 22 | public override void Parse(dynamic value) 23 | { 24 | this.Value = (T)value.Value; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Rendering/CameraFade.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Rendering 6 | { 7 | /// 8 | /// Represents camera fades 9 | /// 10 | public enum CameraFade 11 | { 12 | In, 13 | Out 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Rpc/RpcEnums.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Rpc 6 | { 7 | public enum ClientRpcFailedAction 8 | { 9 | Ignore, 10 | Queue 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/SlipeShared.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | Library 5 | netcoreapp3.1 6 | Slipe.Shared 7 | OnOutputUpdated 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeShared/Vehicles/HandlingEnums.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Shared.Vehicles 6 | { 7 | /// 8 | /// Represents different vehicle drive types 9 | /// 10 | public enum DriveType 11 | { 12 | Rwd, 13 | Fwd, 14 | Awd 15 | } 16 | 17 | /// 18 | /// Represents dfiferent engine types 19 | /// 20 | public enum EngineType 21 | { 22 | Petrol, 23 | Diesel, 24 | Electric 25 | } 26 | 27 | /// 28 | /// Represents lights used in Vehicle Handling 29 | /// 30 | public enum VehicleLightType 31 | { 32 | Long, 33 | Small, 34 | Big, 35 | Tall 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeSql/SlipeSql.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | netcoreapp3.1 5 | Slipe.Sql 6 | Slipe.Sql 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /Slipe/Core/Source/SlipeSql/SqlValue.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | 5 | namespace Slipe.Sql 6 | { 7 | public class SqlValue 8 | { 9 | /// 10 | /// Represents a value used by 11 | /// 12 | public SqlValue(object value) 13 | { 14 | 15 | } 16 | 17 | public static implicit operator string(SqlValue value) 18 | { 19 | return string.Empty; 20 | } 21 | 22 | public static implicit operator int(SqlValue value) 23 | { 24 | return 0; 25 | } 26 | 27 | public static implicit operator float(SqlValue value) 28 | { 29 | return 0f; 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Source/ClientSide/ClientSide.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | Exe 5 | netcoreapp3.1 6 | OnOutputUpdated 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /Source/ClientSide/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "profiles": { 3 | "ClientSide": { 4 | "commandName": "Executable", 5 | "executablePath": "slipe", 6 | "commandLineArgs": "restart-resource", 7 | "workingDirectory": "../../" 8 | } 9 | } 10 | } -------------------------------------------------------------------------------- /Source/ServerSide/ExampleManager.cs: -------------------------------------------------------------------------------- 1 | using Slipe.Server.IO; 2 | using Slipe.Server.Peds; 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Numerics; 6 | using System.Text; 7 | 8 | namespace ServerSide 9 | { 10 | public class ExampleManager 11 | { 12 | public ExampleManager() 13 | { 14 | Player.OnJoin += OnPlayerJoin; 15 | } 16 | 17 | private void OnPlayerJoin(Player source, Slipe.Server.Peds.Events.OnJoinEventArgs eventArgs) 18 | { 19 | source.Spawn(new Vector3(0, 0, 3), Slipe.Shared.Peds.PedModel.ballas1); 20 | 21 | ChatBox.WriteLine($"{source.Name} has joined the server!"); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Source/ServerSide/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "profiles": { 3 | "ServerSide": { 4 | "commandName": "Executable", 5 | "executablePath": "slipe", 6 | "commandLineArgs": "restart-resource", 7 | "workingDirectory": "../../" 8 | } 9 | } 10 | } -------------------------------------------------------------------------------- /Source/ServerSide/ServerSide.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | Exe 5 | netcoreapp3.1 6 | OnOutputUpdated 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /test.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 1 4 | 2 5 | 3 6 | 4 7 | 8 | test 9 | test 10 | test 11 | 12 | --------------------------------------------------------------------------------