diff --git a/[qb]/qb-spawn/.github/ISSUE_TEMPLATE/bug_report.md b/[qb]/qb-spawn/.github/ISSUE_TEMPLATE/bug_report.md
new file mode 100644
index 0000000..62f702f
--- /dev/null
+++ b/[qb]/qb-spawn/.github/ISSUE_TEMPLATE/bug_report.md
@@ -0,0 +1,32 @@
+---
+name: Bug report
+about: Create a report to help us improve or fix something
+title: "[BUG]"
+labels: bug
+assignees: ''
+
+---
+
+**Describe the bug**
+A clear and concise description of what the bug is. A stranger to qbcore should be able to read your bug report and understand how to reproduce it themselves and understand how the feature should work normally.
+
+**To Reproduce**
+Steps to reproduce the behavior:
+1. Go to '...'
+2. Click on '....'
+3. Use this item '....' (item's name from shared.lua if applicable)
+4. See error
+
+**Expected behavior**
+A clear and concise description of what you expected to happen.
+
+**Screenshots**
+If applicable, add screenshots to help explain your problem.
+
+**Questions (please complete the following information):**
+ - When you last updated: [e.g. last week]
+ - Are you using custom resource? which ones? [e.g. zdiscord, qb-target]
+ - Have you renamed `qb-` to something custom? [e.g. yes/no]
+
+**Additional context**
+Add any other context about the problem here.
diff --git a/[qb]/qb-spawn/.github/ISSUE_TEMPLATE/feature-request.md b/[qb]/qb-spawn/.github/ISSUE_TEMPLATE/feature-request.md
new file mode 100644
index 0000000..9e9bf3e
--- /dev/null
+++ b/[qb]/qb-spawn/.github/ISSUE_TEMPLATE/feature-request.md
@@ -0,0 +1,20 @@
+---
+name: Feature Request
+about: Suggest an idea for QBCore
+title: "[SUGGESTION]"
+labels: enhancement
+assignees: ''
+
+---
+
+**Is your feature request related to a problem? Please describe.**
+A clear and concise description of what the problem is.
+
+**Describe the feature you'd like**
+A clear and concise description of what you want to happen. and with as much detail as possible how it would function in your opinion. Please try to keep it unique.
+
+**Describe alternatives you've considered**
+A clear and concise description of any alternative solutions or features you've considered for people to have in mind just in case the main idea isn't liked but a derivative is.
+
+**Additional context**
+Add any other context or screenshots about the feature request here.
diff --git a/[qb]/qb-spawn/.github/auto_assign.yml b/[qb]/qb-spawn/.github/auto_assign.yml
new file mode 100644
index 0000000..2a80921
--- /dev/null
+++ b/[qb]/qb-spawn/.github/auto_assign.yml
@@ -0,0 +1,17 @@
+# Set to true to add reviewers to pull requests
+addReviewers: true
+
+# Set to true to add assignees to pull requests
+addAssignees: author
+
+# A list of reviewers to be added to pull requests (GitHub user name)
+reviewers:
+ - /maintenance
+
+# A list of keywords to be skipped the process that add reviewers if pull requests include it
+skipKeywords:
+ - wip
+
+# A number of reviewers added to the pull request
+# Set 0 to add all the reviewers (default: 0)
+numberOfReviewers: 0
\ No newline at end of file
diff --git a/[qb]/qb-spawn/.github/contributing.md b/[qb]/qb-spawn/.github/contributing.md
new file mode 100644
index 0000000..21fb806
--- /dev/null
+++ b/[qb]/qb-spawn/.github/contributing.md
@@ -0,0 +1,201 @@
+# Contributing to QBCore
+
+First of all, thank you for taking the time to contribute!
+
+These guidelines will help you help us in the best way possible regardless of your skill level. We ask that you try to read everything related to the way you'd like to contribute and try and use your best judgement for anything not covered.
+
+### Table of Contents
+
+[Code of Conduct](#code-of-conduct)
+
+[I don't want to read this whole thing, I just have a question!!!](#i-dont-want-to-read-this-whole-thing-i-just-have-a-question)
+
+[How Can I Contribute?](#how-can-i-contribute)
+ * [Reporting Bugs](#reporting-bugs)
+ * [Suggesting Features / Enhancements](#suggesting-features--enhancements)
+ * [Your First Code Contribution](#your-first-code-contribution)
+ * [Pull Requests](#pull-requests)
+
+[Styleguides](#styleguides)
+ * [Git Commit Messages](#git-commit-messages)
+ * [Lua Styleguide](#lua-styleguide)
+ * [JavaScript Styleguide](#javascript-styleguide)
+
+
+
+## Code of Conduct
+
+- Refrain from using languages other than English.
+- Refrain from discussing any politically charged or inflammatory topics.
+- Uphold mature conversations and respect each other; excessive profanity, hate speech or any kind of harassment will not be tolerated.
+- No advertising of any kind.
+- Follow these guidelines.
+- Do not mention members of github unless a question is directed at them and can't be answered by anyone else.
+- Do not mention any of the development team for any reason. We will read things as we get to them.
+
+## I don't want to read this whole thing I just have a question!!!
+
+> **Note:** Please don't file an issue to ask a question. You'll get faster results by using the resources below.
+
+* [QBCore Website](https://qbcore.org)
+* [QBCore Discord](https://discord.gg/qbcore)
+* [FiveM Discord - #qbcore channel](https://discord.gg/fivem)
+
+
+
+
+
+
+
+
+
+
+## How Can I Contribute?
+
+### Reporting Bugs
+
+The easiest way to contribute for most people is just to report bugs you find cause if nobody reports it there's a chance we'll never know it exists and then we'll never fix it.
+
+Before creating bug reports, please check [this list](#before-submitting-a-bug-report) as you might find out that you don't need to create one. When you are creating a bug report, please [include as many details as possible](#how-do-i-submit-a-good-bug-report). Fill out the bug-report template with the information it asks for helps us resolve issues faster.
+
+> **Note:** If you find a **Closed** issue that seems like it is the same thing that you're experiencing, open a new issue and include a link to the original issue in the body of your new one.
+
+#### Before Submitting A Bug Report
+
+* **Check the docs** There's a chance what you see as a bug might just work differently than you expect and if you think it could work better consider a feature enhancement report instead.
+* **Search the [discord](https://discord.gg/qbcore)** to see if anyone else has run into the issue and see if it was solved through user error or code changes. (if the code change isn't pending a PR and you know what you're doing consider submitting one following [Pull Requests](#pull-requests) )
+* **Determine which resource the problem should be reported in**. If the bug is related to the inventory for example report this bug under qb-inventory rather than under qb-core or some other resource.
+* **Perform a [cursory search](https://github.com/search?q=+is%3Aissue+user%3Aqbcore-framework)** to see if the problem has already been reported. If it has **and the issue is still open**, add a comment to the existing issue instead of opening a new one.
+
+#### How Do I Submit A (Good) Bug Report?
+
+Bugs are tracked as [GitHub issues](https://guides.github.com/features/issues/). After you've determined which resource your bug is related to, create an issue on that repository and provide the following information by filling in bug-report template.
+
+Explain the problem and include additional details to help maintainers reproduce the problem:
+
+* **Use a clear and descriptive title** for the issue to identify the problem.
+* **Describe the exact steps which reproduce the problem** in as many details as possible.
+* **Provide specific examples to demonstrate the steps**. If something happened with only a specific group or single item but not others, specify that.
+* **Describe the behavior you observed after following the steps** and point out what exactly is the problem with that behavior.
+* **Explain which behavior you expected to see instead and why.**
+* **Include screenshots** which show the specific bug in action or before and after.
+* **If the problem wasn't triggered by a specific action**, describe what you were doing before the problem happened and share more information using the guidelines below.
+
+Provide more context by answering these questions if possible:
+
+* **Did the problem start happening recently** (e.g. after updating to a new version of QBCore?) or was this always a problem?
+* If the problem started happening recently, **can you reproduce the problem in an older version of QBCore?** What's the most recent commit in which the problem doesn't happen?
+* **Can you reliably reproduce the issue?** If not, provide details about how often the problem happens and under which conditions it normally happens.
+
+Include details about your setup:
+
+* **When was your QBCore last updated?**
+* **What OS is the server running on**?
+* **Which *extra* resources do you have installed?**
+
+
+---
+
+
+### Suggesting Features / Enhancements
+
+This section guides you through submitting an enhancement suggestion for QBCore, including completely new features and minor improvements to existing functionality. Following these guidelines helps maintainers and the community understand your suggestion.
+
+Before creating enhancement suggestions, please check [this list](#before-submitting-an-enhancement-suggestion) as you might find out that you don't need to create one. When you are creating an enhancement suggestion, please [include as many details as possible](#how-do-i-submit-a-good-enhancement-suggestion). Fill in feature request template, including the steps that you imagine you would take if the feature you're requesting existed.
+
+#### Before Submitting An Enhancement Suggestion
+
+* **Make sure it doesn't already exist.** Sounds silly, but there's a lot of features built in to qbcore that people don't realize so take a look through the docs and stuff to make sure it's not already there.
+* **Check if there's already PR which provides that enhancement.**
+* **Determine which resource the enhancement should be suggested in.** if it fits with another resource suggest it in that resource. if it would be it's own resource suggest it in the main qb-core repository.
+* **Perform a [cursory search](https://github.com/search?q=+is%3Aissue+user%3Aqbcore-framework)** to see if the enhancement has already been suggested. If it has, add a comment to the existing issue instead of opening a new one.
+
+#### How Do I Submit A (Good) Enhancement Suggestion?
+
+Enhancement suggestions are tracked as [GitHub issues](https://guides.github.com/features/issues/). After you've determined which resource your enhancement suggestion is related to, create an issue on that repository and provide the following information:
+
+* **Use a clear and descriptive title** for the issue to identify the suggestion.
+* **Provide a step-by-step description of the suggested enhancement** in as many details as possible.
+* **Provide specific examples to demonstrate the steps**. Include copy/pasteable snippets which you use in those examples, as [Markdown code blocks](https://help.github.com/articles/markdown-basics/#multiple-lines).
+* **Describe the current behavior** and **explain which behavior you expected to see instead** and why.
+* **Include screenshots and animated GIFs** which help you demonstrate the steps or point out the part of QBCore which the suggestion is related to.
+* **Explain why this enhancement would be useful.**
+* **Be creative and unique.** Stealing ideas from popular servers 1:1 detail isn't going to get accepted.
+
+
+---
+
+
+
+### Your First Code Contribution
+
+Unsure where to begin contributing to QBCore? You can start by looking through these `beginner` and `help-wanted` issues.
+
+
+
+---
+
+
+### Pull Requests
+
+The process described here has several goals:
+
+- Maintain QBCore's quality.
+- Fix problems that are important to users.
+- Engage the community in working toward the best possible QBCore.
+- Enable a sustainable system for QBCore's maintainers to review contributions.
+
+Please follow these steps to have your contribution considered by the maintainers:
+
+1. Follow all instructions in The Pull Request template.
+2. Follow the [styleguides](#styleguides).
+3. Await review by the reviewer(s).
+
+While the prerequisites above must be satisfied prior to having your pull request reviewed, the reviewer(s) may ask you to complete additional design work, tests, or other changes before your pull request can be ultimately accepted.
+
+
+---
+
+## Styleguides
+
+### Git Commit Messages
+
+* Limit the first line to 72 characters or less.
+* Reference issues and pull requests liberally after the first line.
+* Consider starting the commit message with an applicable emoji:
+ * :art: `:art:` when improving the format/structure of the code
+ * :racehorse: `:racehorse:` when improving performance
+ * :memo: `:memo:` when writing docs
+ * :bug: `:bug:` when fixing a bug
+ * :fire: `:fire:` when removing code or files
+ * :white_check_mark: `:white_check_mark:` when adding tests
+ * :lock: `:lock:` when dealing with security
+ * :arrow_up: `:arrow_up:` when upgrading dependencies
+ * :arrow_down: `:arrow_down:` when downgrading dependencies
+ * :shirt: `:shirt:` when removing linter warnings
+
+### Lua Styleguide
+
+All lua code should be done using all the best practices of proper lua using the easiest to read yet fastest/most optimized methods of execution.
+
+- Use 4 Space indentation
+- Aim for lua 5.4 (include `lua54 'yes'` in the fxmanifest.lua)
+- Use `PlayerPedId()` instead of `GetPlayerPed(-1)`
+- Use `#(vector3 - vector3)` instead of `GetDistanceBetweenCoords()`
+- Don't create unnecessary threads. always try to find a better method of triggering events
+- Don't repeat yourself.. if you're using the same operations in many different places convert them into a function with flexible variables
+- For distance checking loops set longer waits if you're outside of a range
+- Job specific loops should only run for players with that job, don't waste cycles
+- When possible don't trust the client, esspecially with transactions
+- Balance security and optimizations
+- [Consider this Lua Performance guide](https://springrts.com/wiki/Lua_Performance)
+- Use local varriables everywhere possible
+- Make use of config options where it makes sense making features optional or customizable
+- Instead of `table.insert(myTable, "Value")` use `myTable[#myTable + 1] = "Value"`
+- Instead of `table.insert(ages, "bob", 30)` use `ages["bob"] = 30`
+
+
+### JavaScript Styleguide
+
+- Use 4 Space indentation
+- Don't repeat yourself.. if you're using the same operations in many different places convert them into a function with flexible variables.
diff --git a/[qb]/qb-spawn/.github/pull_request_template.md b/[qb]/qb-spawn/.github/pull_request_template.md
new file mode 100644
index 0000000..000f0f9
--- /dev/null
+++ b/[qb]/qb-spawn/.github/pull_request_template.md
@@ -0,0 +1,10 @@
+**Describe Pull request**
+First, make sure you've read and are following the contribution guidelines and style guide and your code reflects that.
+Write up a clear and concise description of what your pull request adds or fixes and if it's an added feature explain why you think it should be included in the core.
+
+If your PR is to fix an issue mention that issue here
+
+**Questions (please complete the following information):**
+- Have you personally loaded this code into an updated qbcore project and checked all it's functionality? [yes/no] (Be honest)
+- Does your code fit the style guidelines? [yes/no]
+- Does your PR fit the contribution guidelines? [yes/no]
diff --git a/[qb]/qb-spawn/.github/workflows/lint.yml b/[qb]/qb-spawn/.github/workflows/lint.yml
new file mode 100644
index 0000000..2151a22
--- /dev/null
+++ b/[qb]/qb-spawn/.github/workflows/lint.yml
@@ -0,0 +1,23 @@
+name: Lint
+on: [push, pull_request_target]
+jobs:
+ lint:
+ name: Lint Resource
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v2
+ with:
+ ref: ${{ github.event.pull_request.head.sha }}
+ - name: Lint
+ uses: iLLeniumStudios/fivem-lua-lint-action@v2
+ with:
+ capture: "junit.xml"
+ args: "-t --formatter JUnit"
+ extra_libs: mysql+qblocales+polyzone+qbapartments
+ - name: Generate Lint Report
+ if: always()
+ uses: mikepenz/action-junit-report@v3
+ with:
+ report_paths: "**/junit.xml"
+ check_name: Linting Report
+ fail_on_failure: false
diff --git a/[qb]/qb-spawn/LICENSE b/[qb]/qb-spawn/LICENSE
new file mode 100644
index 0000000..f288702
--- /dev/null
+++ b/[qb]/qb-spawn/LICENSE
@@ -0,0 +1,674 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The GNU General Public License is a free, copyleft license for
+software and other kinds of works.
+
+ The licenses for most software and other practical works are designed
+to take away your freedom to share and change the works. By contrast,
+the GNU General Public License is intended to guarantee your freedom to
+share and change all versions of a program--to make sure it remains free
+software for all its users. We, the Free Software Foundation, use the
+GNU General Public License for most of our software; it applies also to
+any other work released this way by its authors. You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+them if you wish), that you receive source code or can get it if you
+want it, that you can change the software or use pieces of it in new
+free programs, and that you know you can do these things.
+
+ To protect your rights, we need to prevent others from denying you
+these rights or asking you to surrender the rights. Therefore, you have
+certain responsibilities if you distribute copies of the software, or if
+you modify it: responsibilities to respect the freedom of others.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must pass on to the recipients the same
+freedoms that you received. You must make sure that they, too, receive
+or can get the source code. And you must show them these terms so they
+know their rights.
+
+ Developers that use the GNU GPL protect your rights with two steps:
+(1) assert copyright on the software, and (2) offer you this License
+giving you legal permission to copy, distribute and/or modify it.
+
+ For the developers' and authors' protection, the GPL clearly explains
+that there is no warranty for this free software. For both users' and
+authors' sake, the GPL requires that modified versions be marked as
+changed, so that their problems will not be attributed erroneously to
+authors of previous versions.
+
+ Some devices are designed to deny users access to install or run
+modified versions of the software inside them, although the manufacturer
+can do so. This is fundamentally incompatible with the aim of
+protecting users' freedom to change the software. The systematic
+pattern of such abuse occurs in the area of products for individuals to
+use, which is precisely where it is most unacceptable. Therefore, we
+have designed this version of the GPL to prohibit the practice for those
+products. If such problems arise substantially in other domains, we
+stand ready to extend this provision to those domains in future versions
+of the GPL, as needed to protect the freedom of users.
+
+ Finally, every program is threatened constantly by software patents.
+States should not allow patents to restrict development and use of
+software on general-purpose computers, but in those that do, we wish to
+avoid the special danger that patents applied to a free program could
+make it effectively proprietary. To prevent this, the GPL assures that
+patents cannot be used to render the program non-free.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ TERMS AND CONDITIONS
+
+ 0. Definitions.
+
+ "This License" refers to version 3 of the GNU General Public License.
+
+ "Copyright" also means copyright-like laws that apply to other kinds of
+works, such as semiconductor masks.
+
+ "The Program" refers to any copyrightable work licensed under this
+License. Each licensee is addressed as "you". "Licensees" and
+"recipients" may be individuals or organizations.
+
+ To "modify" a work means to copy from or adapt all or part of the work
+in a fashion requiring copyright permission, other than the making of an
+exact copy. The resulting work is called a "modified version" of the
+earlier work or a work "based on" the earlier work.
+
+ A "covered work" means either the unmodified Program or a work based
+on the Program.
+
+ To "propagate" a work means to do anything with it that, without
+permission, would make you directly or secondarily liable for
+infringement under applicable copyright law, except executing it on a
+computer or modifying a private copy. Propagation includes copying,
+distribution (with or without modification), making available to the
+public, and in some countries other activities as well.
+
+ To "convey" a work means any kind of propagation that enables other
+parties to make or receive copies. Mere interaction with a user through
+a computer network, with no transfer of a copy, is not conveying.
+
+ An interactive user interface displays "Appropriate Legal Notices"
+to the extent that it includes a convenient and prominently visible
+feature that (1) displays an appropriate copyright notice, and (2)
+tells the user that there is no warranty for the work (except to the
+extent that warranties are provided), that licensees may convey the
+work under this License, and how to view a copy of this License. If
+the interface presents a list of user commands or options, such as a
+menu, a prominent item in the list meets this criterion.
+
+ 1. Source Code.
+
+ The "source code" for a work means the preferred form of the work
+for making modifications to it. "Object code" means any non-source
+form of a work.
+
+ A "Standard Interface" means an interface that either is an official
+standard defined by a recognized standards body, or, in the case of
+interfaces specified for a particular programming language, one that
+is widely used among developers working in that language.
+
+ The "System Libraries" of an executable work include anything, other
+than the work as a whole, that (a) is included in the normal form of
+packaging a Major Component, but which is not part of that Major
+Component, and (b) serves only to enable use of the work with that
+Major Component, or to implement a Standard Interface for which an
+implementation is available to the public in source code form. A
+"Major Component", in this context, means a major essential component
+(kernel, window system, and so on) of the specific operating system
+(if any) on which the executable work runs, or a compiler used to
+produce the work, or an object code interpreter used to run it.
+
+ The "Corresponding Source" for a work in object code form means all
+the source code needed to generate, install, and (for an executable
+work) run the object code and to modify the work, including scripts to
+control those activities. However, it does not include the work's
+System Libraries, or general-purpose tools or generally available free
+programs which are used unmodified in performing those activities but
+which are not part of the work. For example, Corresponding Source
+includes interface definition files associated with source files for
+the work, and the source code for shared libraries and dynamically
+linked subprograms that the work is specifically designed to require,
+such as by intimate data communication or control flow between those
+subprograms and other parts of the work.
+
+ The Corresponding Source need not include anything that users
+can regenerate automatically from other parts of the Corresponding
+Source.
+
+ The Corresponding Source for a work in source code form is that
+same work.
+
+ 2. Basic Permissions.
+
+ All rights granted under this License are granted for the term of
+copyright on the Program, and are irrevocable provided the stated
+conditions are met. This License explicitly affirms your unlimited
+permission to run the unmodified Program. The output from running a
+covered work is covered by this License only if the output, given its
+content, constitutes a covered work. This License acknowledges your
+rights of fair use or other equivalent, as provided by copyright law.
+
+ You may make, run and propagate covered works that you do not
+convey, without conditions so long as your license otherwise remains
+in force. You may convey covered works to others for the sole purpose
+of having them make modifications exclusively for you, or provide you
+with facilities for running those works, provided that you comply with
+the terms of this License in conveying all material for which you do
+not control copyright. Those thus making or running the covered works
+for you must do so exclusively on your behalf, under your direction
+and control, on terms that prohibit them from making any copies of
+your copyrighted material outside their relationship with you.
+
+ Conveying under any other circumstances is permitted solely under
+the conditions stated below. Sublicensing is not allowed; section 10
+makes it unnecessary.
+
+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
+
+ No covered work shall be deemed part of an effective technological
+measure under any applicable law fulfilling obligations under article
+11 of the WIPO copyright treaty adopted on 20 December 1996, or
+similar laws prohibiting or restricting circumvention of such
+measures.
+
+ When you convey a covered work, you waive any legal power to forbid
+circumvention of technological measures to the extent such circumvention
+is effected by exercising rights under this License with respect to
+the covered work, and you disclaim any intention to limit operation or
+modification of the work as a means of enforcing, against the work's
+users, your or third parties' legal rights to forbid circumvention of
+technological measures.
+
+ 4. Conveying Verbatim Copies.
+
+ You may convey verbatim copies of the Program's source code as you
+receive it, in any medium, provided that you conspicuously and
+appropriately publish on each copy an appropriate copyright notice;
+keep intact all notices stating that this License and any
+non-permissive terms added in accord with section 7 apply to the code;
+keep intact all notices of the absence of any warranty; and give all
+recipients a copy of this License along with the Program.
+
+ You may charge any price or no price for each copy that you convey,
+and you may offer support or warranty protection for a fee.
+
+ 5. Conveying Modified Source Versions.
+
+ You may convey a work based on the Program, or the modifications to
+produce it from the Program, in the form of source code under the
+terms of section 4, provided that you also meet all of these conditions:
+
+ a) The work must carry prominent notices stating that you modified
+ it, and giving a relevant date.
+
+ b) The work must carry prominent notices stating that it is
+ released under this License and any conditions added under section
+ 7. This requirement modifies the requirement in section 4 to
+ "keep intact all notices".
+
+ c) You must license the entire work, as a whole, under this
+ License to anyone who comes into possession of a copy. This
+ License will therefore apply, along with any applicable section 7
+ additional terms, to the whole of the work, and all its parts,
+ regardless of how they are packaged. This License gives no
+ permission to license the work in any other way, but it does not
+ invalidate such permission if you have separately received it.
+
+ d) If the work has interactive user interfaces, each must display
+ Appropriate Legal Notices; however, if the Program has interactive
+ interfaces that do not display Appropriate Legal Notices, your
+ work need not make them do so.
+
+ A compilation of a covered work with other separate and independent
+works, which are not by their nature extensions of the covered work,
+and which are not combined with it such as to form a larger program,
+in or on a volume of a storage or distribution medium, is called an
+"aggregate" if the compilation and its resulting copyright are not
+used to limit the access or legal rights of the compilation's users
+beyond what the individual works permit. Inclusion of a covered work
+in an aggregate does not cause this License to apply to the other
+parts of the aggregate.
+
+ 6. Conveying Non-Source Forms.
+
+ You may convey a covered work in object code form under the terms
+of sections 4 and 5, provided that you also convey the
+machine-readable Corresponding Source under the terms of this License,
+in one of these ways:
+
+ a) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by the
+ Corresponding Source fixed on a durable physical medium
+ customarily used for software interchange.
+
+ b) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by a
+ written offer, valid for at least three years and valid for as
+ long as you offer spare parts or customer support for that product
+ model, to give anyone who possesses the object code either (1) a
+ copy of the Corresponding Source for all the software in the
+ product that is covered by this License, on a durable physical
+ medium customarily used for software interchange, for a price no
+ more than your reasonable cost of physically performing this
+ conveying of source, or (2) access to copy the
+ Corresponding Source from a network server at no charge.
+
+ c) Convey individual copies of the object code with a copy of the
+ written offer to provide the Corresponding Source. This
+ alternative is allowed only occasionally and noncommercially, and
+ only if you received the object code with such an offer, in accord
+ with subsection 6b.
+
+ d) Convey the object code by offering access from a designated
+ place (gratis or for a charge), and offer equivalent access to the
+ Corresponding Source in the same way through the same place at no
+ further charge. You need not require recipients to copy the
+ Corresponding Source along with the object code. If the place to
+ copy the object code is a network server, the Corresponding Source
+ may be on a different server (operated by you or a third party)
+ that supports equivalent copying facilities, provided you maintain
+ clear directions next to the object code saying where to find the
+ Corresponding Source. Regardless of what server hosts the
+ Corresponding Source, you remain obligated to ensure that it is
+ available for as long as needed to satisfy these requirements.
+
+ e) Convey the object code using peer-to-peer transmission, provided
+ you inform other peers where the object code and Corresponding
+ Source of the work are being offered to the general public at no
+ charge under subsection 6d.
+
+ A separable portion of the object code, whose source code is excluded
+from the Corresponding Source as a System Library, need not be
+included in conveying the object code work.
+
+ A "User Product" is either (1) a "consumer product", which means any
+tangible personal property which is normally used for personal, family,
+or household purposes, or (2) anything designed or sold for incorporation
+into a dwelling. In determining whether a product is a consumer product,
+doubtful cases shall be resolved in favor of coverage. For a particular
+product received by a particular user, "normally used" refers to a
+typical or common use of that class of product, regardless of the status
+of the particular user or of the way in which the particular user
+actually uses, or expects or is expected to use, the product. A product
+is a consumer product regardless of whether the product has substantial
+commercial, industrial or non-consumer uses, unless such uses represent
+the only significant mode of use of the product.
+
+ "Installation Information" for a User Product means any methods,
+procedures, authorization keys, or other information required to install
+and execute modified versions of a covered work in that User Product from
+a modified version of its Corresponding Source. The information must
+suffice to ensure that the continued functioning of the modified object
+code is in no case prevented or interfered with solely because
+modification has been made.
+
+ If you convey an object code work under this section in, or with, or
+specifically for use in, a User Product, and the conveying occurs as
+part of a transaction in which the right of possession and use of the
+User Product is transferred to the recipient in perpetuity or for a
+fixed term (regardless of how the transaction is characterized), the
+Corresponding Source conveyed under this section must be accompanied
+by the Installation Information. But this requirement does not apply
+if neither you nor any third party retains the ability to install
+modified object code on the User Product (for example, the work has
+been installed in ROM).
+
+ The requirement to provide Installation Information does not include a
+requirement to continue to provide support service, warranty, or updates
+for a work that has been modified or installed by the recipient, or for
+the User Product in which it has been modified or installed. Access to a
+network may be denied when the modification itself materially and
+adversely affects the operation of the network or violates the rules and
+protocols for communication across the network.
+
+ Corresponding Source conveyed, and Installation Information provided,
+in accord with this section must be in a format that is publicly
+documented (and with an implementation available to the public in
+source code form), and must require no special password or key for
+unpacking, reading or copying.
+
+ 7. Additional Terms.
+
+ "Additional permissions" are terms that supplement the terms of this
+License by making exceptions from one or more of its conditions.
+Additional permissions that are applicable to the entire Program shall
+be treated as though they were included in this License, to the extent
+that they are valid under applicable law. If additional permissions
+apply only to part of the Program, that part may be used separately
+under those permissions, but the entire Program remains governed by
+this License without regard to the additional permissions.
+
+ When you convey a copy of a covered work, you may at your option
+remove any additional permissions from that copy, or from any part of
+it. (Additional permissions may be written to require their own
+removal in certain cases when you modify the work.) You may place
+additional permissions on material, added by you to a covered work,
+for which you have or can give appropriate copyright permission.
+
+ Notwithstanding any other provision of this License, for material you
+add to a covered work, you may (if authorized by the copyright holders of
+that material) supplement the terms of this License with terms:
+
+ a) Disclaiming warranty or limiting liability differently from the
+ terms of sections 15 and 16 of this License; or
+
+ b) Requiring preservation of specified reasonable legal notices or
+ author attributions in that material or in the Appropriate Legal
+ Notices displayed by works containing it; or
+
+ c) Prohibiting misrepresentation of the origin of that material, or
+ requiring that modified versions of such material be marked in
+ reasonable ways as different from the original version; or
+
+ d) Limiting the use for publicity purposes of names of licensors or
+ authors of the material; or
+
+ e) Declining to grant rights under trademark law for use of some
+ trade names, trademarks, or service marks; or
+
+ f) Requiring indemnification of licensors and authors of that
+ material by anyone who conveys the material (or modified versions of
+ it) with contractual assumptions of liability to the recipient, for
+ any liability that these contractual assumptions directly impose on
+ those licensors and authors.
+
+ All other non-permissive additional terms are considered "further
+restrictions" within the meaning of section 10. If the Program as you
+received it, or any part of it, contains a notice stating that it is
+governed by this License along with a term that is a further
+restriction, you may remove that term. If a license document contains
+a further restriction but permits relicensing or conveying under this
+License, you may add to a covered work material governed by the terms
+of that license document, provided that the further restriction does
+not survive such relicensing or conveying.
+
+ If you add terms to a covered work in accord with this section, you
+must place, in the relevant source files, a statement of the
+additional terms that apply to those files, or a notice indicating
+where to find the applicable terms.
+
+ Additional terms, permissive or non-permissive, may be stated in the
+form of a separately written license, or stated as exceptions;
+the above requirements apply either way.
+
+ 8. Termination.
+
+ You may not propagate or modify a covered work except as expressly
+provided under this License. Any attempt otherwise to propagate or
+modify it is void, and will automatically terminate your rights under
+this License (including any patent licenses granted under the third
+paragraph of section 11).
+
+ However, if you cease all violation of this License, then your
+license from a particular copyright holder is reinstated (a)
+provisionally, unless and until the copyright holder explicitly and
+finally terminates your license, and (b) permanently, if the copyright
+holder fails to notify you of the violation by some reasonable means
+prior to 60 days after the cessation.
+
+ Moreover, your license from a particular copyright holder is
+reinstated permanently if the copyright holder notifies you of the
+violation by some reasonable means, this is the first time you have
+received notice of violation of this License (for any work) from that
+copyright holder, and you cure the violation prior to 30 days after
+your receipt of the notice.
+
+ Termination of your rights under this section does not terminate the
+licenses of parties who have received copies or rights from you under
+this License. If your rights have been terminated and not permanently
+reinstated, you do not qualify to receive new licenses for the same
+material under section 10.
+
+ 9. Acceptance Not Required for Having Copies.
+
+ You are not required to accept this License in order to receive or
+run a copy of the Program. Ancillary propagation of a covered work
+occurring solely as a consequence of using peer-to-peer transmission
+to receive a copy likewise does not require acceptance. However,
+nothing other than this License grants you permission to propagate or
+modify any covered work. These actions infringe copyright if you do
+not accept this License. Therefore, by modifying or propagating a
+covered work, you indicate your acceptance of this License to do so.
+
+ 10. Automatic Licensing of Downstream Recipients.
+
+ Each time you convey a covered work, the recipient automatically
+receives a license from the original licensors, to run, modify and
+propagate that work, subject to this License. You are not responsible
+for enforcing compliance by third parties with this License.
+
+ An "entity transaction" is a transaction transferring control of an
+organization, or substantially all assets of one, or subdividing an
+organization, or merging organizations. If propagation of a covered
+work results from an entity transaction, each party to that
+transaction who receives a copy of the work also receives whatever
+licenses to the work the party's predecessor in interest had or could
+give under the previous paragraph, plus a right to possession of the
+Corresponding Source of the work from the predecessor in interest, if
+the predecessor has it or can get it with reasonable efforts.
+
+ You may not impose any further restrictions on the exercise of the
+rights granted or affirmed under this License. For example, you may
+not impose a license fee, royalty, or other charge for exercise of
+rights granted under this License, and you may not initiate litigation
+(including a cross-claim or counterclaim in a lawsuit) alleging that
+any patent claim is infringed by making, using, selling, offering for
+sale, or importing the Program or any portion of it.
+
+ 11. Patents.
+
+ A "contributor" is a copyright holder who authorizes use under this
+License of the Program or a work on which the Program is based. The
+work thus licensed is called the contributor's "contributor version".
+
+ A contributor's "essential patent claims" are all patent claims
+owned or controlled by the contributor, whether already acquired or
+hereafter acquired, that would be infringed by some manner, permitted
+by this License, of making, using, or selling its contributor version,
+but do not include claims that would be infringed only as a
+consequence of further modification of the contributor version. For
+purposes of this definition, "control" includes the right to grant
+patent sublicenses in a manner consistent with the requirements of
+this License.
+
+ Each contributor grants you a non-exclusive, worldwide, royalty-free
+patent license under the contributor's essential patent claims, to
+make, use, sell, offer for sale, import and otherwise run, modify and
+propagate the contents of its contributor version.
+
+ In the following three paragraphs, a "patent license" is any express
+agreement or commitment, however denominated, not to enforce a patent
+(such as an express permission to practice a patent or covenant not to
+sue for patent infringement). To "grant" such a patent license to a
+party means to make such an agreement or commitment not to enforce a
+patent against the party.
+
+ If you convey a covered work, knowingly relying on a patent license,
+and the Corresponding Source of the work is not available for anyone
+to copy, free of charge and under the terms of this License, through a
+publicly available network server or other readily accessible means,
+then you must either (1) cause the Corresponding Source to be so
+available, or (2) arrange to deprive yourself of the benefit of the
+patent license for this particular work, or (3) arrange, in a manner
+consistent with the requirements of this License, to extend the patent
+license to downstream recipients. "Knowingly relying" means you have
+actual knowledge that, but for the patent license, your conveying the
+covered work in a country, or your recipient's use of the covered work
+in a country, would infringe one or more identifiable patents in that
+country that you have reason to believe are valid.
+
+ If, pursuant to or in connection with a single transaction or
+arrangement, you convey, or propagate by procuring conveyance of, a
+covered work, and grant a patent license to some of the parties
+receiving the covered work authorizing them to use, propagate, modify
+or convey a specific copy of the covered work, then the patent license
+you grant is automatically extended to all recipients of the covered
+work and works based on it.
+
+ A patent license is "discriminatory" if it does not include within
+the scope of its coverage, prohibits the exercise of, or is
+conditioned on the non-exercise of one or more of the rights that are
+specifically granted under this License. You may not convey a covered
+work if you are a party to an arrangement with a third party that is
+in the business of distributing software, under which you make payment
+to the third party based on the extent of your activity of conveying
+the work, and under which the third party grants, to any of the
+parties who would receive the covered work from you, a discriminatory
+patent license (a) in connection with copies of the covered work
+conveyed by you (or copies made from those copies), or (b) primarily
+for and in connection with specific products or compilations that
+contain the covered work, unless you entered into that arrangement,
+or that patent license was granted, prior to 28 March 2007.
+
+ Nothing in this License shall be construed as excluding or limiting
+any implied license or other defenses to infringement that may
+otherwise be available to you under applicable patent law.
+
+ 12. No Surrender of Others' Freedom.
+
+ If conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot convey a
+covered work so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you may
+not convey it at all. For example, if you agree to terms that obligate you
+to collect a royalty for further conveying from those to whom you convey
+the Program, the only way you could satisfy both those terms and this
+License would be to refrain entirely from conveying the Program.
+
+ 13. Use with the GNU Affero General Public License.
+
+ Notwithstanding any other provision of this License, you have
+permission to link or combine any covered work with a work licensed
+under version 3 of the GNU Affero General Public License into a single
+combined work, and to convey the resulting work. The terms of this
+License will continue to apply to the part which is the covered work,
+but the special requirements of the GNU Affero General Public License,
+section 13, concerning interaction through a network will apply to the
+combination as such.
+
+ 14. Revised Versions of this License.
+
+ The Free Software Foundation may publish revised and/or new versions of
+the GNU General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Program specifies that a certain numbered version of the GNU General
+Public License "or any later version" applies to it, you have the
+option of following the terms and conditions either of that numbered
+version or of any later version published by the Free Software
+Foundation. If the Program does not specify a version number of the
+GNU General Public License, you may choose any version ever published
+by the Free Software Foundation.
+
+ If the Program specifies that a proxy can decide which future
+versions of the GNU General Public License can be used, that proxy's
+public statement of acceptance of a version permanently authorizes you
+to choose that version for the Program.
+
+ Later license versions may give you additional or different
+permissions. However, no additional obligations are imposed on any
+author or copyright holder as a result of your choosing to follow a
+later version.
+
+ 15. Disclaimer of Warranty.
+
+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+ 16. Limitation of Liability.
+
+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
+SUCH DAMAGES.
+
+ 17. Interpretation of Sections 15 and 16.
+
+ If the disclaimer of warranty and limitation of liability provided
+above cannot be given local legal effect according to their terms,
+reviewing courts shall apply local law that most closely approximates
+an absolute waiver of all civil liability in connection with the
+Program, unless a warranty or assumption of liability accompanies a
+copy of the Program in return for a fee.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+state the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+
+ Copyright (C)
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+
+Also add information on how to contact you by electronic and paper mail.
+
+ If the program does terminal interaction, make it output a short
+notice like this when it starts in an interactive mode:
+
+ Copyright (C)
+ This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, your program's commands
+might be different; for a GUI interface, you would use an "about box".
+
+ You should also get your employer (if you work as a programmer) or school,
+if any, to sign a "copyright disclaimer" for the program, if necessary.
+For more information on this, and how to apply and follow the GNU GPL, see
+.
+
+ The GNU General Public License does not permit incorporating your program
+into proprietary programs. If your program is a subroutine library, you
+may consider it more useful to permit linking proprietary applications with
+the library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License. But first, please read
+.
diff --git a/[qb]/qb-spawn/README.md b/[qb]/qb-spawn/README.md
new file mode 100644
index 0000000..cee8219
--- /dev/null
+++ b/[qb]/qb-spawn/README.md
@@ -0,0 +1,61 @@
+# qb-spawn
+Spawn Selector for QB-Core Framework :eagle:
+
+# License
+
+ QBCore Framework
+ Copyright (C) 2021 Joshua Eger
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see
+
+
+## Dependencies
+- [qb-core](https://github.com/qbcore-framework/qb-core)
+- [qb-houses](https://github.com/qbcore-framework/qb-houses) - Lets player select the house
+- [qb-apartment](https://github.com/qbcore-framework/qb-apartment) - Lets player select the apartment
+- [qb-garages](https://github.com/qbcore-framework/qb-garages) - For house garages
+
+## Screenshots
+![Spawn selector](https://i.imgur.com/nz0mPGe.png)
+
+## Features
+- Ability to select spawn after selecting the character
+
+## Installation
+### Manual
+- Download the script and put it in the `[qb]` directory.
+- Add the following code to your server.cfg/resouces.cfg
+```
+ensure qb-core
+ensure qb-spawn
+ensure qb-apartments
+ensure qb-garages
+```
+
+## Configuration
+An example to add spawn option
+```
+QB.Spawns = {
+ ["spawn1"] = { -- Needs to be unique
+ coords = vector4(1.1, -1.1, 1.1, 180.0), -- Coords player will be spawned
+ location = "spawn1", -- Needs to be unique
+ label = "Spawn 1 Name", -- This is the label which will show up in selection menu.
+ },
+ ["spawn2"] = { -- Needs to be unique
+ coords = vector4(1.1, -1.1, 1.1, 180.0), -- Coords player will be spawned
+ location = "spawn2", -- Needs to be unique
+ label = "Spawn 2 Name", -- This is the label which will show up in selection menu.
+ },
+}
+```
diff --git a/[qb]/qb-spawn/client.lua b/[qb]/qb-spawn/client.lua
new file mode 100644
index 0000000..d4da51a
--- /dev/null
+++ b/[qb]/qb-spawn/client.lua
@@ -0,0 +1,228 @@
+local QBCore = exports['qb-core']:GetCoreObject()
+local camZPlus1 = 1500
+local camZPlus2 = 50
+local pointCamCoords = 75
+local pointCamCoords2 = 0
+local cam1Time = 500
+local cam2Time = 1000
+local choosingSpawn = false
+local Houses = {}
+local cam = nil
+local cam2 = nil
+
+-- Functions
+
+local function SetDisplay(bool)
+ local translations = {}
+ for k in pairs(Lang.fallback and Lang.fallback.phrases or Lang.phrases) do
+ if k:sub(0, #'ui.') then
+ translations[k:sub(#'ui.' + 1)] = Lang:t(k)
+ end
+ end
+ choosingSpawn = bool
+ SetNuiFocus(bool, bool)
+ SendNUIMessage({
+ action = "showUi",
+ status = bool,
+ translations = translations
+ })
+end
+
+-- Events
+
+RegisterNetEvent('qb-spawn:client:openUI', function(value)
+ SetEntityVisible(PlayerPedId(), false)
+ DoScreenFadeOut(250)
+ Wait(1000)
+ DoScreenFadeIn(250)
+ QBCore.Functions.GetPlayerData(function(PlayerData)
+ cam = CreateCamWithParams("DEFAULT_SCRIPTED_CAMERA", PlayerData.position.x, PlayerData.position.y, PlayerData.position.z + camZPlus1, -85.00, 0.00, 0.00, 100.00, false, 0)
+ SetCamActive(cam, true)
+ RenderScriptCams(true, false, 1, true, true)
+ end)
+ Wait(500)
+ SetDisplay(value)
+end)
+
+RegisterNetEvent('qb-houses:client:setHouseConfig', function(houseConfig)
+ Houses = houseConfig
+end)
+
+RegisterNetEvent('qb-spawn:client:setupSpawns', function(cData, new, apps)
+ if not new then
+ QBCore.Functions.TriggerCallback('qb-spawn:server:getOwnedHouses', function(houses)
+ local myHouses = {}
+ if houses ~= nil then
+ for i = 1, (#houses), 1 do
+ myHouses[#myHouses+1] = {
+ house = houses[i].house,
+ label = Houses[houses[i].house].adress,
+ }
+ end
+ end
+
+ Wait(500)
+ SendNUIMessage({
+ action = "setupLocations",
+ locations = QB.Spawns,
+ houses = myHouses,
+ isNew = new
+ })
+ end, cData.citizenid)
+ elseif new then
+ SendNUIMessage({
+ action = "setupAppartements",
+ locations = apps,
+ isNew = new
+ })
+ end
+end)
+
+-- NUI Callbacks
+
+RegisterNUICallback("exit", function(_, cb)
+ SetNuiFocus(false, false)
+ SendNUIMessage({
+ action = "showUi",
+ status = false
+ })
+ choosingSpawn = false
+ cb("ok")
+end)
+
+local function SetCam(campos)
+ cam2 = CreateCamWithParams("DEFAULT_SCRIPTED_CAMERA", campos.x, campos.y, campos.z + camZPlus1, 300.00,0.00,0.00, 110.00, false, 0)
+ PointCamAtCoord(cam2, campos.x, campos.y, campos.z + pointCamCoords)
+ SetCamActiveWithInterp(cam2, cam, cam1Time, true, true)
+ if DoesCamExist(cam) then
+ DestroyCam(cam, true)
+ end
+ Wait(cam1Time)
+
+ cam = CreateCamWithParams("DEFAULT_SCRIPTED_CAMERA", campos.x, campos.y, campos.z + camZPlus2, 300.00,0.00,0.00, 110.00, false, 0)
+ PointCamAtCoord(cam, campos.x, campos.y, campos.z + pointCamCoords2)
+ SetCamActiveWithInterp(cam, cam2, cam2Time, true, true)
+ SetEntityCoords(PlayerPedId(), campos.x, campos.y, campos.z)
+end
+
+RegisterNUICallback('setCam', function(data, cb)
+ local location = tostring(data.posname)
+ local type = tostring(data.type)
+ DoScreenFadeOut(200)
+ Wait(500)
+ DoScreenFadeIn(200)
+ if DoesCamExist(cam) then DestroyCam(cam, true) end
+ if DoesCamExist(cam2) then DestroyCam(cam2, true) end
+ if type == "current" then
+ QBCore.Functions.GetPlayerData(function(PlayerData)
+ SetCam(PlayerData.position)
+ end)
+ elseif type == "house" then
+ SetCam(Houses[location].coords.enter)
+ elseif type == "normal" then
+ SetCam(QB.Spawns[location].coords)
+ elseif type == "appartment" then
+ SetCam(Apartments.Locations[location].coords.enter)
+ end
+ cb('ok')
+end)
+
+RegisterNUICallback('chooseAppa', function(data, cb)
+ local ped = PlayerPedId()
+ local appaYeet = data.appType
+ SetDisplay(false)
+ DoScreenFadeOut(500)
+ Wait(5000)
+ TriggerServerEvent("apartments:server:CreateApartment", appaYeet, Apartments.Locations[appaYeet].label)
+ TriggerServerEvent('QBCore:Server:OnPlayerLoaded')
+ TriggerEvent('QBCore:Client:OnPlayerLoaded')
+ FreezeEntityPosition(ped, false)
+ RenderScriptCams(false, true, 500, true, true)
+ SetCamActive(cam, false)
+ DestroyCam(cam, true)
+ SetCamActive(cam2, false)
+ DestroyCam(cam2, true)
+ SetEntityVisible(ped, true)
+ cb('ok')
+end)
+
+local function PreSpawnPlayer()
+ SetDisplay(false)
+ DoScreenFadeOut(500)
+ Wait(2000)
+end
+
+local function PostSpawnPlayer(ped)
+ FreezeEntityPosition(ped, false)
+ RenderScriptCams(false, true, 500, true, true)
+ SetCamActive(cam, false)
+ DestroyCam(cam, true)
+ SetCamActive(cam2, false)
+ DestroyCam(cam2, true)
+ SetEntityVisible(PlayerPedId(), true)
+ Wait(500)
+ DoScreenFadeIn(250)
+end
+
+RegisterNUICallback('spawnplayer', function(data, cb)
+ local location = tostring(data.spawnloc)
+ local type = tostring(data.typeLoc)
+ local ped = PlayerPedId()
+ local PlayerData = QBCore.Functions.GetPlayerData()
+ local insideMeta = PlayerData.metadata["inside"]
+ if type == "current" then
+ PreSpawnPlayer()
+ QBCore.Functions.GetPlayerData(function(pd)
+ ped = PlayerPedId()
+ SetEntityCoords(ped, pd.position.x, pd.position.y, pd.position.z)
+ SetEntityHeading(ped, pd.position.a)
+ FreezeEntityPosition(ped, false)
+ end)
+
+ if insideMeta.house ~= nil then
+ local houseId = insideMeta.house
+ TriggerEvent('qb-houses:client:LastLocationHouse', houseId)
+ elseif insideMeta.apartment.apartmentType ~= nil or insideMeta.apartment.apartmentId ~= nil then
+ local apartmentType = insideMeta.apartment.apartmentType
+ local apartmentId = insideMeta.apartment.apartmentId
+ TriggerEvent('qb-apartments:client:LastLocationHouse', apartmentType, apartmentId)
+ end
+ TriggerServerEvent('QBCore:Server:OnPlayerLoaded')
+ TriggerEvent('QBCore:Client:OnPlayerLoaded')
+ PostSpawnPlayer()
+ elseif type == "house" then
+ PreSpawnPlayer()
+ TriggerEvent('qb-houses:client:enterOwnedHouse', location)
+ TriggerServerEvent('QBCore:Server:OnPlayerLoaded')
+ TriggerEvent('QBCore:Client:OnPlayerLoaded')
+ TriggerServerEvent('qb-houses:server:SetInsideMeta', 0, false)
+ TriggerServerEvent('qb-apartments:server:SetInsideMeta', 0, 0, false)
+ PostSpawnPlayer()
+ elseif type == "normal" then
+ local pos = QB.Spawns[location].coords
+ PreSpawnPlayer()
+ SetEntityCoords(ped, pos.x, pos.y, pos.z)
+ TriggerServerEvent('QBCore:Server:OnPlayerLoaded')
+ TriggerEvent('QBCore:Client:OnPlayerLoaded')
+ TriggerServerEvent('qb-houses:server:SetInsideMeta', 0, false)
+ TriggerServerEvent('qb-apartments:server:SetInsideMeta', 0, 0, false)
+ Wait(500)
+ SetEntityCoords(ped, pos.x, pos.y, pos.z)
+ SetEntityHeading(ped, pos.w)
+ PostSpawnPlayer()
+ end
+ cb('ok')
+end)
+
+-- Threads
+
+CreateThread(function()
+ while true do
+ Wait(0)
+ if choosingSpawn then
+ DisableAllControlActions(0)
+ else
+ Wait(1000)
+ end
+ end
+end)
diff --git a/[qb]/qb-spawn/config.lua b/[qb]/qb-spawn/config.lua
new file mode 100644
index 0000000..11bddc4
--- /dev/null
+++ b/[qb]/qb-spawn/config.lua
@@ -0,0 +1,27 @@
+QB = {}
+
+QB.Spawns = {
+ ["legion"] = {
+ coords = vector4(195.17, -933.77, 29.7, 144.5),
+ location = "legion",
+ label = "Legion Square",
+ },
+
+ ["policedp"] = {
+ coords = vector4(428.23, -984.28, 29.76, 3.5),
+ location = "policedp",
+ label = "Police Department",
+ },
+
+ ["paleto"] = {
+ coords = vector4(80.35, 6424.12, 31.67, 45.5),
+ location = "paleto",
+ label = "Paleto Bay",
+ },
+
+ ["motel"] = {
+ coords = vector4(327.56, -205.08, 53.08, 163.5),
+ location = "motel",
+ label = "Motels",
+ },
+}
\ No newline at end of file
diff --git a/[qb]/qb-spawn/fxmanifest.lua b/[qb]/qb-spawn/fxmanifest.lua
new file mode 100644
index 0000000..fdc8126
--- /dev/null
+++ b/[qb]/qb-spawn/fxmanifest.lua
@@ -0,0 +1,31 @@
+fx_version 'cerulean'
+game 'gta5'
+
+description 'QB-Spawn'
+version '1.2.0'
+
+shared_scripts {
+ '@qb-core/shared/locale.lua',
+ 'locales/en.lua',
+ 'locales/*.lua',
+ 'config.lua',
+ '@qb-apartments/config.lua',
+}
+
+client_script 'client.lua'
+
+server_scripts {
+ '@oxmysql/lib/MySQL.lua',
+ 'server.lua'
+}
+
+ui_page 'html/index.html'
+
+files {
+ 'html/index.html',
+ 'html/style.css',
+ 'html/vue.js',
+ 'html/reset.css'
+}
+
+lua54 'yes'
diff --git a/[qb]/qb-spawn/html/index.html b/[qb]/qb-spawn/html/index.html
new file mode 100644
index 0000000..3060ffb
--- /dev/null
+++ b/[qb]/qb-spawn/html/index.html
@@ -0,0 +1,149 @@
+
+
+
+
+
+ QBCore - Spawnlocation
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/[qb]/qb-spawn/html/reset.css b/[qb]/qb-spawn/html/reset.css
new file mode 100644
index 0000000..f75ecd1
--- /dev/null
+++ b/[qb]/qb-spawn/html/reset.css
@@ -0,0 +1,58 @@
+html, body, div, span, applet, object, iframe,
+h1, h2, h3, h4, h5, h6, p, blockquote, pre,
+a, abbr, acronym, address, big, cite, code,
+del, dfn, em, img, ins, kbd, q, s, samp,
+small, strike, strong, sub, sup, tt, var,
+b, u, i, center,
+dl, dt, dd, ol, ul, li,
+fieldset, form, label, legend,
+table, caption, tbody, tfoot, thead, tr, th, td,
+article, aside, canvas, details, embed,
+figure, figcaption, footer, header, hgroup,
+menu, nav, output, ruby, section, summary,
+time, mark, audio, video {
+ letter-spacing: .1vh;
+ font-weight: 900;
+ color: #ededed;
+ margin: 0;
+ padding: 0;
+ border: 0;
+ font-size: 100%;
+ font: inherit;
+ vertical-align: baseline;
+}
+/* HTML5 display-role reset for older browsers */
+article, aside, details, figcaption, figure,
+footer, header, hgroup, menu, nav, section {
+ display: block;
+}
+body {
+ line-height: 1;
+}
+ol, ul {
+ list-style: none;
+}
+blockquote, q {
+ quotes: none;
+}
+blockquote:before, blockquote:after,
+q:before, q:after {
+ content: '';
+ content: none;
+}
+table {
+ border-collapse: collapse;
+ border-spacing: 0;
+}
+
+.noselect {
+ -webkit-touch-callout: none;
+ -khtml-user-select: none;
+ -moz-user-select: none;
+ -ms-user-select: none;
+ user-select: none;
+}
+
+::-webkit-scrollbar {
+ display: none;
+}
\ No newline at end of file
diff --git a/[qb]/qb-spawn/html/style.css b/[qb]/qb-spawn/html/style.css
new file mode 100644
index 0000000..e6dd0be
--- /dev/null
+++ b/[qb]/qb-spawn/html/style.css
@@ -0,0 +1,85 @@
+@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@200&display=swap');
+
+#app {
+ font-family: 'Poppins', sans-serif;
+}
+
+.spawn-locations {
+ text-transform: uppercase;
+ position: absolute;
+ min-width: 30vh;
+ width: fit-content;
+ max-width: 35vh;
+ top: 10vh;
+ left: 10vh;
+ background-color: #161923f2;
+ border-radius: 5px;
+ box-shadow: rgb(0 0 0 / 16%) 0px 3px 6px, rgb(0 0 0 / 23%) 0px 3px 6px;
+ border-radius: .8vh;
+ padding: 30px;
+ cursor: default;
+ transition: 300ms;
+}
+
+.location {
+ width: 100%;
+ margin-bottom: 15px;
+ transition: 200ms;
+ border-radius: .3vh;
+ cursor: pointer;
+}
+
+.v-btn.location:hover {
+ background-color: #a90d2ca6!important;
+ transition: 300ms;
+}
+
+.v-btn.location .v-btn__content,
+.v-btn.submit-spawn .v-btn__content {
+ font-size: 1.4vh!important;
+ font-weight: 600!important;
+ color: white!important;
+ letter-spacing: 3;
+}
+
+.v-btn.location.selected {
+ background-color: #a90d2ca6!important;
+}
+
+.submit-spawn {
+ background-color: rgb(47 134 67)!important;
+ width: 100%;
+ margin-top: 1.5vh;
+ transition: 0.2s;
+ border-radius: .3vh;
+ cursor: pointer;
+}
+
+.spawn_locations-header {
+ width: 100%;
+ transition: 0.2s;
+ margin-bottom: 17.5px;
+}
+
+.spawn_locations-header > p {
+ font-family: 'Poppins', sans-serif;
+ letter-spacing: 1px;
+ font-weight: bold;
+ position: relative;
+ color: #ededed;
+ text-align: center;
+ font-size: 1.5vh;
+}
+
+
+.slide-top-fade-enter-active {
+ transition: all 0.3s ease-out;
+}
+.slide-top-fade-leave-active {
+ transition: all 0.5s cubic-bezier(1, 0.7, 0.9, 1);
+}
+.slide-top-fade-enter-from,
+.slide-top-fade-leave-to {
+ transform: translateY(-10%);
+ opacity: 0!important;
+}
\ No newline at end of file
diff --git a/[qb]/qb-spawn/html/vue.js b/[qb]/qb-spawn/html/vue.js
new file mode 100644
index 0000000..cc5f445
--- /dev/null
+++ b/[qb]/qb-spawn/html/vue.js
@@ -0,0 +1,5 @@
+/*!
+ * Vue.js v2.7.8
+ * (c) 2014-2022 Evan You
+ * Released under the MIT License.
+*/ !function(b,a){"object"==typeof exports&&"undefined"!=typeof module?module.exports=a():"function"==typeof define&&define.amd?define(a):(b="undefined"!=typeof globalThis?globalThis:b||self).Vue=a()}(this,function(){"use strict";var a9,w,ab,ac,ad,ba,bb,o,ae,af,bc,bd,be,bf,bg,bh,bi,bj,bk,bl,bm,bn,bo,bp,bq,br,bs,bt,bu,bv,bw,bx,by,bz=Object.freeze({}),bA=Array.isArray;function bB(a){return!0===a}function bC(a){return"string"==typeof a||"number"==typeof a||"symbol"==typeof a||"boolean"==typeof a}function bD(a){return"function"==typeof a}function bE(a){return null!==a&&"object"==typeof a}var bF=Object.prototype.toString;function bG(a){return bF.call(a).slice(8,-1)}function bH(a){return"[object Object]"===bF.call(a)}function bI(a){return"[object RegExp]"===bF.call(a)}function bJ(b){var a=parseFloat(String(b));return a>=0&&Math.floor(a)===a&&isFinite(b)}function bK(a){var b;return null!=(b=a)&&"function"==typeof a.then&&"function"==typeof a.catch}function bL(a){return null==a?"":Array.isArray(a)||bH(a)&&a.toString===bF?JSON.stringify(a,null,2):String(a)}function bM(a){var b=parseFloat(a);return isNaN(b)?a:b}function b(c,d){for(var e=Object.create(null),b=c.split(","),a=0;a -1)return a.splice(b,1)}}var bQ=Object.prototype.hasOwnProperty;function bR(a,b){return bQ.call(a,b)}function f(a){var b=Object.create(null);return function(c){return b[c]||(b[c]=a(c))}}var bS=/-(\w)/g,bT=f(function(a){return a.replace(bS,function(_,a){return a?a.toUpperCase():""})}),bU=f(function(a){return a.charAt(0).toUpperCase()+a.slice(1)}),bV=/\B([A-Z])/g,bW=f(function(a){return a.replace(bV,"-$1").toLowerCase()}),bX=Function.prototype.bind?function(a,b){return a.bind(b)}:function(b,c){function a(d){var a=arguments.length;return a?a>1?b.apply(c,arguments):b.call(c,d):b.call(c)}return a._length=b.length,a};function bY(c,a){a=a||0;for(var b=c.length-a,d=new Array(b);b--;)d[b]=c[b+a];return d}function l(a,b){for(var c in b)a[c]=b[c];return a}function bZ(b){for(var c={},a=0;a0,b7=c&&c.indexOf("edge/")>0;c&&c.indexOf("android");var b8=c&&/iphone|ipad|ipod|ios/.test(c);c&&/chrome\/\d+/.test(c),c&&/phantomjs/.test(c);var B=c&&c.match(/firefox\/(\d+)/),b9={}.watch,ca=!1;if(h)try{var C={};Object.defineProperty(C,"passive",{get:function(){ca=!0}}),window.addEventListener("test-passive",null,C)}catch(cb){}var ah=function(){return void 0===a9&&(a9=!h&&"undefined"!=typeof global&&global.process&&"server"===global.process.env.VUE_ENV),a9},cc=h&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__;function k(a){return"function"==typeof a&&/native code/.test(a.toString())}var cd="undefined"!=typeof Symbol&&k(Symbol)&&"undefined"!=typeof Reflect&&k(Reflect.ownKeys);w="undefined"!=typeof Set&&k(Set)?Set:function(){function a(){this.set=Object.create(null)}return a.prototype.has=function(a){return!0===this.set[a]},a.prototype.add=function(a){this.set[a]=!0},a.prototype.clear=function(){this.set=Object.create(null)},a}();var ce=null;function cf(a){void 0===a&&(a=null),!a&&ce&&ce._scope.off(),ce=a,a&&a._scope.on()}var ai=function(){function a(b,a,c,d,e,f,g,h){this.tag=b,this.data=a,this.children=c,this.text=d,this.elm=e,this.ns=void 0,this.context=f,this.fnContext=void 0,this.fnOptions=void 0,this.fnScopeId=void 0,this.key=a&&a.key,this.componentOptions=g,this.componentInstance=void 0,this.parent=void 0,this.raw=!1,this.isStatic=!1,this.isRootInsert=!0,this.isComment=!1,this.isCloned=!1,this.isOnce=!1,this.asyncFactory=h,this.asyncMeta=void 0,this.isAsyncPlaceholder=!1}return Object.defineProperty(a.prototype,"child",{get:function(){return this.componentInstance},enumerable:!1,configurable:!0}),a}(),cg=function(a){void 0===a&&(a="");var b=new ai;return b.text=a,b.isComment=!0,b};function ch(a){return new ai(void 0,void 0,void 0,String(a))}function ci(a){var b=new ai(a.tag,a.data,a.children&&a.children.slice(),a.text,a.elm,a.context,a.componentOptions,a.asyncFactory);return b.ns=a.ns,b.isStatic=a.isStatic,b.key=a.key,b.isComment=a.isComment,b.fnContext=a.fnContext,b.fnOptions=a.fnOptions,b.fnScopeId=a.fnScopeId,b.asyncMeta=a.asyncMeta,b.isCloned=!0,b}var cj=b("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,require"),ck=function(a,b){J('Property or method "'.concat(b,'" is not defined on the instance but ')+"referenced during render. Make sure that this property is reactive, either in the data option, or for class-based components, by initializing the property. See: https://vuejs.org/v2/guide/reactivity.html#Declaring-Reactive-Properties.",a)},cl=function(b,a){J('Property "'.concat(a,'" must be accessed with "$data.').concat(a,'" because ')+'properties starting with "$" or "_" are not proxied in the Vue instance to prevent conflicts with Vue internals. See: https://vuejs.org/v2/api/#data',b)},aj="undefined"!=typeof Proxy&&k(Proxy);if(aj){var cm=b("stop,prevent,self,ctrl,shift,alt,meta,exact");q.keyCodes=new Proxy(q.keyCodes,{set:function(b,a,c){return cm(a)?(J("Avoid overwriting built-in modifier in config.keyCodes: .".concat(a)),!1):(b[a]=c,!0)}})}var cn={has:function(b,a){var c=a in b,d=cj(a)||"string"==typeof a&&"_"===a.charAt(0)&&!(a in b.$data);return c||d||(a in b.$data?cl(b,a):ck(b,a)),c||!d}},co={get:function(b,a){return"string"!=typeof a||a in b||(a in b.$data?cl(b,a):ck(b,a)),b[a]}};ab=function(a){if(aj){var b=a.$options,c=b.render&&b.render._withStripped?co:cn;a._renderProxy=new Proxy(a,c)}else a._renderProxy=a};var cp=function(){return(cp=Object.assign||function(d){for(var a,b=1,e=arguments.length;b0&&(a=cR(a,"".concat(g||"","_").concat(d)),cQ(a[0])&&cQ(c)&&(b[e]=ch(c.text+a[0].text),a.shift()),b.push.apply(b,a)):bC(a)?cQ(c)?b[e]=ch(c.text+a):""!==a&&b.push(ch(a)):cQ(a)&&cQ(c)?b[e]=ch(c.text+a.text):(bB(f._isVList)&&null!=(i=a.tag)&&null==(j=a.key)&&null!=(k=g)&&(a.key="__vlist".concat(g,"_").concat(d,"__")),b.push(a)));return b}var cS=1,cT=2;function cU(d,e,a,b,c,f){return(bA(a)||bC(a))&&(c=b,b=a,a=void 0),bB(f)&&(c=cT),cV(d,e,a,b,c)}function cV(d,c,a,b,g){if(null!=(o=a)&&null!=(p=a.__ob__))return J("Avoid using observed data object as vnode data: ".concat(JSON.stringify(a),"\n")+"Always create fresh vnode data objects in each render!",d),cg();if(null!=(r=a)&&null!=(s=a.is)&&(c=a.is),!c)return cg();if(null==(t=a)||null==(u=a.key)||bC(a.key)||J("Avoid using non-primitive value as key, use string/number value instead.",d),bA(b)&&bD(b[0])&&((a=a||{}).scopedSlots={default:b[0]},b.length=0),g===cT?b=cP(b):g===cS&&(b=function(a){for(var b=0;b."),d),e=new ai(q.parsePlatformTagName(c),a,b,void 0,void 0,d)):e=a&&a.pre||null==(n=h=eB(d.$options,"components",c))?new ai(c,a,b,void 0,void 0,d):em(h,a,d,b,c)}else e=em(c,a,d,b);return bA(e)?e:null!=(i=e)?(null!=(j=f)&&cW(e,f),null!=(k=a)&&cX(a),e):cg()}function cW(a,c,d){var i;if(a.ns=c,"foreignObject"===a.tag&&(c=void 0,d=!0),null!=a.children)for(var e=0,f=a.children.length;e0,h=a?!!a.$stable:!f,i=a&&a.$key;if(a){if(a._normalized)return a._normalized;if(h&&c&&c!==bz&&i===c.$key&&!f&&!c.$hasNormal)return c;for(var d in b={},a)a[d]&&"$"!==d[0]&&(b[d]=de(j,e,d,a[d]))}else b={};for(var g in e)g in b||(b[g]=df(e,g));return a&&Object.isExtensible(a)&&(a._normalized=b),b4(b,"$stable",h),b4(b,"$key",i),b4(b,"$hasNormal",f),b}function de(e,b,c,d){var a=function(){var c=ce;cf(e);var a=arguments.length?d.apply(null,arguments):d({}),b=(a=a&&"object"==typeof a&&!bA(a)?[a]:cP(a))&&a[0];return cf(c),a&&(!b||1===a.length&&b.isComment&&!dc(b))?void 0:a};return d.proxy&&Object.defineProperty(b,c,{get:a,enumerable:!0,configurable:!0}),a}function df(a,b){return function(){return a[b]}}function dg(a){var c=!1;return{get attrs(){if(!a._attrsProxy){var b=a._attrsProxy={};b4(b,"_v_attr_proxy",!0),dh(b,a.$attrs,bz,a,"$attrs")}return a._attrsProxy},get listeners(){return a._listenersProxy||dh(a._listenersProxy={},a.$listeners,bz,a,"$listeners"),a._listenersProxy},get slots(){return dj(a)},emit:bX(a.$emit,a),expose:function(b){c&&J("expose() should be called only once per setup().",a),c=!0,b&&Object.keys(b).forEach(function(c){return cF(a,b,c)})}}}function dh(b,d,e,f,g){var c=!1;for(var a in d)a in b?d[a]!==e[a]&&(c=!0):(c=!0,di(b,a,f,g));for(var a in b)a in d||(c=!0,delete b[a]);return c}function di(a,b,c,d){Object.defineProperty(a,b,{enumerable:!0,configurable:!0,get:function(){return c[d][b]}})}function dj(a){return a._slotsProxy||dk(a._slotsProxy={},a.$scopedSlots),a._slotsProxy}function dk(b,c){for(var a in c)b[a]=c[a];for(var a in b)a in c||delete b[a]}function dl(){ce||J("useContext() called without active instance.");var a=ce;return a._setupContext||(a._setupContext=dg(a))}var dm=null;function dn(a,b){return(a.__esModule||cd&&"Module"===a[Symbol.toStringTag])&&(a=a.default),bE(a)?b.extend(a):a}function dp(b){if(bA(b))for(var c=0;cdocument.createEvent("Event").timeStamp&&(E=function(){return F.now()})}var dK=function(b,a){if(b.post){if(!a.post)return 1}else if(a.post)return -1;return b.id-a.id};function dL(){for(dJ=E(),dH=!0,dC.sort(dK),dI=0;dIdB)){J("You may have an infinite update loop "+(c.user?'in watcher with expression "'.concat(c.expression,'"'):"in a component render function."),c.vm);break}var c,d,a=dD.slice(),b=dC.slice();dI=dC.length=dD.length=0,dE={},dF={},dG=dH=!1,dN(a),dM(b),cc&&q.devtools&&cc.emit("flush")}function dM(b){for(var c=b.length;c--;){var d=b[c],a=d.vm;a&&a._watcher===d&&a._isMounted&&!a._isDestroyed&&dA(a,"updated")}}function dN(b){for(var a=0;adI&&dC[b].id>a.id;)b--;dC.splice(b+1,0,a)}else dC.push(a);if(!dG){if(dG=!0,!q.async){dL();return}G(dL)}}}var t="watcher",dP="".concat(t," callback"),dQ="".concat(t," getter"),dR="".concat(t," cleanup");function aw(a,b){return dT(a,null,cp(cp({},b),{flush:"post"}))}var dS={};function dT(c,d,k){var b,v,e=void 0===k?bz:k,f=e.immediate,h=e.deep,l=e.flush,i=void 0===l?"pre":l,p=e.onTrack,q=e.onTrigger;d||(void 0!==f&&J('watch() "immediate" option is only respected when using the watch(source, callback, options?) signature.'),void 0!==h&&J('watch() "deep" option is only respected when using the watch(source, callback, options?) signature.'));var r=function(a){J("Invalid watch source: ".concat(a,". A watch source can only be a getter/effect ")+"function, a ref, a reactive object, or an array of these types.")},m=ce,s=function(b,c,a){return void 0===a&&(a=null),dW(b,null,a,m,c)},n=!1,j=!1;if(at(c)?(b=function(){return c.value},n=aq(c)):ap(c)?(b=function(){return c.__ob__.dep.depend(),c},h=!0):bA(c)?(j=!0,n=c.some(function(a){return ap(a)||aq(a)}),b=function(){return c.map(function(a){return at(a)?a.value:ap(a)?d3(a):bD(a)?s(a,dQ):void r(a)})}):bD(c)?b=d?function(){return s(c,dQ)}:function(){if(!m||!m._isDestroyed)return v&&v(),s(c,t,[o])}:(b=g,r(c)),d&&h){var w=b;b=function(){return d3(w())}}var o=function(b){v=a.onStop=function(){s(b,dR)}};if(ah())return o=g,d?f&&s(d,dP,[b(),j?[]:void 0,o]):b(),g;var a=new d6(ce,b,g,{lazy:!0});a.noRecurse=!d;var u=j?[]:dS;return a.run=function(){if(a.active||"pre"===i&&m&&m._isBeingDestroyed){if(d){var b=a.get();(h||n||(j?b.some(function(a,b){return b1(a,u[b])}):b1(b,u)))&&(v&&v(),s(d,dP,[b,u===dS?void 0:u,o]),u=b)}else a.get()}},"sync"===i?a.update=a.run:"post"===i?(a.post=!0,a.update=function(){return dO(a)}):a.update=function(){if(m&&m===ce&&!m._isMounted){var b=m._preWatchers||(m._preWatchers=[]);0>b.indexOf(a)&&b.push(a)}else dO(a)},a.onTrack=p,a.onTrigger=q,d?f?a.run():u=a.get():"post"===i&&m?m.$once("hook:mounted",function(){return a.get()}):a.get(),function(){a.teardown()}}var ax=function(){function a(a){void 0===a&&(a=!1),this.active=!0,this.effects=[],this.cleanups=[],!a&&bb&&(this.parent=bb,this.index=(bb.scopes||(bb.scopes=[])).push(this)-1)}return a.prototype.run=function(a){if(this.active){var b=bb;try{return bb=this,a()}finally{bb=b}}else J("cannot run an inactive effect scope.")},a.prototype.on=function(){bb=this},a.prototype.off=function(){bb=this.parent},a.prototype.stop=function(d){if(this.active){var a=void 0,b=void 0;for(a=0,b=this.effects.length;a1)return d&&bD(c)?c.call(a):c;J('injection "'.concat(String(b),'" not found.'))}else J("inject() can only be used inside setup() or functional components.")},h:function(a,b,c){return ce||J("globally imported h() can only be invoked when there is an active component instance, e.g. synchronously in a component's render or setup function."),cU(ce,a,b,c,2,!0)},getCurrentInstance:function(){return ce&&{proxy:ce}},useSlots:function(){return dl().slots},useAttrs:function(){return dl().attrs},useListeners:function(){return dl().listeners},mergeDefaults:function(e,c){var d=bA(e)?e.reduce(function(a,b){return a[b]={},a},{}):e;for(var a in c){var b=d[a];b?bA(b)||bD(b)?d[a]={type:b,default:c[a]}:b.default=c[a]:null===b?d[a]={default:c[a]}:J('props default key "'.concat(a,'" has no corresponding declaration.'))}return d},nextTick:G,set:r,del:s,useCssModule:function(a){return J("useCssModule() is not supported in the global build."),bz},useCssVars:function(b){if(h){var a=ce;if(!a){J("useCssVars is called without current active component instance.");return}aw(function(){var c=a.$el,d=b(a,a._setupProxy);if(c&&1===c.nodeType){var f=c.style;for(var e in d)f.setProperty("--".concat(e),d[e])}})}},defineAsyncComponent:function(a){bD(a)&&(a={loader:a});var e=a.loader,f=a.loadingComponent,g=a.errorComponent,b=a.delay,h=void 0===b?200:b,i=a.timeout,c=a.suspensible,d=void 0!==c&&c,j=a.onError;d&&J("The suspensiblbe option for async components is not supported in Vue2. It is ignored.");var k=null,l=0,m=function(){return l++,k=null,n()},n=function(){var a;return k||(a=k=e().catch(function(a){if(a=a instanceof Error?a:new Error(String(a)),j)return new Promise(function(d,e){var b=function(){return d(m())},c=function(){return e(a)};j(a,b,c,l+1)});throw a}).then(function(b){if(a!==k&&k)return k;if(b||J("Async component loader resolved to undefined. If you are using retry(), make sure to return its return value."),b&&(b.__esModule||"Module"===b[Symbol.toStringTag])&&(b=b.default),b&&!bE(b)&&!bD(b))throw new Error("Invalid async component load result: ".concat(b));return b}))};return function(){return{component:n(),delay:h,timeout:i,error:g,loading:f}}},onBeforeMount:aD,onMounted:aE,onBeforeUpdate:aF,onUpdated:aG,onBeforeUnmount:aH,onUnmounted:aI,onErrorCaptured:aJ,onActivated:aK,onDeactivated:aL,onServerPrefetch:aM,onRenderTracked:aN,onRenderTriggered:aO}),d2=new w;function d3(a){return d4(a,d2),d2.clear(),a}function d4(a,c){var b,d,e=bA(a);if(!(!e&&!bE(a)||Object.isFrozen(a))&&!(a instanceof ai)){if(a.__ob__){var f=a.__ob__.dep.id;if(c.has(f))return;c.add(f)}if(e)for(b=a.length;b--;)d4(a[b],c);else if(at(a))d4(a.value,c);else for(b=(d=Object.keys(a)).length;b--;)d4(a[d[b]],c)}}var d5=0,d6=function(){function a(b,c,f,a,h){var e,d;e=this,void 0===(d=bb||(b?b._scope:void 0))&&(d=bb),d&&d.active&&d.effects.push(e),(this.vm=b)&&h&&(b._watcher=this),a?(this.deep=!!a.deep,this.user=!!a.user,this.lazy=!!a.lazy,this.sync=!!a.sync,this.before=a.before,this.onTrack=a.onTrack,this.onTrigger=a.onTrigger):this.deep=this.user=this.lazy=this.sync=!1,this.cb=f,this.id=++d5,this.active=!0,this.post=!1,this.dirty=this.lazy,this.deps=[],this.newDeps=[],this.depIds=new w,this.newDepIds=new w,this.expression=c.toString(),bD(c)?this.getter=c:(this.getter=function(a){if(!b5.test(a)){var b=a.split(".");return function(a){for(var c=0;c";var g,d=bD(a)&&null!=a.cid?a.options:a._isVue?a.$options||a.constructor.options:a,b=ek(d),c=d.__file;if(!b&&c){var e=c.match(/([^/\\]+)\.vue$/);b=e&&e[1]}return(b?"<".concat(b.replace(es,function(a){return a.toUpperCase()}).replace(/[-_]/g,""),">"):"")+(c&& !1!==f?" at ".concat(c):"")};var et=function(b,a){for(var c="";a;)a%2==1&&(c+=b),a>1&&(b+=b),a>>=1;return c};ae=function(a){if(!a._isVue||!a.$parent)return"\n\n(found in ".concat(af(a),")");for(var b=[],c=0;a;){if(b.length>0){var d=b[b.length-1];if(d.constructor===a.constructor){c++,a=a.$parent;continue}c>0&&(b[b.length-1]=[d,c],c=0)}b.push(a),a=a.$parent}return"\n\nfound in\n\n"+b.map(function(a,b){return"".concat(0===b?"---> ":et(" ",5+2*b)).concat(bA(a)?"".concat(af(a[0]),"... (").concat(a[1]," recursive calls)"):af(a))}).join("\n")};var i=q.optionMergeStrategies;function eu(a,d){if(!d)return a;for(var b,e,c,g=cd?Reflect.ownKeys(d):Object.keys(d),f=0;f -1){if(f&&!bR(c,"default"))a=!1;else if(""===a||a===bW(b)){var h=eK(String,c.type);(h<0||g -1:"string"==typeof a?a.split(",").indexOf(b)> -1:!!bI(a)&&a.test(b)}function eS(a,f){var b=a.cache,g=a.keys,h=a._vnode;for(var c in b){var d=b[c];if(d){var e=d.name;e&&!f(e)&&eT(b,c,g,h)}}}function eT(c,a,e,d){var b=c[a];b&&(!d||b.tag!==d.tag)&&b.componentInstance.$destroy(),c[a]=null,bP(e,a)}a.prototype._init=function(h){var k,l,i,s,b,j,d,t,m,n,e,c,o,f,p,u,v,r,a=this;a._uid=ef++,q.performance&&ac&&(k="vue-perf-start:".concat(a._uid),l="vue-perf-end:".concat(a._uid),ac(k)),a._isVue=!0,a.__v_skip=!0,a._scope=new ax(!0),h&&h._isComponent?(n=a,e=h,c=n.$options=Object.create(n.constructor.options),o=e._parentVnode,c.parent=e.parent,c._parentVnode=o,f=o.componentOptions,c.propsData=f.propsData,c._parentListeners=f.listeners,c._renderChildren=f.children,c._componentTag=f.tag,e.render&&(c.render=e.render,c.staticRenderFns=e.staticRenderFns)):a.$options=aU(eg(a.constructor),h||{},a),ab(a),a._self=a,function(a){var c=a.$options,b=c.parent;if(b&&!c.abstract){for(;b.$options.abstract&&b.$parent;)b=b.$parent;b.$children.push(a)}a.$parent=b,a.$root=b?b.$root:a,a.$children=[],a.$refs={},a._provided=b?b._provided:Object.create(null),a._watcher=null,a._inactive=null,a._directInactive=!1,a._isMounted=!1,a._isDestroyed=!1,a._isBeingDestroyed=!1}(a),(i=a)._events=Object.create(null),i._hasHookEvent=!1,(s=i.$options._parentListeners)&&dt(i,s),(b=a)._vnode=null,b._staticTrees=null,j=b.$options,d=b.$vnode=j._parentVnode,t=d&&d.context,b.$slots=da(j._renderChildren,t),b.$scopedSlots=d?dd(b.$parent,d.data.scopedSlots,b.$slots):bz,b._c=function(a,c,d,e){return cU(b,a,c,d,e,!1)},b.$createElement=function(a,c,d,e){return cU(b,a,c,d,e,!0)},m=d&&d.data,an(b,"$attrs",m&&m.attrs||bz,function(){dv||J("$attrs is readonly.",b)},!0),an(b,"$listeners",j._parentListeners||bz,function(){dv||J("$listeners is readonly.",b)},!0),dA(a,"beforeCreate",void 0,!1),p=a,r=ee(p.$options.inject,p),r&&(cw=!1,Object.keys(r).forEach(function(a){an(p,a,r[a],function(){J("Avoid mutating an injected value directly since the changes will be overwritten whenever the provided component re-renders. "+'injection being mutated: "'.concat(a,'"'),p)})}),cw=!0),function(b){var a=b.$options;if(a.props&&function(a,b){var f,g,h=a.$options.propsData||{},i=a._props=ao({}),j=a.$options._propKeys=[],c=!a.$parent;c||(cw=!1);var d=function(d){j.push(d);var f=eC(d,b,h,a),e=bW(d);(bO(e)||q.isReservedAttr(e))&&J('"'.concat(e,'" is a reserved attribute and cannot be used as component prop.'),a),an(i,d,f,function(){c||dv||J("Avoid mutating a prop directly since the value will be overwritten whenever the parent component re-renders. Instead, use a data or computed property based on the prop's "+'value. Prop being mutated: "'.concat(d,'"'),a)}),d in a||d8(a,"_props",d)};for(var e in b)d(e);cw=!0}(b,a.props),function(b){var d=b.$options,e=d.setup;if(e){var f=b._setupContext=dg(b);cf(b),cs();var a=dW(e,null,[b._props||ao({}),f],b,"setup");if(ct(),cf(),bD(a))d.render=a;else if(bE(a)){if(a instanceof ai&&J("setup() should not return VNodes directly - return a render function instead."),b._setupState=a,a.__sfc){var g=b._setupProxy={};for(var c in a)"__sfc"!==c&&cF(g,a,c)}else for(var c in a)b3(c)?J("Avoid using variables that start with _ or $ in setup()."):cF(b,a,c)}else void 0!==a&&J("setup() should return an object. Received: ".concat(null===a?"null":typeof a))}}(b),a.methods&&function(b,c){var d=b.$options.props;for(var a in c)"function"!=typeof c[a]&&J('Method "'.concat(a,'" has type "').concat(typeof c[a],'" in the component definition. ')+"Did you reference the function correctly?",b),d&&bR(d,a)&&J('Method "'.concat(a,'" has already been defined as a prop.'),b),a in b&&b3(a)&&J('Method "'.concat(a,'" conflicts with an existing Vue instance method. ')+"Avoid defining component methods that start with _ or $."),b[a]="function"!=typeof c[a]?g:bX(c[a],b)}(b,a.methods),a.data)(function(a){var b=a.$options.data;b=a._data=bD(b)?function d(b,a){cs();try{return b.call(a,a)}catch(c){return dV(c,a,"data()"),{}}finally{ct()}}(b,a):b||{},bH(b)||(b={},J("data functions should return an object:\nhttps://vuejs.org/v2/guide/components.html#data-Must-Be-a-Function",a));for(var d=Object.keys(b),e=a.$options.props,f=a.$options.methods,g=d.length;g--;){var c=d[g];f&&bR(f,c)&&J('Method "'.concat(c,'" has already been defined as a data property.'),a),e&&bR(e,c)?J('The data property "'.concat(c,'" is already declared as a prop. ')+"Use prop default value instead.",a):b3(c)||d8(a,"_data",c)}var h=cz(b);h&&h.vmCount++})(b);else{var c=cz(b._data={});c&&c.vmCount++}a.computed&&function(a,d){var f=a._computedWatchers=Object.create(null),h=ah();for(var b in d){var c=d[b],e=bD(c)?c:c.get;null==e&&J('Getter is missing for computed property "'.concat(b,'".'),a),h||(f[b]=new d6(a,e||g,g,d9)),b in a?b in a.$data?J('The computed property "'.concat(b,'" is already defined in data.'),a):a.$options.props&&b in a.$options.props?J('The computed property "'.concat(b,'" is already defined as a prop.'),a):a.$options.methods&&b in a.$options.methods&&J('The computed property "'.concat(b,'" is already defined as a method.'),a):ea(a,b,c)}}(b,a.computed),a.watch&&a.watch!==b9&&function(d,e){for(var b in e){var a=e[b];if(bA(a))for(var c=0;c1?bY(b):b;for(var e=bY(arguments,1),f='event handler for "'.concat(a,'"'),d=0,g=b.length;dparseInt(this.max)&&eT(c,a[0],a,this._vnode),this.vnodeToCache=null}}},created:function(){this.cache=Object.create(null),this.keys=[]},destroyed:function(){for(var a in this.cache)eT(this.cache,a,this.keys)},mounted:function(){var a=this;this.cacheVNode(),this.$watch("include",function(b){eS(a,function(a){return eR(b,a)})}),this.$watch("exclude",function(b){eS(a,function(a){return!eR(b,a)})})},updated:function(){this.cacheVNode()},render:function(){var e=this.$slots.default,a=dp(e),b=a&&a.componentOptions;if(b){var d=eQ(b),f=this,g=f.include,h=f.exclude;if(g&&(!d||!eR(g,d))||h&&d&&eR(h,d))return a;var i=this,j=i.cache,k=i.keys,c=null==a.key?b.Ctor.cid+(b.tag?"::".concat(b.tag):""):a.key;j[c]?(a.componentInstance=j[c].componentInstance,bP(k,c),k.push(c)):(this.vnodeToCache=a,this.keyToCache=c),a.data.keepAlive=!0}return a||e&&e[0]}}}),d.use=function(a){var c=this._installedPlugins||(this._installedPlugins=[]);if(c.indexOf(a)> -1)return this;var b=bY(arguments,1);return b.unshift(this),bD(a.install)?a.install.apply(a,b):bD(a)&&a.apply(null,b),c.push(a),this},d.mixin=function(a){return this.options=aU(this.options,a),this},(K=d).cid=0,aV=1,K.extend=function(c){c=c||{};var b=this,e=b.cid,f=c._Ctor||(c._Ctor={});if(f[e])return f[e];var d=ek(c)||ek(b.options);d&&ez(d);var a=function(a){this._init(a)};return a.prototype=Object.create(b.prototype),a.prototype.constructor=a,a.cid=aV++,a.options=aU(b.options,c),a.super=b,a.options.props&&function(a){var b=a.options.props;for(var c in b)d8(a.prototype,"_props",c)}(a),a.options.computed&&function(a){var b=a.options.computed;for(var c in b)ea(a.prototype,c,b[c])}(a),a.extend=b.extend,a.mixin=b.mixin,a.use=b.use,p.forEach(function(c){a[c]=b[c]}),d&&(a.options.components[d]=a),a.superOptions=b.options,a.extendOptions=c,a.sealedOptions=l({},a.options),f[e]=a,a},aW=d,p.forEach(function(a){aW[a]=function(c,b){return b?("component"===a&&ez(c),"component"===a&&bH(b)&&(b.name=b.name||c,b=this.options._base.extend(b)),"directive"===a&&bD(b)&&(b={bind:b,update:b}),this.options[a+"s"][c]=b,b):this.options[a+"s"][c]}}),Object.defineProperty(a.prototype,"$isServer",{get:ah}),Object.defineProperty(a.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Object.defineProperty(a,"FunctionalRenderContext",{value:I}),a.version=H;var aX=b("style,class"),e2=b("input,textarea,option,select,progress"),M=function(a,c,b){return"value"===b&&e2(a)&&"button"!==c||"selected"===b&&"option"===a||"checked"===b&&"input"===a||"muted"===b&&"video"===a},e3=b("contenteditable,draggable,spellcheck"),e4=b("events,caret,typing,plaintext-only"),e5=b("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,truespeed,typemustmatch,visible"),e6="http://www.w3.org/1999/xlink",e7=function(a){return":"===a.charAt(5)&&"xlink"===a.slice(0,5)},e8=function(a){return e7(a)?a.slice(6,a.length):""},e9=function(a){return null==a|| !1===a};function fa(a,b){var c;return{staticClass:fb(a.staticClass,b.staticClass),class:null!=(c=a.class)?[a.class,b.class]:b.class}}function fb(a,b){return a?b?a+" "+b:a:b||""}function fc(a){return Array.isArray(a)?fd(a):bE(a)?fe(a):"string"==typeof a?a:""}function fd(d){for(var e,b,a="",c=0,f=d.length;c -1)fy(b,a,c);else if(e5(a))e9(c)?b.removeAttribute(a):(c="allowfullscreen"===a&&"EMBED"===b.tagName?"true":a,b.setAttribute(a,c));else if(e3(a)){var e,d;b.setAttribute(a,(e=a,e9(d=c)||"false"===d?"false":"contenteditable"===e&&e4(d)?d:"true"))}else e7(a)?e9(c)?b.removeAttributeNS(e6,e8(a)):b.setAttributeNS(e6,a,c):fy(b,a,c)}function fy(a,b,c){if(e9(c))a.removeAttribute(b);else{if(z&&!A&&"TEXTAREA"===a.tagName&&"placeholder"===b&&""!==c&&!a.__ieph){var d=function(b){b.stopImmediatePropagation(),a.removeEventListener("input",d)};a.addEventListener("input",d),a.__ieph=!0}a.setAttribute(b,c)}}function R(g,c){var h,i,j,k,l,b=c.elm,e=c.data,d=g.data;if(null!=(h=e.staticClass)||null!=(i=e.class)||null!=(j=d)&&(null!=(k=d.staticClass)||null!=(l=d.class))){var m,a=function(d){for(var g,h,e,f,i,j,a=d.data,b=d,c=d;null!=(g=c.componentInstance);)(c=c.componentInstance._vnode)&&c.data&&(a=fa(c.data,a));for(;null!=(h=b=b.parent);)b&&b.data&&(a=fa(a,b.data));return e=a.staticClass,f=a.class,null!=(i=e)||null!=(j=f)?fb(e,fc(f)):""}(c),f=b._transitionClasses;null!=(m=f)&&(a=fb(a,fc(f))),a!==b._prevClass&&(b.setAttribute("class",a),b._prevClass=a)}}var fz=/[\w).+\-_$\]]/;function fA(c){var b,e,a,d,f,g=!1,h=!1,i=!1,j=!1,k=0,l=0,m=0,p=0;for(a=0;a=0&&" "===(o=c.charAt(n));n--);o&&fz.test(o)||(j=!0)}}else void 0===d?(p=a+1,d=c.slice(0,a).trim()):q();function q(){(f||(f=[])).push(c.slice(p,a).trim()),p=a+1}if(void 0===d?d=c.slice(0,a).trim():0!==p&&q(),f)for(a=0;aa.indexOf("[")||a.lastIndexOf("]") -1?{exp:a.slice(0,bf),key:'"'+a.slice(bf+1)+'"'}:{exp:a,key:null};for(bd=a,bf=bg=bh=0;!fT();)fU(be=fS())?fW(be):91===be&&fV(be);return{exp:a.slice(0,bg),key:a.slice(bg+1,bh)}}function fS(){return bd.charCodeAt(++bf)}function fT(){return bf>=bc}function fU(a){return 34===a||39===a}function fV(a){var b=1;for(bg=bf;!fT();){if(fU(a=fS())){fW(a);continue}if(91===a&&b++,93===a&&b--,0===b){bh=bf;break}}}function fW(a){for(var b=a;!fT()&&(a=fS())!==b;);}function fX(a,b,c){var d=bj;return function e(){var f=b.apply(null,arguments);null!==f&&f$(a,e,c,d)}}var fY=u&&!(B&&53>=Number(B[1]));function fZ(c,a,b,d){if(fY){var f=dJ,e=a;a=e._wrapper=function(a){if(a.target===a.currentTarget||a.timeStamp>=f||a.timeStamp<=0||a.target.ownerDocument!==document)return e.apply(this,arguments)}}bj.addEventListener(c,a,ca?{capture:b,passive:d}:b)}function f$(b,a,c,d){(d||bj).removeEventListener(b,a._wrapper||a,c)}function S(b,a){var d,e;if(null!=(d=b.data.on)||null!=(e=a.data.on)){var c=a.data.on||{},f=b.data.on||{};bj=a.elm||b.elm,function(a){if(null!=(d=a["__r"])){var d,c,b=z?"change":"input";a[b]=[].concat(a["__r"],a[b]||[]),delete a["__r"]}null!=(c=a["__c"])&&(a.change=[].concat(a["__c"],a.change||[]),delete a["__c"])}(c),cM(c,f,fZ,f$,fX,a.context),bj=void 0}}function T(g,e){var j,k;if(null!=(j=g.data.domProps)||null!=(k=e.data.domProps)){var b,c,m,a=e.elm,f=g.data.domProps||{},d=e.data.domProps||{};for(b in(null!=(m=d.__ob__)||bB(d._v_attr_proxy))&&(d=e.data.domProps=l({},d)),f)b in d||(a[b]="");for(b in d){if(c=d[b],"textContent"===b||"innerHTML"===b){if(e.children&&(e.children.length=0),c===f[b])continue;1===a.childNodes.length&&a.removeChild(a.childNodes[0])}if("value"===b&&"PROGRESS"!==a.tagName){a._value=c;var n,o,h=null==(o=c)?"":String(c);f_(a,h)&&(a.value=h)}else if("innerHTML"===b&&fh(a.tagName)&&null==(n=a.innerHTML)){(bk=bk||document.createElement("div")).innerHTML="");for(var i=bk.firstChild;a.firstChild;)a.removeChild(a.firstChild);for(;i.firstChild;)a.appendChild(i.firstChild)}else if(c!==f[b])try{a[b]=c}catch(p){}}}}function f_(a,b){return!a.composing&&("OPTION"===a.tagName||f0(a,b)||f1(a,b))}function f0(a,c){var b=!0;try{b=document.activeElement!==a}catch(d){}return b&&a.value!==c}function f1(d,a){var e,b=d.value,c=d._vModifiers;if(null!=(e=c)){if(c.number)return bM(b)!==bM(a);if(c.trim)return b.trim()!==a.trim()}return b!==a}var f2=f(function(a){var b={},c=/:(.+)/;return a.split(/;(?![^(]*\))/g).forEach(function(d){if(d){var a=d.split(c);a.length>1&&(b[a[0].trim()]=a[1].trim())}}),b});function f3(a){var b=f4(a.style);return a.staticStyle?l(a.staticStyle,b):b}function f4(a){return Array.isArray(a)?bZ(a):"string"==typeof a?f2(a):a}var f5=/^--/,f6=/\s*!important$/,f7=function(b,c,a){if(f5.test(c))b.style.setProperty(c,a);else if(f6.test(a))b.style.setProperty(bW(c),a.replace(f6,""),"important");else{var e=f9(c);if(Array.isArray(a))for(var d=0,f=a.length;d -1?a.split(ga).forEach(function(a){return b.classList.add(a)}):b.classList.add(a);else{var c=" ".concat(b.getAttribute("class")||""," ");0>c.indexOf(" "+a+" ")&&b.setAttribute("class",(c+a).trim())}}}function gc(a,b){if(b&&(b=b.trim())){if(a.classList)b.indexOf(" ")> -1?b.split(ga).forEach(function(b){return a.classList.remove(b)}):a.classList.remove(b),a.classList.length||a.removeAttribute("class");else{for(var c=" ".concat(a.getAttribute("class")||""," "),d=" "+b+" ";c.indexOf(d)>=0;)c=c.replace(d," ");(c=c.trim())?a.setAttribute("class",c):a.removeAttribute("class")}}}function gd(a){if(a){if("object"==typeof a){var b={};return!1!==a.css&&l(b,ge(a.name||"v")),l(b,a),b}if("string"==typeof a)return ge(a)}}var ge=f(function(a){return{enterClass:"".concat(a,"-enter"),enterToClass:"".concat(a,"-enter-to"),enterActiveClass:"".concat(a,"-enter-active"),leaveClass:"".concat(a,"-leave"),leaveToClass:"".concat(a,"-leave-to"),leaveActiveClass:"".concat(a,"-leave-active")}}),aZ=h&&!A,gf="transition",gg="animation",a$="transition",a_="transitionend",a0="animation",a1="animationend";aZ&&(void 0===window.ontransitionend&& void 0!==window.onwebkittransitionend&&(a$="WebkitTransition",a_="webkitTransitionEnd"),void 0===window.onanimationend&& void 0!==window.onwebkitanimationend&&(a0="WebkitAnimation",a1="webkitAnimationEnd"));var gh=h?window.requestAnimationFrame?window.requestAnimationFrame.bind(window):setTimeout:function(a){return a()};function gi(a){gh(function(){gh(a)})}function gj(a,b){var c=a._transitionClasses||(a._transitionClasses=[]);0>c.indexOf(b)&&(c.push(b),gb(a,b))}function gk(a,b){a._transitionClasses&&bP(a._transitionClasses,b),gc(a,b)}function gl(b,d,e){var a=gn(b,d),c=a.type,f=a.timeout,i=a.propCount;if(!c)return e();var g=c===gf?a_:a1,j=0,k=function(){b.removeEventListener(g,h),e()},h=function(a){a.target===b&& ++j>=i&&k()};setTimeout(function(){j0&&(a=gf,e=c,f=g.length):i===gg?d>0&&(a=gg,e=d,f=h.length):f=(a=(e=Math.max(c,d))>0?c>d?gf:gg:null)?a===gf?g.length:h.length:0;var m=a===gf&&gm.test(b[a$+"Property"]);return{type:a,timeout:e,propCount:f,hasTransform:m}}function go(a,b){for(;a.length explicit ".concat(b," duration is not a valid number - ")+"got ".concat(JSON.stringify(a),"."),c.context):isNaN(a)&&J(" explicit ".concat(b," duration is NaN - ")+"the duration expression might be incorrect.",c.context)}function gt(a){return"number"==typeof a&&!isNaN(a)}function gu(a){if(null==(d=a))return!1;var d,c,b=a.fns;return null!=(c=b)?gu(Array.isArray(b)?b[0]:b):(a._length||a.length)>1}function V(_,a){!0!==a.data.show&&gq(a)}var a2=[{create:Q,update:Q},{create:R,update:R},{create:S,update:S,destroy:function(a){return S(a,fn)}},{create:T,update:T},{create:U,update:U},h?{create:V,activate:V,remove:function(a,b){!0!==a.data.show?gr(a,b):b()}}:{}].concat([{create:function(_,a){fl(a)},update:function(a,b){a.data.ref!==b.data.ref&&(fl(a,!0),fl(b))},destroy:function(a){fl(a,!0)}},{create:P,update:P,destroy:function(a){P(a,fn)}}]),a3=function(e){var g,a,c,f={},d=e.modules,h=e.nodeOps;for(a=0;a - did you register the component correctly? For recursive components, make sure to provide the "name" option.',a.context),a.elm=a.ns?h.createElementNS(a.ns,e):h.createElement(e,a),u(a),r(a,v,f),null!=(s=b)&&t(a,f),p(c,a.elm,d),b&&b.pre&&k--):bB(a.isComment)?(a.elm=h.createComment(a.text),p(c,a.elm,d)):(a.elm=h.createTextNode(a.text),p(c,a.elm,d))}}function m(a,c,d,e){var f,b=a.data;if(null!=(f=b)){var g,h,i,k,j=null!=(g=a.componentInstance)&&b.keepAlive;if(null!=(h=b=b.hook)&&null!=(i=b=b.init)&&b(a,!1),null!=a.componentInstance)return n(a,c),p(d,a.elm,e),bB(j)&&o(a,c,d,e),!0}}function n(a,b){var c;null!=(c=a.data.pendingInsert)&&(b.push.apply(b,a.data.pendingInsert),a.data.pendingInsert=null),a.elm=a.componentInstance.$el,s(a)?(t(a,b),u(a)):(fl(a),b.push(a))}function o(c,d,e,g){for(var h,i,a,b=c;b.componentInstance;)if(null!=(h=a=(b=b.componentInstance._vnode).data)&&null!=(i=a=a.transition)){for(a=0;ai?v(m,null==(D=a[g+1])?null:a[g+1].elm,a,e,g,j):e>g&&x(b,k,i)}(i,g,d,j,n):null!=(u=d)?(z(d),null!=(w=c.text)&&h.setTextContent(i,""),v(i,null,d,0,d.length-1,j)):null!=(y=g)?x(g,0,g.length-1):null!=(C=c.text)&&h.setTextContent(i,""):c.text!==a.text&&h.setTextContent(i,a.text),null!=(D=e)&&null!=(E=b=e.hook)&&null!=(G=b=b.postpatch)&&b(c,a)}}function C(c,a,d){var e;if(bB(d)&&null!=(e=c.parent))c.parent.data.pendingInsert=a;else for(var b=0;b, or missing . Bailing hydration and performing full client-side render.")}a=(e=a,new ai(h.tagName(e).toLowerCase(),{},[],void 0,e))}var v,y,E,g=a.elm,q=h.parentNode(g);if(l(b,d,g._leaveCb?null:q,h.nextSibling(g)),null!=b.parent)for(var c=b.parent,z=s(b);c;){for(var i=0;i ')+"expects an Array value for its binding, but got ".concat(Object.prototype.toString.call(d).slice(8,-1)),h);return}for(var c=0,i=a.options.length;c -1,b.selected!==e&&(b.selected=e);else if(b$(gy(b),d)){a.selectedIndex!==c&&(a.selectedIndex=c);return}f||(a.selectedIndex=-1)}function gx(b,a){return a.every(function(a){return!b$(a,b)})}function gy(a){return"_value"in a?a._value:a.value}function gz(a){a.target.composing=!0}function gA(a){a.target.composing&&(a.target.composing=!1,gB(a.target,"input"))}function gB(b,c){var a=document.createEvent("HTMLEvents");a.initEvent(c,!0,!0),b.dispatchEvent(a)}function gC(a){return!a.componentInstance||a.data&&a.data.transition?a:gC(a.componentInstance._vnode)}var W={name:String,appear:Boolean,css:Boolean,mode:String,type:String,enterClass:String,leaveClass:String,enterToClass:String,leaveToClass:String,enterActiveClass:String,leaveActiveClass:String,appearClass:String,appearActiveClass:String,appearToClass:String,duration:[Number,String,Object]};function gD(a){var b=a&&a.componentOptions;return b&&b.Ctor.options.abstract?gD(dp(b.children)):a}function gE(c){var b={},d=c.$options;for(var a in d.propsData)b[a]=c[a];var e=d._parentListeners;for(var a in e)b[bT(a)]=e[a];return b}function gF(b,a){if(/\d-keep-alive$/.test(a.tag))return b("keep-alive",{props:a.componentOptions.propsData})}var gG=function(a){return a.tag||dc(a)},gH=function(a){return"show"===a.name},X=l({tag:String,moveClass:String},W);function gI(a){a.elm._moveCb&&a.elm._moveCb(),a.elm._enterCb&&a.elm._enterCb()}function gJ(a){a.data.newPos=a.elm.getBoundingClientRect()}function gK(a){var c=a.data.pos,d=a.data.newPos,e=c.left-d.left,f=c.top-d.top;if(e||f){a.data.moved=!0;var b=a.elm.style;b.transform=b.WebkitTransform="translate(".concat(e,"px,").concat(f,"px)"),b.transitionDuration="0s"}}delete X.mode,a.config.mustUseProp=M,a.config.isReservedTag=N,a.config.isReservedAttr=aX,a.config.getTagNamespace=O,a.config.isUnknownElement=function(a){if(!h)return!0;if(N(a))return!1;if(null!=fi[a=a.toLowerCase()])return fi[a];var b=document.createElement(a);return a.indexOf("-")> -1?fi[a]=b.constructor===window.HTMLUnknownElement||b.constructor===window.HTMLElement:fi[a]=/HTMLUnknownElement/.test(b.toString())},l(a.options.directives,{model:a4,show:{bind:function(b,d,a){var c=d.value,e=(a=gC(a)).data&&a.data.transition,f=b.__vOriginalDisplay="none"===b.style.display?"":b.style.display;c&&e?(a.data.show=!0,gq(a,function(){b.style.display=f})):b.style.display=c?f:"none"},update:function(c,d,a){var b=d.value;!b!= !d.oldValue&&((a=gC(a)).data&&a.data.transition?(a.data.show=!0,b?gq(a,function(){c.style.display=c.__vOriginalDisplay}):gr(a,function(){c.style.display="none"})):c.style.display=b?c.__vOriginalDisplay:"none")},unbind:function(a,c,d,e,b){b||(a.style.display=a.__vOriginalDisplay)}}}),l(a.options.components,{Transition:{name:"transition",props:W,abstract:!0,render:function(i){var o=this,e=this.$slots.default;if(e&&(e=e.filter(gG)).length){e.length>1&&J(" can only be used on a single element. Use for lists.",this.$parent);var c=this.mode;c&&"in-out"!==c&&"out-in"!==c&&J("invalid mode: "+c,this.$parent);var d=e[0];if(function(a){for(;a=a.parent;)if(a.data.transition)return!0}(this.$vnode))return d;var a=gD(d);if(!a)return d;if(this._leaving)return gF(i,d);var f="__transition-".concat(this._uid,"-");a.key=null==a.key?a.isComment?f+"comment":f+a.tag:bC(a.key)?0===String(a.key).indexOf(f)?a.key:f+a.key:a.key;var g,j,h=(a.data||(a.data={})).transition=gE(this),k=this._vnode,b=gD(k);if(a.data.directives&&a.data.directives.some(gH)&&(a.data.show=!0),b&&b.data&&(g=a,(j=b).key!==g.key||j.tag!==g.tag)&&!dc(b)&&!(b.componentInstance&&b.componentInstance._vnode.isComment)){var m=b.data.transition=l({},h);if("out-in"===c)return this._leaving=!0,cN(m,"afterLeave",function(){o._leaving=!1,o.$forceUpdate()}),gF(i,d);if("in-out"===c){if(dc(a))return k;var p,n=function(){p()};cN(h,"afterEnter",n),cN(h,"enterCancelled",n),cN(m,"delayLeave",function(a){p=a})}}return d}}},TransitionGroup:{props:X,beforeMount:function(){var a=this,b=this._update;this._update=function(c,d){var e=dw(a);a.__patch__(a._vnode,a.kept,!1,!0),a._vnode=a.kept,e(),b.call(a,c,d)}},render:function(e){for(var f=this.tag||this.$vnode.data.tag||"span",g=Object.create(null),c=this.prevChildren=this.children,h=this.$slots.default||[],i=this.children=[],j=gE(this),b=0;b children must be keyed: <".concat(m,">"))}}}if(c){for(var k=[],l=[],b=0;bb&&(f.push(d=a.slice(b,g)),e.push(JSON.stringify(d)));var j=fA(c[1].trim());e.push("_s(".concat(j,")")),f.push({"@binding":j}),b=g+c[0].length}return b\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,gR=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+?\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,Y="[a-zA-Z_][\\-\\.0-9_a-zA-Z".concat(y.source,"]*"),Z="((?:".concat(Y,"\\:)?").concat(Y,")"),gS=new RegExp("^<".concat(Z)),gT=/^\s*(\/?)>/,gU=new RegExp("^<\\/".concat(Z,"[^>]*>")),gV=/^]+>/i,gW=/^",""":'"',"&":"&","
":"\n"," ":" ","'":"'"},g_=/&(?:lt|gt|quot|amp|#39);/g,g0=/&(?:lt|gt|quot|amp|#39|#10|#9);/g,g1=b("pre,textarea",!0),g2=function(a,b){return a&&g1(a)&&"\n"===b[0]};function g3(a,b){return a.replace(b?g0:g_,function(a){return g$[a]})}var g4=/^@|^v-on:/,g5=/^v-|^@|^:|^#/,g6=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,g7=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,g8=/^\(|\)$/g,g9=/^\[.*\]$/,ha=/:(.*)$/,hb=/^:|^\.|^v-bind:/,hc=/\.[^.\]]+(?=[^\]]*$)/g,hd=/^v-slot(:|$)|^#/,he=/[\r\n]/,hf=/[ \f\t\r\n]+/g,hg=/[\s"'<>\/=]/,hh=f(function(a){return(bm=bm||document.createElement("div")).innerHTML=a,bm.textContent}),hi="_empty_";function hj(b,a,c){return{type:1,tag:b,attrsList:a,attrsMap:hx(a),rawAttrsMap:{},parent:c,children:[]}}function hk(a,c){hl(a),a.plain=!a.key&&!a.scopedSlots&&!a.attrsList.length,hm(a),hq(a),hs(a),ht(a);for(var b=0;b cannot be keyed. Place the key on real elements instead.",fK(a,"key")),a.for){var c=a.iterator2||a.iterator1,d=a.parent;c&&c===b&&d&&"transition-group"===d.tag&&bn("Do not use v-for index as key on children, this is the same as not using keys.",fK(a,"key"),!0)}a.key=b}}function hm(a){var b=fL(a,"ref");b&&(a.ref=b,a.refInFor=hv(a))}function hn(a){var b;if(b=fM(a,"v-for")){var c=ho(b);c?l(a,c):bn("Invalid v-for expression: ".concat(b),a.rawAttrsMap["v-for"])}}function ho(e){var c=e.match(g6);if(c){var a={};a.for=c[2].trim();var d=c[1].trim().replace(g8,""),b=d.match(g7);return b?(a.alias=d.replace(g7,"").trim(),a.iterator1=b[1].trim(),b[2]&&(a.iterator2=b[2].trim())):a.alias=d,a}}function hp(a,b){a.ifConditions||(a.ifConditions=[]),a.ifConditions.push(b)}function hq(a){"template"===a.tag?((k=fM(a,"scope"))&&bn('the "scope" attribute for scoped slots have been deprecated and replaced by "slot-scope" since 2.5. The new "slot-scope" attribute can also be used on plain elements in addition to to denote scoped slots.',a.rawAttrsMap.scope,!0),a.slotScope=k||fM(a,"slot-scope")):(k=fM(a,"slot-scope"))&&(a.attrsMap["v-for"]&&bn("Ambiguous combined usage of slot-scope and v-for on <".concat(a.tag,"> ")+"(v-for takes higher priority). Use a wrapper for the scoped slot to make it clearer.",a.rawAttrsMap["slot-scope"],!0),a.slotScope=k);var k,c=fL(a,"slot");if(c&&(a.slotTarget='""'===c?'"default"':c,a.slotTargetDynamic=!!(a.attrsMap[":slot"]||a.attrsMap["v-bind:slot"]),"template"===a.tag||a.slotScope||fF(a,"slot",c,fK(a,"slot"))),"template"===a.tag){var b=fN(a,hd);if(b){(a.slotTarget||a.slotScope)&&bn("Unexpected mixed usage of different slot syntaxes.",a),a.parent&&!bv(a.parent)&&bn(" can only appear at the root level inside the receiving component",a);var f=hr(b),i=f.name,e=f.dynamic;a.slotTarget=i,a.slotTargetDynamic=e,a.slotScope=b.value||hi}}else{var b=fN(a,hd);if(b){bv(a)||bn("v-slot can only be used on components or .",b),(a.slotScope||a.slotTarget)&&bn("Unexpected mixed usage of different slot syntaxes.",a),a.scopedSlots&&bn("To avoid scope ambiguity, the default slot should also use syntax when there are other named slots.",b);var j=a.scopedSlots||(a.scopedSlots={}),g=hr(b),h=g.name,e=g.dynamic,d=j[h]=hj("template",[],a);d.slotTarget=h,d.slotTargetDynamic=e,d.children=a.children.filter(function(a){if(!a.slotScope)return a.parent=d,!0}),d.slotScope=b.value||hi,a.children=[],a.plain=!1}}}function hr(b){var a=b.name.replace(hd,"");return a||("#"!==b.name[0]?a="default":bn("v-slot shorthand syntax requires a slot name.",b)),g9.test(a)?{name:a.slice(1,-1),dynamic:!0}:{name:'"'.concat(a,'"'),dynamic:!1}}function hs(a){"slot"===a.tag&&(a.slotName=fL(a,"name"),a.key&&bn("`key` does not work on because slots are abstract outlets and can possibly expand into multiple elements. Use the key on a wrapping element instead.",fK(a,"key")))}function ht(a){var b;(b=fL(a,"is"))&&(a.component=b),null!=fM(a,"inline-template")&&(a.inlineTemplate=!0)}function hu(b){var c,j,a,k,d,g,i,f,e=b.attrsList;for(c=0,j=e.length;c, use
.',e[c]),fF(b,a,JSON.stringify(d),e[c]),!b.component&&"muted"===a&&bt(b.tag,b.attrsMap.type,a)&&fE(b,a,"true",e[c])}function hv(b){for(var a=b;a;){if(void 0!==a.for)return!0;a=a.parent}return!1}function hw(b){var a=b.match(hc);if(a){var c={};return a.forEach(function(a){c[a.slice(1)]=!0}),c}}function hx(b){for(var c={},a=0,d=b.length;a: ')+"You are binding v-model directly to a v-for iteration alias. This will not be able to modify the v-for source array because writing to the alias is like modifying a function local variable. Consider using an array of objects and use v-model on an object property instead.",b.rawAttrsMap["v-model"]),a=a.parent}function hB(a){return hj(a.tag,a.attrsList.slice(),a.parent)}var hC,$=[{staticKeys:["staticClass"],transformNode:function(a,c){var e=c.warn||fC,b=fM(a,"class");b&&gO(b,c.delimiters)&&e('class="'.concat(b,'": ')+'Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of
, use
.',a.rawAttrsMap.class),b&&(a.staticClass=JSON.stringify(b.replace(/\s+/g," ").trim()));var d=fL(a,"class",!1);d&&(a.classBinding=d)},genData:function(a){var b="";return a.staticClass&&(b+="staticClass:".concat(a.staticClass,",")),a.classBinding&&(b+="class:".concat(a.classBinding,",")),b}},{staticKeys:["staticStyle"],transformNode:function(a,c){var e=c.warn||fC,b=fM(a,"style");b&&(gO(b,c.delimiters)&&e('style="'.concat(b,'": ')+'Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of
, use
.',a.rawAttrsMap.style),a.staticStyle=JSON.stringify(f2(b)));var d=fL(a,"style",!1);d&&(a.styleBinding=d)},genData:function(a){var b="";return a.staticStyle&&(b+="staticStyle:".concat(a.staticStyle,",")),a.styleBinding&&(b+="style:(".concat(a.styleBinding,"),")),b}},{preTransformNode:function(b,g){if("input"===b.tag){var d=b.attrsMap;if(d["v-model"]){var c=void 0;if((d[":type"]||d["v-bind:type"])&&(c=fL(b,"type")),d.type||c||!d["v-bind"]||(c="(".concat(d["v-bind"],").type")),c){var h=fM(b,"v-if",!0),i=h?"&&(".concat(h,")"):"",k=null!=fM(b,"v-else",!0),j=fM(b,"v-else-if",!0),a=hB(b);hn(a),fG(a,"type","checkbox"),hk(a,g),a.processed=!0,a.if="(".concat(c,")==='checkbox'")+i,hp(a,{exp:a.if,block:a});var e=hB(b);fM(e,"v-for",!0),fG(e,"type","radio"),hk(e,g),hp(a,{exp:"(".concat(c,")==='radio'")+i,block:e});var f=hB(b);return fM(f,"v-for",!0),fG(f,":type",c),hk(f,g),hp(a,{exp:h,block:f}),k?a.else=!0:j&&(a.elseif=j),a}}}}}],a7={expectHTML:!0,modules:$,directives:{model:function(a,n,z){bi=z;var o,p,r,s,t,k,e,b,u,v,h,i,w,j,l,x,y,f,c=n.value,g=n.modifiers,d=a.tag,m=a.attrsMap.type;if("input"===d&&"file"===m&&bi("<".concat(a.tag,' v-model="').concat(c,'" type="file">:\n')+"File inputs are read only. Use a v-on:change listener instead.",a.rawAttrsMap["v-model"]),a.component)return fP(a,c,g),!1;if("select"===d)o=a,p=c,s=(r=g)&&r.number,t='Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = "_value" in o ? o._value : o.value;'+"return ".concat(s?"_n(val)":"val","})"),k="var $$selectedVal = ".concat(t,";"),fJ(o,"change",k="".concat(k," ").concat(fQ(p,"$event.target.multiple ? $$selectedVal : $$selectedVal[0]")),null,!0);else if("input"===d&&"checkbox"===m)e=a,b=c,v=(u=g)&&u.number,h=fL(e,"value")||"null",i=fL(e,"true-value")||"true",w=fL(e,"false-value")||"false",fE(e,"checked","Array.isArray(".concat(b,")")+"?_i(".concat(b,",").concat(h,")>-1")+("true"===i?":(".concat(b,")"):":_q(".concat(b,",").concat(i,")"))),fJ(e,"change","var $$a=".concat(b,",")+"$$el=$event.target,"+"$$c=$$el.checked?(".concat(i,"):(").concat(w,");")+"if(Array.isArray($$a)){"+"var $$v=".concat(v?"_n("+h+")":h,",")+"$$i=_i($$a,$$v);"+"if($$el.checked){$$i<0&&(".concat(fQ(b,"$$a.concat([$$v])"),")}")+"else{$$i>-1&&(".concat(fQ(b,"$$a.slice(0,$$i).concat($$a.slice($$i+1))"),")}")+"}else{".concat(fQ(b,"$$c"),"}"),null,!0);else if("input"===d&&"radio"===m)j=a,l=c,y=(x=g)&&x.number,f=fL(j,"value")||"null",f=y?"_n(".concat(f,")"):f,fE(j,"checked","_q(".concat(l,",").concat(f,")")),fJ(j,"change",fQ(l,f),null,!0);else if("input"===d||"textarea"===d)!function(a,e,l){var f=a.attrsMap.type,g=a.attrsMap["v-bind:value"]||a.attrsMap[":value"],m=a.attrsMap["v-bind:type"]||a.attrsMap[":type"];if(g&&!m){var h=a.attrsMap["v-bind:value"]?"v-bind:value":":value";bi("".concat(h,'="').concat(g,'" conflicts with v-model on the same element ')+"because the latter already expands to a value binding internally",a.rawAttrsMap[h])}var c=l||{},i=c.lazy,j=c.number,k=c.trim,b="$event.target.value";k&&(b="$event.target.value.trim()"),j&&(b="_n(".concat(b,")"));var d=fQ(e,b);i||"range"===f||(d="if($event.target.composing)return;".concat(d)),fE(a,"value","(".concat(e,")")),fJ(a,i?"change":"range"===f?"__r":"input",d,null,!0),(k||j)&&fJ(a,"blur","$forceUpdate()")}(a,c,g);else{if(!q.isReservedTag(d))return fP(a,c,g),!1;bi("<".concat(a.tag,' v-model="').concat(c,'">: ')+"v-model is not supported on this element type. If you are working with contenteditable, it's recommended to wrap a library dedicated for that purpose inside a custom component.",a.rawAttrsMap["v-model"])}return!0},text:function(b,a){a.value&&fE(b,"textContent","_s(".concat(a.value,")"),a)},html:function(b,a){a.value&&fE(b,"innerHTML","_s(".concat(a.value,")"),a)}},isPreTag:function(a){return"pre"===a},isUnaryTag:a5,mustUseProp:M,canBeLeftOpenTag:a6,isReservedTag:N,getTagNamespace:O,staticKeys:$.reduce(function(a,b){return a.concat(b.staticKeys||[])},[]).join(",")},hD=f(function(a){return b("type,tag,attrsList,attrsMap,plain,parent,children,attrs,start,end,rawAttrsMap"+(a?","+a:""))});function hE(a){if(a.static=hG(a),1===a.type&&(bx(a.tag)||"slot"===a.tag||null!=a.attrsMap["inline-template"])){for(var b=0,c=a.children.length;b|^function(?:\s+[\w$]+)?\s*\(/,hJ=/\([^)]*?\);*$/,hK=/^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['[^']*?']|\["[^"]*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*$/,hL={esc:27,tab:9,enter:13,space:32,up:38,left:37,right:39,down:40,delete:[8,46]},hM={esc:["Esc","Escape"],tab:"Tab",enter:"Enter",space:[" ","Spacebar"],up:["Up","ArrowUp"],left:["Left","ArrowLeft"],right:["Right","ArrowRight"],down:["Down","ArrowDown"],delete:["Backspace","Delete","Del"]},j=function(a){return"if(".concat(a,")return null;")},hN={stop:"$event.stopPropagation();",prevent:"$event.preventDefault();",self:j("$event.target !== $event.currentTarget"),ctrl:j("!$event.ctrlKey"),shift:j("!$event.shiftKey"),alt:j("!$event.altKey"),meta:j("!$event.metaKey"),left:j("'button' in $event && $event.button !== 0"),middle:j("'button' in $event && $event.button !== 1"),right:j("'button' in $event && $event.button !== 2")};function hO(c,g){var e=g?"nativeOn:":"on:",a="",d="";for(var b in c){var f=hP(c[b]);c[b]&&c[b].dynamic?d+="".concat(b,",").concat(f,","):a+='"'.concat(b,'":').concat(f,",")}return(a="{".concat(a.slice(0,-1),"}"),d)?e+"_d(".concat(a,",[").concat(d.slice(0,-1),"])"):e+a}function hP(a){if(!a)return"function(){}";if(Array.isArray(a))return"[".concat(a.map(function(a){return hP(a)}).join(","),"]");var c=hK.test(a.value),d=hI.test(a.value),e=hK.test(a.value.replace(hJ,""));if(a.modifiers){var b="",f="",g=[],h=function(b){if(hN[b])f+=hN[b],hL[b]&&g.push(b);else if("exact"===b){var c=a.modifiers;f+=j(["ctrl","shift","alt","meta"].filter(function(a){return!c[a]}).map(function(a){return"$event.".concat(a,"Key")}).join("||"))}else g.push(b)};for(var i in a.modifiers)h(i);g.length&&(b+=hQ(g)),f&&(b+=f);var k=c?"return ".concat(a.value,".apply(null, arguments)"):d?"return (".concat(a.value,").apply(null, arguments)"):e?"return ".concat(a.value):a.value;return"function($event){".concat(b).concat(k,"}")}return c||d?a.value:"function($event){".concat(e?"return ".concat(a.value):a.value,"}")}function hQ(a){return"if(!$event.type.indexOf('key')&&"+"".concat(a.map(hR).join("&&"),")return null;")}function hR(a){var b=parseInt(a,10);if(b)return"$event.keyCode!==".concat(b);var c=hL[a],d=hM[a];return"_k($event.keyCode,"+"".concat(JSON.stringify(a),",")+"".concat(JSON.stringify(c),",")+"$event.key,"+"".concat(JSON.stringify(d))+")"}var hS={on:function(a,b){b.modifiers&&J("v-on without argument does not support modifiers."),a.wrapListeners=function(a){return"_g(".concat(a,",").concat(b.value,")")}},bind:function(a,b){a.wrapData=function(c){return"_b(".concat(c,",'").concat(a.tag,"',").concat(b.value,",").concat(b.modifiers&&b.modifiers.prop?"true":"false").concat(b.modifiers&&b.modifiers.sync?",true":"",")")}},cloak:g},hT=function(a){this.options=a,this.warn=a.warn||fC,this.transforms=fD(a.modules,"transformCode"),this.dataGenFns=fD(a.modules,"genData"),this.directives=l(l({},hS),a.directives);var b=a.isReservedTag||n;this.maybeComponent=function(a){return!!a.component||!b(a.tag)},this.onceId=0,this.staticRenderFns=[],this.pre=!1};function hU(a,c){var b=new hT(c),d=a?"script"===a.tag?"null":hV(a,b):'_c("div")';return{render:"with(this){return ".concat(d,"}"),staticRenderFns:b.staticRenderFns}}function hV(a,b){if(a.parent&&(a.pre=a.pre||a.parent.pre),a.staticRoot&&!a.staticProcessed)return hX(a,b);if(a.once&&!a.onceProcessed)return hY(a,b);if(a.for&&!a.forProcessed)return h_(a,b);if(a.if&&!a.ifProcessed)return hZ(a,b);if("template"===a.tag&&!a.slotTarget&&!b.pre)return h7(a,b)||"void 0";if("slot"===a.tag)return id(a,b);var c=void 0;if(a.component)c=ie(a.component,a,b);else{var e=void 0,h=b.maybeComponent(a);(!a.plain||a.pre&&h)&&(e=h0(a,b));var d=void 0,f=b.options.bindings;h&&f&& !1!==f.__isScriptSetup&&(d=hW(f,a.tag)),d||(d="'".concat(a.tag,"'"));var i=a.inlineTemplate?null:h7(a,b,!0);c="_c(".concat(d).concat(e?",".concat(e):"").concat(i?",".concat(i):"",")")}for(var g=0;g: component lists rendered with ')+"v-for should have explicit keys. See https://vuejs.org/guide/list.html#key for more info.",a.rawAttrsMap["v-for"],!0),a.forProcessed=!0,"".concat(f||"_l","((").concat(c,"),")+"function(".concat(d).concat(g).concat(h,"){")+"return ".concat((e||hV)(a,b))+"})"}function h0(a,c){var b="{",e=h1(a,c);e&&(b+=e+","),a.key&&(b+="key:".concat(a.key,",")),a.ref&&(b+="ref:".concat(a.ref,",")),a.refInFor&&(b+="refInFor:true,"),a.pre&&(b+="pre:true,"),a.component&&(b+='tag:"'.concat(a.tag,'",'));for(var d=0;d>>0}function h5(a){return 1===a.type&&("slot"===a.tag||a.children.some(h5))}function h6(a,b){var c=a.attrsMap["slot-scope"];if(a.if&&!a.ifProcessed&&!c)return hZ(a,b,h6,"null");if(a.for&&!a.forProcessed)return h_(a,b,h6);var d=a.slotScope===hi?"":String(a.slotScope),e="function(".concat(d,"){")+"return ".concat("template"===a.tag?a.if&&c?"(".concat(a.if,")?").concat(h7(a,b)||"undefined",":undefined"):h7(a,b)||"undefined":hV(a,b),"}");return"{key:".concat(a.slotTarget||'"default"',",fn:").concat(e).concat(d?"":",proxy:true","}")}function h7(f,c,d,g,h){var a=f.children;if(a.length){var b=a[0];if(1===a.length&&b.for&&"template"!==b.tag&&"slot"!==b.tag){var i=d?c.maybeComponent(b)?",1":",0":"";return"".concat((g||hV)(b,c)).concat(i)}var e=d?h8(a,c.maybeComponent):0,j=h||ia;return"[".concat(a.map(function(a){return j(a,c)}).join(","),"]").concat(e?",".concat(e):"")}}function h8(d,e){for(var b=0,c=0;c0)for(;1&b&&(c+=a),!((b>>>=1)<=0);)a+=a;return c}function iu(a,b){try{return new Function(a)}catch(c){return b.push({err:c,code:a}),g}}var a8=(function(a){return function(e){var c,d;function b(i,b){var c=Object.create(e),k=[],m=[],g=function(a,c,b){(b?m:k).push(a)};if(b){if(b.outputSourceRange){var n=i.match(/^\s*/)[0].length;g=function(b,a,d){var c="string"==typeof b?{msg:b}:b;a&&(null!=a.start&&(c.start=a.start+n),null!=a.end&&(c.end=a.end+n)),(d?m:k).push(c)}}for(var d in b.modules&&(c.modules=(e.modules||[]).concat(b.modules)),b.directives&&(c.directives=l(Object.create(e.directives||null),b.directives)),b)"modules"!==d&&"directives"!==d&&(c[d]=b[d])}c.warn=g;var h,j,f=a(i.trim(),c);return h=f.ast,j=g,h&&il(h,j),f.errors=k,f.tips=m,f}return{compile:b,compileToFunctions:(c=b,d=Object.create(null),function(e,b,j){var f=(b=l({},b)).warn||J;delete b.warn;try{new Function("return 1")}catch(k){k.toString().match(/unsafe-eval|CSP/)&&f("It seems you are using the standalone build of Vue.js in an environment with Content Security Policy that prohibits unsafe-eval. The template compiler cannot work in this environment. Consider relaxing the policy to allow unsafe-eval or pre-compiling your templates into render functions.")}var g=b.delimiters?String(b.delimiters)+e:e;if(d[g])return d[g];var a=c(e,b);a.errors&&a.errors.length&&(b.outputSourceRange?a.errors.forEach(function(a){f("Error compiling template:\n\n".concat(a.msg,"\n\n")+function(i,e,b){void 0===e&&(e=0),void 0===b&&(b=i.length);for(var f=i.split(/\r?\n/),c=0,g=[],d=0;d=e){for(var a=d-is;a<=d+is||b>c;a++)if(!(a<0)&&!(a>=f.length)){g.push("".concat(a+1).concat(it(" ",3-String(a+1).length),"| ").concat(f[a]));var h=f[a].length;if(a===d){var j=e-(c-h)+1,k=b>c?h-j:b-e;g.push(" | "+it(" ",j)+it("^",k))}else if(a>d){if(b>c){var l=Math.min(b-c,h);g.push(" | "+it("^",l))}c+=h+1}}break}return g.join("\n")}(e,a.start,a.end),j)}):f("Error compiling template:\n\n".concat(e,"\n\n")+a.errors.map(function(a){return"- ".concat(a)}).join("\n")+"\n",j)),a.tips&&a.tips.length&&(b.outputSourceRange?a.tips.forEach(function(a){return aS(a.msg,j)}):a.tips.forEach(function(a){return aS(a,j)}));var h={},i=[];return h.render=iu(a.render,i),h.staticRenderFns=a.staticRenderFns.map(function(a){return iu(a,i)}),a.errors&&a.errors.length||!i.length||f("Failed to generate render function:\n\n"+i.map(function(a){var b=a.err,c=a.code;return"".concat(b.toString()," in\n\n").concat(c,"\n")}).join("\n"),j),d[g]=h})}}})(function(f,a){var b,c,d=function(b,a){bn=a.warn||fC,bs=a.isPreTag||n,bt=a.mustUseProp||n,bu=a.getTagNamespace||n;var c,d,e=a.isReservedTag||n;bv=function(a){return!!(a.component||a.attrsMap[":is"]||a.attrsMap["v-bind:is"]||!(a.attrsMap.is?e(a.attrsMap.is):e(a.tag)))},bp=fD(a.modules,"transformNode"),bq=fD(a.modules,"preTransformNode"),br=fD(a.modules,"postTransformNode"),bo=a.delimiters;var f=[],g=!1!==a.preserveWhitespace,h=a.whitespace,i=!1,j=!1,k=!1;function l(a,b){k||(k=!0,bn(a,b))}function m(b){if(o(b),i||b.processed||(b=hk(b,a)),f.length||b===c||(c.if&&(b.elseif||b.else)?(p(b),hp(c,{exp:b.elseif,block:b})):l("Component template should contain exactly one root element. If you are using v-if on multiple elements, use v-else-if to chain them instead.",{start:b.start})),d&&!b.forbidden){if(b.elseif||b.else){var e,k,g;e=b,(g=function c(a){for(var b=a.length;b--;){if(1===a[b].type)return a[b];" "!==a[b].text&&bn('text "'.concat(a[b].text.trim(),'" between v-if and v-else(-if) ')+"will be ignored.",a[b]),a.pop()}}((k=d).children))&&g.if?hp(g,{exp:e.elseif,block:e}):bn("v-".concat(e.elseif?'else-if="'+e.elseif+'"':"else"," ")+"used on element <".concat(e.tag,"> without corresponding v-if."),e.rawAttrsMap[e.elseif?"v-else-if":"v-else"])}else{if(b.slotScope){var m=b.slotTarget||'"default"';(d.scopedSlots||(d.scopedSlots={}))[m]=b}d.children.push(b),b.parent=d}}b.children=b.children.filter(function(a){return!a.slotScope}),o(b),b.pre&&(i=!1),bs(b.tag)&&(j=!1);for(var h=0;h as component root element because it may ")+"contain multiple nodes.",{start:a.start}),a.attrsMap.hasOwnProperty("v-for")&&l("Cannot use v-for on stateful component root element because it renders multiple elements.",a.rawAttrsMap["v-for"])}return!function(b,a){for(var d,e,f=[],g=a.expectHTML,h=a.isUnaryTag||n,i=a.canBeLeftOpenTag||n,j=0;b&&"break"!==function(){if(d=b,e&&gY(e)){var u=0,n=e.toLowerCase(),v=gZ[n]||(gZ[n]=new RegExp("([\\s\\S]*?)("+n+"[^>]*>)","i")),g=b.replace(v,function(d,b,c){return u=c.length,gY(n)||"noscript"===n||(b=b.replace(//g,"$1").replace(//g,"$1")),g2(n,b)&&(b=b.slice(1)),a.chars&&a.chars(b),""});j+=b.length-g.length,b=g,c(n,j-u,j)}else{var h=b.indexOf("<");if(0===h){if(gW.test(b)){var o=b.indexOf("-->");if(o>=0)return a.shouldKeepComment&&a.comment&&a.comment(b.substring(4,o),j,j+o+3),k(o+3),"continue"}if(gX.test(b)){var r=b.indexOf("]>");if(r>=0)return k(r+2),"continue"}var s=b.match(gV);if(s)return k(s[0].length),"continue";var p=b.match(gU);if(p){var w=j;return k(p[0].length),c(p[1],w,j),"continue"}var q=l();if(q)return m(q),g2(q.tagName,b)&&k(1),"continue"}var i=void 0,g=void 0,t=void 0;if(h>=0){for(g=b.slice(h);!gU.test(g)&&!gS.test(g)&&!gW.test(g)&&!gX.test(g)&&!((t=g.indexOf("<",1))<0);)h+=t,g=b.slice(h);i=b.substring(0,h)}h<0&&(i=b),i&&k(i.length),a.chars&&i&&a.chars(i,j-i.length,j)}if(b===d)return a.chars&&a.chars(b),!f.length&&a.warn&&a.warn('Mal-formatted tag at end of template: "'.concat(b,'"'),{start:j+b.length}),"break"}(););function k(a){j+=a,b=b.substring(a)}function l(){var e=b.match(gS);if(e){var c={tagName:e[1],attrs:[],start:j};k(e[0].length);for(var d=void 0,a=void 0;!(d=b.match(gT))&&(a=b.match(gR)||b.match(gQ));)a.start=j,k(a[0].length),a.end=j,c.attrs.push(a);if(d)return c.unarySlash=d[1],k(d[0].length),c.end=j,c}}function m(d){var b=d.tagName,o=d.unarySlash;g&&("p"===e&&gP(b)&&c(e),i(b)&&e===b&&c(b));for(var m=h(b)||!!o,n=d.attrs.length,l=new Array(n),k=0;k=0&&f[b].lowerCasedTag!==i;b--);else b=0;if(b>=0){for(var c=f.length-1;c>=b;c--)(c>b||!d)&&a.warn&&a.warn("tag <".concat(f[c].tag,"> has no matching end tag."),{start:f[c].start,end:f[c].end}),a.end&&a.end(f[c].tag,g,h);f.length=b,e=b&&f[b-1].tag}else"br"===i?a.start&&a.start(d,[],!0,g,h):"p"===i&&(a.start&&a.start(d,[],!1,g,h),a.end&&a.end(d,g,h))}c()}(b,{warn:bn,expectHTML:a.expectHTML,isUnaryTag:a.isUnaryTag,canBeLeftOpenTag:a.canBeLeftOpenTag,shouldDecodeNewlines:a.shouldDecodeNewlines,shouldDecodeNewlinesForHref:a.shouldDecodeNewlinesForHref,shouldKeepComment:a.comments,outputSourceRange:a.outputSourceRange,start:function(h,e,q,r,s){var n,o,k=d&&d.ns||bu(h);z&&"svg"===k&&(e=function(c){for(var d=[],b=0;b, / or =.",a.outputSourceRange?{start:b.start+b.name.indexOf("["),end:b.start+b.name.length}:void 0)}),"style"!==(g=b).tag&&("script"!==g.tag||g.attrsMap.type&&"text/javascript"!==g.attrsMap.type)||ah()||(b.forbidden=!0,bn("Templates should only be responsible for mapping the state to the UI. Avoid placing tags with side-effects in your templates, such as "+"<".concat(h,">")+", as they will not be parsed.",{start:b.start}));for(var l=0;l':'',by.innerHTML.indexOf("
")>0}var iv=!!h&&aa(!1),iw=!!h&&aa(!0),ix=f(function(b){var a=fk(b);return a&&a.innerHTML}),iy=a.prototype.$mount;return a.prototype.$mount=function(b,e){if((b=b&&fk(b))===document.body||b===document.documentElement)return J("Do not mount Vue to or - mount to normal elements instead."),this;var c=this.$options;if(!c.render){var a=c.template;if(a){if("string"==typeof a)"#"!==a.charAt(0)||(a=ix(a))||J("Template element not found or is empty: ".concat(c.template),this);else{if(!a.nodeType)return J("invalid template option:"+a,this),this;a=a.innerHTML}}else b&&(a=function(a){if(a.outerHTML)return a.outerHTML;var b=document.createElement("div");return b.appendChild(a.cloneNode(!0)),b.innerHTML}(b));if(a){q.performance&&ac&&ac("compile");var d=a8(a,{outputSourceRange:!0,shouldDecodeNewlines:iv,shouldDecodeNewlinesForHref:iw,delimiters:c.delimiters,comments:c.comments},this),f=d.render,g=d.staticRenderFns;c.render=f,c.staticRenderFns=g,q.performance&&ac&&(ac("compile end"),ad("vue ".concat(this._name," compile"),"compile","compile end"))}}return iy.call(this,b,e)},a.compile=a8,l(a,aQ),a.effect=function(a,b){var c=new d6(ce,a,g,{sync:!0});b&&(c.update=function(){b(function(){return c.run()})})},a})
\ No newline at end of file
diff --git a/[qb]/qb-spawn/locales/en.lua b/[qb]/qb-spawn/locales/en.lua
new file mode 100644
index 0000000..90985b5
--- /dev/null
+++ b/[qb]/qb-spawn/locales/en.lua
@@ -0,0 +1,12 @@
+local Translations = {
+ ui = {
+ last_location = "Last Location",
+ confirm = "Confirm",
+ where_would_you_like_to_start = "Where would you like to start?",
+ }
+}
+
+Lang = Lang or Locale:new({
+ phrases = Translations,
+ warnOnMissing = true
+})
\ No newline at end of file
diff --git a/[qb]/qb-spawn/locales/es.lua b/[qb]/qb-spawn/locales/es.lua
new file mode 100644
index 0000000..0670249
--- /dev/null
+++ b/[qb]/qb-spawn/locales/es.lua
@@ -0,0 +1,15 @@
+local Translations = {
+ ui = {
+ last_location = "Última ubicación",
+ confirm = "Confirmar",
+ where_would_you_like_to_start = "¿Por dónde te gustarÃa empezar?",
+ }
+}
+
+if GetConvar('qb_locale', 'en') == 'es' then
+ Lang = Locale:new({
+ phrases = Translations,
+ warnOnMissing = true,
+ fallbackLang = Lang,
+ })
+end
\ No newline at end of file
diff --git a/[qb]/qb-spawn/locales/pt.lua b/[qb]/qb-spawn/locales/pt.lua
new file mode 100644
index 0000000..afc0aea
--- /dev/null
+++ b/[qb]/qb-spawn/locales/pt.lua
@@ -0,0 +1,15 @@
+local Translations = {
+ ui = {
+ last_location = "Última localização",
+ confirm = "Confirmar",
+ where_would_you_like_to_start = "Onde gostaria de começar?",
+ }
+}
+
+if GetConvar('qb_locale', 'en') == 'pt' then
+ Lang = Locale:new({
+ phrases = Translations,
+ warnOnMissing = true,
+ fallbackLang = Lang,
+ })
+end
diff --git a/[qb]/qb-spawn/server.lua b/[qb]/qb-spawn/server.lua
new file mode 100644
index 0000000..84e793a
--- /dev/null
+++ b/[qb]/qb-spawn/server.lua
@@ -0,0 +1,14 @@
+local QBCore = exports['qb-core']:GetCoreObject()
+
+QBCore.Functions.CreateCallback('qb-spawn:server:getOwnedHouses', function(_, cb, cid)
+ if cid ~= nil then
+ local houses = MySQL.query.await('SELECT * FROM player_houses WHERE citizenid = ?', {cid})
+ if houses[1] ~= nil then
+ cb(houses)
+ else
+ cb({})
+ end
+ else
+ cb({})
+ end
+end)
diff --git a/[qb]/qb-storerobbery/.github/ISSUE_TEMPLATE/bug_report.md b/[qb]/qb-storerobbery/.github/ISSUE_TEMPLATE/bug_report.md
new file mode 100644
index 0000000..62f702f
--- /dev/null
+++ b/[qb]/qb-storerobbery/.github/ISSUE_TEMPLATE/bug_report.md
@@ -0,0 +1,32 @@
+---
+name: Bug report
+about: Create a report to help us improve or fix something
+title: "[BUG]"
+labels: bug
+assignees: ''
+
+---
+
+**Describe the bug**
+A clear and concise description of what the bug is. A stranger to qbcore should be able to read your bug report and understand how to reproduce it themselves and understand how the feature should work normally.
+
+**To Reproduce**
+Steps to reproduce the behavior:
+1. Go to '...'
+2. Click on '....'
+3. Use this item '....' (item's name from shared.lua if applicable)
+4. See error
+
+**Expected behavior**
+A clear and concise description of what you expected to happen.
+
+**Screenshots**
+If applicable, add screenshots to help explain your problem.
+
+**Questions (please complete the following information):**
+ - When you last updated: [e.g. last week]
+ - Are you using custom resource? which ones? [e.g. zdiscord, qb-target]
+ - Have you renamed `qb-` to something custom? [e.g. yes/no]
+
+**Additional context**
+Add any other context about the problem here.
diff --git a/[qb]/qb-storerobbery/.github/ISSUE_TEMPLATE/feature-request.md b/[qb]/qb-storerobbery/.github/ISSUE_TEMPLATE/feature-request.md
new file mode 100644
index 0000000..9e9bf3e
--- /dev/null
+++ b/[qb]/qb-storerobbery/.github/ISSUE_TEMPLATE/feature-request.md
@@ -0,0 +1,20 @@
+---
+name: Feature Request
+about: Suggest an idea for QBCore
+title: "[SUGGESTION]"
+labels: enhancement
+assignees: ''
+
+---
+
+**Is your feature request related to a problem? Please describe.**
+A clear and concise description of what the problem is.
+
+**Describe the feature you'd like**
+A clear and concise description of what you want to happen. and with as much detail as possible how it would function in your opinion. Please try to keep it unique.
+
+**Describe alternatives you've considered**
+A clear and concise description of any alternative solutions or features you've considered for people to have in mind just in case the main idea isn't liked but a derivative is.
+
+**Additional context**
+Add any other context or screenshots about the feature request here.
diff --git a/[qb]/qb-storerobbery/.github/auto_assign.yml b/[qb]/qb-storerobbery/.github/auto_assign.yml
new file mode 100644
index 0000000..2a80921
--- /dev/null
+++ b/[qb]/qb-storerobbery/.github/auto_assign.yml
@@ -0,0 +1,17 @@
+# Set to true to add reviewers to pull requests
+addReviewers: true
+
+# Set to true to add assignees to pull requests
+addAssignees: author
+
+# A list of reviewers to be added to pull requests (GitHub user name)
+reviewers:
+ - /maintenance
+
+# A list of keywords to be skipped the process that add reviewers if pull requests include it
+skipKeywords:
+ - wip
+
+# A number of reviewers added to the pull request
+# Set 0 to add all the reviewers (default: 0)
+numberOfReviewers: 0
\ No newline at end of file
diff --git a/[qb]/qb-storerobbery/.github/contributing.md b/[qb]/qb-storerobbery/.github/contributing.md
new file mode 100644
index 0000000..21fb806
--- /dev/null
+++ b/[qb]/qb-storerobbery/.github/contributing.md
@@ -0,0 +1,201 @@
+# Contributing to QBCore
+
+First of all, thank you for taking the time to contribute!
+
+These guidelines will help you help us in the best way possible regardless of your skill level. We ask that you try to read everything related to the way you'd like to contribute and try and use your best judgement for anything not covered.
+
+### Table of Contents
+
+[Code of Conduct](#code-of-conduct)
+
+[I don't want to read this whole thing, I just have a question!!!](#i-dont-want-to-read-this-whole-thing-i-just-have-a-question)
+
+[How Can I Contribute?](#how-can-i-contribute)
+ * [Reporting Bugs](#reporting-bugs)
+ * [Suggesting Features / Enhancements](#suggesting-features--enhancements)
+ * [Your First Code Contribution](#your-first-code-contribution)
+ * [Pull Requests](#pull-requests)
+
+[Styleguides](#styleguides)
+ * [Git Commit Messages](#git-commit-messages)
+ * [Lua Styleguide](#lua-styleguide)
+ * [JavaScript Styleguide](#javascript-styleguide)
+
+
+
+## Code of Conduct
+
+- Refrain from using languages other than English.
+- Refrain from discussing any politically charged or inflammatory topics.
+- Uphold mature conversations and respect each other; excessive profanity, hate speech or any kind of harassment will not be tolerated.
+- No advertising of any kind.
+- Follow these guidelines.
+- Do not mention members of github unless a question is directed at them and can't be answered by anyone else.
+- Do not mention any of the development team for any reason. We will read things as we get to them.
+
+## I don't want to read this whole thing I just have a question!!!
+
+> **Note:** Please don't file an issue to ask a question. You'll get faster results by using the resources below.
+
+* [QBCore Website](https://qbcore.org)
+* [QBCore Discord](https://discord.gg/qbcore)
+* [FiveM Discord - #qbcore channel](https://discord.gg/fivem)
+
+
+
+
+
+
+
+
+
+
+## How Can I Contribute?
+
+### Reporting Bugs
+
+The easiest way to contribute for most people is just to report bugs you find cause if nobody reports it there's a chance we'll never know it exists and then we'll never fix it.
+
+Before creating bug reports, please check [this list](#before-submitting-a-bug-report) as you might find out that you don't need to create one. When you are creating a bug report, please [include as many details as possible](#how-do-i-submit-a-good-bug-report). Fill out the bug-report template with the information it asks for helps us resolve issues faster.
+
+> **Note:** If you find a **Closed** issue that seems like it is the same thing that you're experiencing, open a new issue and include a link to the original issue in the body of your new one.
+
+#### Before Submitting A Bug Report
+
+* **Check the docs** There's a chance what you see as a bug might just work differently than you expect and if you think it could work better consider a feature enhancement report instead.
+* **Search the [discord](https://discord.gg/qbcore)** to see if anyone else has run into the issue and see if it was solved through user error or code changes. (if the code change isn't pending a PR and you know what you're doing consider submitting one following [Pull Requests](#pull-requests) )
+* **Determine which resource the problem should be reported in**. If the bug is related to the inventory for example report this bug under qb-inventory rather than under qb-core or some other resource.
+* **Perform a [cursory search](https://github.com/search?q=+is%3Aissue+user%3Aqbcore-framework)** to see if the problem has already been reported. If it has **and the issue is still open**, add a comment to the existing issue instead of opening a new one.
+
+#### How Do I Submit A (Good) Bug Report?
+
+Bugs are tracked as [GitHub issues](https://guides.github.com/features/issues/). After you've determined which resource your bug is related to, create an issue on that repository and provide the following information by filling in bug-report template.
+
+Explain the problem and include additional details to help maintainers reproduce the problem:
+
+* **Use a clear and descriptive title** for the issue to identify the problem.
+* **Describe the exact steps which reproduce the problem** in as many details as possible.
+* **Provide specific examples to demonstrate the steps**. If something happened with only a specific group or single item but not others, specify that.
+* **Describe the behavior you observed after following the steps** and point out what exactly is the problem with that behavior.
+* **Explain which behavior you expected to see instead and why.**
+* **Include screenshots** which show the specific bug in action or before and after.
+* **If the problem wasn't triggered by a specific action**, describe what you were doing before the problem happened and share more information using the guidelines below.
+
+Provide more context by answering these questions if possible:
+
+* **Did the problem start happening recently** (e.g. after updating to a new version of QBCore?) or was this always a problem?
+* If the problem started happening recently, **can you reproduce the problem in an older version of QBCore?** What's the most recent commit in which the problem doesn't happen?
+* **Can you reliably reproduce the issue?** If not, provide details about how often the problem happens and under which conditions it normally happens.
+
+Include details about your setup:
+
+* **When was your QBCore last updated?**
+* **What OS is the server running on**?
+* **Which *extra* resources do you have installed?**
+
+
+---
+
+
+### Suggesting Features / Enhancements
+
+This section guides you through submitting an enhancement suggestion for QBCore, including completely new features and minor improvements to existing functionality. Following these guidelines helps maintainers and the community understand your suggestion.
+
+Before creating enhancement suggestions, please check [this list](#before-submitting-an-enhancement-suggestion) as you might find out that you don't need to create one. When you are creating an enhancement suggestion, please [include as many details as possible](#how-do-i-submit-a-good-enhancement-suggestion). Fill in feature request template, including the steps that you imagine you would take if the feature you're requesting existed.
+
+#### Before Submitting An Enhancement Suggestion
+
+* **Make sure it doesn't already exist.** Sounds silly, but there's a lot of features built in to qbcore that people don't realize so take a look through the docs and stuff to make sure it's not already there.
+* **Check if there's already PR which provides that enhancement.**
+* **Determine which resource the enhancement should be suggested in.** if it fits with another resource suggest it in that resource. if it would be it's own resource suggest it in the main qb-core repository.
+* **Perform a [cursory search](https://github.com/search?q=+is%3Aissue+user%3Aqbcore-framework)** to see if the enhancement has already been suggested. If it has, add a comment to the existing issue instead of opening a new one.
+
+#### How Do I Submit A (Good) Enhancement Suggestion?
+
+Enhancement suggestions are tracked as [GitHub issues](https://guides.github.com/features/issues/). After you've determined which resource your enhancement suggestion is related to, create an issue on that repository and provide the following information:
+
+* **Use a clear and descriptive title** for the issue to identify the suggestion.
+* **Provide a step-by-step description of the suggested enhancement** in as many details as possible.
+* **Provide specific examples to demonstrate the steps**. Include copy/pasteable snippets which you use in those examples, as [Markdown code blocks](https://help.github.com/articles/markdown-basics/#multiple-lines).
+* **Describe the current behavior** and **explain which behavior you expected to see instead** and why.
+* **Include screenshots and animated GIFs** which help you demonstrate the steps or point out the part of QBCore which the suggestion is related to.
+* **Explain why this enhancement would be useful.**
+* **Be creative and unique.** Stealing ideas from popular servers 1:1 detail isn't going to get accepted.
+
+
+---
+
+
+
+### Your First Code Contribution
+
+Unsure where to begin contributing to QBCore? You can start by looking through these `beginner` and `help-wanted` issues.
+
+
+
+---
+
+
+### Pull Requests
+
+The process described here has several goals:
+
+- Maintain QBCore's quality.
+- Fix problems that are important to users.
+- Engage the community in working toward the best possible QBCore.
+- Enable a sustainable system for QBCore's maintainers to review contributions.
+
+Please follow these steps to have your contribution considered by the maintainers:
+
+1. Follow all instructions in The Pull Request template.
+2. Follow the [styleguides](#styleguides).
+3. Await review by the reviewer(s).
+
+While the prerequisites above must be satisfied prior to having your pull request reviewed, the reviewer(s) may ask you to complete additional design work, tests, or other changes before your pull request can be ultimately accepted.
+
+
+---
+
+## Styleguides
+
+### Git Commit Messages
+
+* Limit the first line to 72 characters or less.
+* Reference issues and pull requests liberally after the first line.
+* Consider starting the commit message with an applicable emoji:
+ * :art: `:art:` when improving the format/structure of the code
+ * :racehorse: `:racehorse:` when improving performance
+ * :memo: `:memo:` when writing docs
+ * :bug: `:bug:` when fixing a bug
+ * :fire: `:fire:` when removing code or files
+ * :white_check_mark: `:white_check_mark:` when adding tests
+ * :lock: `:lock:` when dealing with security
+ * :arrow_up: `:arrow_up:` when upgrading dependencies
+ * :arrow_down: `:arrow_down:` when downgrading dependencies
+ * :shirt: `:shirt:` when removing linter warnings
+
+### Lua Styleguide
+
+All lua code should be done using all the best practices of proper lua using the easiest to read yet fastest/most optimized methods of execution.
+
+- Use 4 Space indentation
+- Aim for lua 5.4 (include `lua54 'yes'` in the fxmanifest.lua)
+- Use `PlayerPedId()` instead of `GetPlayerPed(-1)`
+- Use `#(vector3 - vector3)` instead of `GetDistanceBetweenCoords()`
+- Don't create unnecessary threads. always try to find a better method of triggering events
+- Don't repeat yourself.. if you're using the same operations in many different places convert them into a function with flexible variables
+- For distance checking loops set longer waits if you're outside of a range
+- Job specific loops should only run for players with that job, don't waste cycles
+- When possible don't trust the client, esspecially with transactions
+- Balance security and optimizations
+- [Consider this Lua Performance guide](https://springrts.com/wiki/Lua_Performance)
+- Use local varriables everywhere possible
+- Make use of config options where it makes sense making features optional or customizable
+- Instead of `table.insert(myTable, "Value")` use `myTable[#myTable + 1] = "Value"`
+- Instead of `table.insert(ages, "bob", 30)` use `ages["bob"] = 30`
+
+
+### JavaScript Styleguide
+
+- Use 4 Space indentation
+- Don't repeat yourself.. if you're using the same operations in many different places convert them into a function with flexible variables.
diff --git a/[qb]/qb-storerobbery/.github/pull_request_template.md b/[qb]/qb-storerobbery/.github/pull_request_template.md
new file mode 100644
index 0000000..000f0f9
--- /dev/null
+++ b/[qb]/qb-storerobbery/.github/pull_request_template.md
@@ -0,0 +1,10 @@
+**Describe Pull request**
+First, make sure you've read and are following the contribution guidelines and style guide and your code reflects that.
+Write up a clear and concise description of what your pull request adds or fixes and if it's an added feature explain why you think it should be included in the core.
+
+If your PR is to fix an issue mention that issue here
+
+**Questions (please complete the following information):**
+- Have you personally loaded this code into an updated qbcore project and checked all it's functionality? [yes/no] (Be honest)
+- Does your code fit the style guidelines? [yes/no]
+- Does your PR fit the contribution guidelines? [yes/no]
diff --git a/[qb]/qb-storerobbery/.github/workflows/lint.yml b/[qb]/qb-storerobbery/.github/workflows/lint.yml
new file mode 100644
index 0000000..fb74fd6
--- /dev/null
+++ b/[qb]/qb-storerobbery/.github/workflows/lint.yml
@@ -0,0 +1,23 @@
+name: Lint
+on: [push, pull_request_target]
+jobs:
+ lint:
+ name: Lint Resource
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v2
+ with:
+ ref: ${{ github.event.pull_request.head.sha }}
+ - name: Lint
+ uses: iLLeniumStudios/fivem-lua-lint-action@v2
+ with:
+ capture: "junit.xml"
+ args: "-t --formatter JUnit"
+ extra_libs: mysql+polyzone+qblocales
+ - name: Generate Lint Report
+ if: always()
+ uses: mikepenz/action-junit-report@v3
+ with:
+ report_paths: "**/junit.xml"
+ check_name: Linting Report
+ fail_on_failure: false
\ No newline at end of file
diff --git a/[qb]/qb-storerobbery/LICENSE b/[qb]/qb-storerobbery/LICENSE
new file mode 100644
index 0000000..f288702
--- /dev/null
+++ b/[qb]/qb-storerobbery/LICENSE
@@ -0,0 +1,674 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The GNU General Public License is a free, copyleft license for
+software and other kinds of works.
+
+ The licenses for most software and other practical works are designed
+to take away your freedom to share and change the works. By contrast,
+the GNU General Public License is intended to guarantee your freedom to
+share and change all versions of a program--to make sure it remains free
+software for all its users. We, the Free Software Foundation, use the
+GNU General Public License for most of our software; it applies also to
+any other work released this way by its authors. You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+them if you wish), that you receive source code or can get it if you
+want it, that you can change the software or use pieces of it in new
+free programs, and that you know you can do these things.
+
+ To protect your rights, we need to prevent others from denying you
+these rights or asking you to surrender the rights. Therefore, you have
+certain responsibilities if you distribute copies of the software, or if
+you modify it: responsibilities to respect the freedom of others.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must pass on to the recipients the same
+freedoms that you received. You must make sure that they, too, receive
+or can get the source code. And you must show them these terms so they
+know their rights.
+
+ Developers that use the GNU GPL protect your rights with two steps:
+(1) assert copyright on the software, and (2) offer you this License
+giving you legal permission to copy, distribute and/or modify it.
+
+ For the developers' and authors' protection, the GPL clearly explains
+that there is no warranty for this free software. For both users' and
+authors' sake, the GPL requires that modified versions be marked as
+changed, so that their problems will not be attributed erroneously to
+authors of previous versions.
+
+ Some devices are designed to deny users access to install or run
+modified versions of the software inside them, although the manufacturer
+can do so. This is fundamentally incompatible with the aim of
+protecting users' freedom to change the software. The systematic
+pattern of such abuse occurs in the area of products for individuals to
+use, which is precisely where it is most unacceptable. Therefore, we
+have designed this version of the GPL to prohibit the practice for those
+products. If such problems arise substantially in other domains, we
+stand ready to extend this provision to those domains in future versions
+of the GPL, as needed to protect the freedom of users.
+
+ Finally, every program is threatened constantly by software patents.
+States should not allow patents to restrict development and use of
+software on general-purpose computers, but in those that do, we wish to
+avoid the special danger that patents applied to a free program could
+make it effectively proprietary. To prevent this, the GPL assures that
+patents cannot be used to render the program non-free.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ TERMS AND CONDITIONS
+
+ 0. Definitions.
+
+ "This License" refers to version 3 of the GNU General Public License.
+
+ "Copyright" also means copyright-like laws that apply to other kinds of
+works, such as semiconductor masks.
+
+ "The Program" refers to any copyrightable work licensed under this
+License. Each licensee is addressed as "you". "Licensees" and
+"recipients" may be individuals or organizations.
+
+ To "modify" a work means to copy from or adapt all or part of the work
+in a fashion requiring copyright permission, other than the making of an
+exact copy. The resulting work is called a "modified version" of the
+earlier work or a work "based on" the earlier work.
+
+ A "covered work" means either the unmodified Program or a work based
+on the Program.
+
+ To "propagate" a work means to do anything with it that, without
+permission, would make you directly or secondarily liable for
+infringement under applicable copyright law, except executing it on a
+computer or modifying a private copy. Propagation includes copying,
+distribution (with or without modification), making available to the
+public, and in some countries other activities as well.
+
+ To "convey" a work means any kind of propagation that enables other
+parties to make or receive copies. Mere interaction with a user through
+a computer network, with no transfer of a copy, is not conveying.
+
+ An interactive user interface displays "Appropriate Legal Notices"
+to the extent that it includes a convenient and prominently visible
+feature that (1) displays an appropriate copyright notice, and (2)
+tells the user that there is no warranty for the work (except to the
+extent that warranties are provided), that licensees may convey the
+work under this License, and how to view a copy of this License. If
+the interface presents a list of user commands or options, such as a
+menu, a prominent item in the list meets this criterion.
+
+ 1. Source Code.
+
+ The "source code" for a work means the preferred form of the work
+for making modifications to it. "Object code" means any non-source
+form of a work.
+
+ A "Standard Interface" means an interface that either is an official
+standard defined by a recognized standards body, or, in the case of
+interfaces specified for a particular programming language, one that
+is widely used among developers working in that language.
+
+ The "System Libraries" of an executable work include anything, other
+than the work as a whole, that (a) is included in the normal form of
+packaging a Major Component, but which is not part of that Major
+Component, and (b) serves only to enable use of the work with that
+Major Component, or to implement a Standard Interface for which an
+implementation is available to the public in source code form. A
+"Major Component", in this context, means a major essential component
+(kernel, window system, and so on) of the specific operating system
+(if any) on which the executable work runs, or a compiler used to
+produce the work, or an object code interpreter used to run it.
+
+ The "Corresponding Source" for a work in object code form means all
+the source code needed to generate, install, and (for an executable
+work) run the object code and to modify the work, including scripts to
+control those activities. However, it does not include the work's
+System Libraries, or general-purpose tools or generally available free
+programs which are used unmodified in performing those activities but
+which are not part of the work. For example, Corresponding Source
+includes interface definition files associated with source files for
+the work, and the source code for shared libraries and dynamically
+linked subprograms that the work is specifically designed to require,
+such as by intimate data communication or control flow between those
+subprograms and other parts of the work.
+
+ The Corresponding Source need not include anything that users
+can regenerate automatically from other parts of the Corresponding
+Source.
+
+ The Corresponding Source for a work in source code form is that
+same work.
+
+ 2. Basic Permissions.
+
+ All rights granted under this License are granted for the term of
+copyright on the Program, and are irrevocable provided the stated
+conditions are met. This License explicitly affirms your unlimited
+permission to run the unmodified Program. The output from running a
+covered work is covered by this License only if the output, given its
+content, constitutes a covered work. This License acknowledges your
+rights of fair use or other equivalent, as provided by copyright law.
+
+ You may make, run and propagate covered works that you do not
+convey, without conditions so long as your license otherwise remains
+in force. You may convey covered works to others for the sole purpose
+of having them make modifications exclusively for you, or provide you
+with facilities for running those works, provided that you comply with
+the terms of this License in conveying all material for which you do
+not control copyright. Those thus making or running the covered works
+for you must do so exclusively on your behalf, under your direction
+and control, on terms that prohibit them from making any copies of
+your copyrighted material outside their relationship with you.
+
+ Conveying under any other circumstances is permitted solely under
+the conditions stated below. Sublicensing is not allowed; section 10
+makes it unnecessary.
+
+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
+
+ No covered work shall be deemed part of an effective technological
+measure under any applicable law fulfilling obligations under article
+11 of the WIPO copyright treaty adopted on 20 December 1996, or
+similar laws prohibiting or restricting circumvention of such
+measures.
+
+ When you convey a covered work, you waive any legal power to forbid
+circumvention of technological measures to the extent such circumvention
+is effected by exercising rights under this License with respect to
+the covered work, and you disclaim any intention to limit operation or
+modification of the work as a means of enforcing, against the work's
+users, your or third parties' legal rights to forbid circumvention of
+technological measures.
+
+ 4. Conveying Verbatim Copies.
+
+ You may convey verbatim copies of the Program's source code as you
+receive it, in any medium, provided that you conspicuously and
+appropriately publish on each copy an appropriate copyright notice;
+keep intact all notices stating that this License and any
+non-permissive terms added in accord with section 7 apply to the code;
+keep intact all notices of the absence of any warranty; and give all
+recipients a copy of this License along with the Program.
+
+ You may charge any price or no price for each copy that you convey,
+and you may offer support or warranty protection for a fee.
+
+ 5. Conveying Modified Source Versions.
+
+ You may convey a work based on the Program, or the modifications to
+produce it from the Program, in the form of source code under the
+terms of section 4, provided that you also meet all of these conditions:
+
+ a) The work must carry prominent notices stating that you modified
+ it, and giving a relevant date.
+
+ b) The work must carry prominent notices stating that it is
+ released under this License and any conditions added under section
+ 7. This requirement modifies the requirement in section 4 to
+ "keep intact all notices".
+
+ c) You must license the entire work, as a whole, under this
+ License to anyone who comes into possession of a copy. This
+ License will therefore apply, along with any applicable section 7
+ additional terms, to the whole of the work, and all its parts,
+ regardless of how they are packaged. This License gives no
+ permission to license the work in any other way, but it does not
+ invalidate such permission if you have separately received it.
+
+ d) If the work has interactive user interfaces, each must display
+ Appropriate Legal Notices; however, if the Program has interactive
+ interfaces that do not display Appropriate Legal Notices, your
+ work need not make them do so.
+
+ A compilation of a covered work with other separate and independent
+works, which are not by their nature extensions of the covered work,
+and which are not combined with it such as to form a larger program,
+in or on a volume of a storage or distribution medium, is called an
+"aggregate" if the compilation and its resulting copyright are not
+used to limit the access or legal rights of the compilation's users
+beyond what the individual works permit. Inclusion of a covered work
+in an aggregate does not cause this License to apply to the other
+parts of the aggregate.
+
+ 6. Conveying Non-Source Forms.
+
+ You may convey a covered work in object code form under the terms
+of sections 4 and 5, provided that you also convey the
+machine-readable Corresponding Source under the terms of this License,
+in one of these ways:
+
+ a) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by the
+ Corresponding Source fixed on a durable physical medium
+ customarily used for software interchange.
+
+ b) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by a
+ written offer, valid for at least three years and valid for as
+ long as you offer spare parts or customer support for that product
+ model, to give anyone who possesses the object code either (1) a
+ copy of the Corresponding Source for all the software in the
+ product that is covered by this License, on a durable physical
+ medium customarily used for software interchange, for a price no
+ more than your reasonable cost of physically performing this
+ conveying of source, or (2) access to copy the
+ Corresponding Source from a network server at no charge.
+
+ c) Convey individual copies of the object code with a copy of the
+ written offer to provide the Corresponding Source. This
+ alternative is allowed only occasionally and noncommercially, and
+ only if you received the object code with such an offer, in accord
+ with subsection 6b.
+
+ d) Convey the object code by offering access from a designated
+ place (gratis or for a charge), and offer equivalent access to the
+ Corresponding Source in the same way through the same place at no
+ further charge. You need not require recipients to copy the
+ Corresponding Source along with the object code. If the place to
+ copy the object code is a network server, the Corresponding Source
+ may be on a different server (operated by you or a third party)
+ that supports equivalent copying facilities, provided you maintain
+ clear directions next to the object code saying where to find the
+ Corresponding Source. Regardless of what server hosts the
+ Corresponding Source, you remain obligated to ensure that it is
+ available for as long as needed to satisfy these requirements.
+
+ e) Convey the object code using peer-to-peer transmission, provided
+ you inform other peers where the object code and Corresponding
+ Source of the work are being offered to the general public at no
+ charge under subsection 6d.
+
+ A separable portion of the object code, whose source code is excluded
+from the Corresponding Source as a System Library, need not be
+included in conveying the object code work.
+
+ A "User Product" is either (1) a "consumer product", which means any
+tangible personal property which is normally used for personal, family,
+or household purposes, or (2) anything designed or sold for incorporation
+into a dwelling. In determining whether a product is a consumer product,
+doubtful cases shall be resolved in favor of coverage. For a particular
+product received by a particular user, "normally used" refers to a
+typical or common use of that class of product, regardless of the status
+of the particular user or of the way in which the particular user
+actually uses, or expects or is expected to use, the product. A product
+is a consumer product regardless of whether the product has substantial
+commercial, industrial or non-consumer uses, unless such uses represent
+the only significant mode of use of the product.
+
+ "Installation Information" for a User Product means any methods,
+procedures, authorization keys, or other information required to install
+and execute modified versions of a covered work in that User Product from
+a modified version of its Corresponding Source. The information must
+suffice to ensure that the continued functioning of the modified object
+code is in no case prevented or interfered with solely because
+modification has been made.
+
+ If you convey an object code work under this section in, or with, or
+specifically for use in, a User Product, and the conveying occurs as
+part of a transaction in which the right of possession and use of the
+User Product is transferred to the recipient in perpetuity or for a
+fixed term (regardless of how the transaction is characterized), the
+Corresponding Source conveyed under this section must be accompanied
+by the Installation Information. But this requirement does not apply
+if neither you nor any third party retains the ability to install
+modified object code on the User Product (for example, the work has
+been installed in ROM).
+
+ The requirement to provide Installation Information does not include a
+requirement to continue to provide support service, warranty, or updates
+for a work that has been modified or installed by the recipient, or for
+the User Product in which it has been modified or installed. Access to a
+network may be denied when the modification itself materially and
+adversely affects the operation of the network or violates the rules and
+protocols for communication across the network.
+
+ Corresponding Source conveyed, and Installation Information provided,
+in accord with this section must be in a format that is publicly
+documented (and with an implementation available to the public in
+source code form), and must require no special password or key for
+unpacking, reading or copying.
+
+ 7. Additional Terms.
+
+ "Additional permissions" are terms that supplement the terms of this
+License by making exceptions from one or more of its conditions.
+Additional permissions that are applicable to the entire Program shall
+be treated as though they were included in this License, to the extent
+that they are valid under applicable law. If additional permissions
+apply only to part of the Program, that part may be used separately
+under those permissions, but the entire Program remains governed by
+this License without regard to the additional permissions.
+
+ When you convey a copy of a covered work, you may at your option
+remove any additional permissions from that copy, or from any part of
+it. (Additional permissions may be written to require their own
+removal in certain cases when you modify the work.) You may place
+additional permissions on material, added by you to a covered work,
+for which you have or can give appropriate copyright permission.
+
+ Notwithstanding any other provision of this License, for material you
+add to a covered work, you may (if authorized by the copyright holders of
+that material) supplement the terms of this License with terms:
+
+ a) Disclaiming warranty or limiting liability differently from the
+ terms of sections 15 and 16 of this License; or
+
+ b) Requiring preservation of specified reasonable legal notices or
+ author attributions in that material or in the Appropriate Legal
+ Notices displayed by works containing it; or
+
+ c) Prohibiting misrepresentation of the origin of that material, or
+ requiring that modified versions of such material be marked in
+ reasonable ways as different from the original version; or
+
+ d) Limiting the use for publicity purposes of names of licensors or
+ authors of the material; or
+
+ e) Declining to grant rights under trademark law for use of some
+ trade names, trademarks, or service marks; or
+
+ f) Requiring indemnification of licensors and authors of that
+ material by anyone who conveys the material (or modified versions of
+ it) with contractual assumptions of liability to the recipient, for
+ any liability that these contractual assumptions directly impose on
+ those licensors and authors.
+
+ All other non-permissive additional terms are considered "further
+restrictions" within the meaning of section 10. If the Program as you
+received it, or any part of it, contains a notice stating that it is
+governed by this License along with a term that is a further
+restriction, you may remove that term. If a license document contains
+a further restriction but permits relicensing or conveying under this
+License, you may add to a covered work material governed by the terms
+of that license document, provided that the further restriction does
+not survive such relicensing or conveying.
+
+ If you add terms to a covered work in accord with this section, you
+must place, in the relevant source files, a statement of the
+additional terms that apply to those files, or a notice indicating
+where to find the applicable terms.
+
+ Additional terms, permissive or non-permissive, may be stated in the
+form of a separately written license, or stated as exceptions;
+the above requirements apply either way.
+
+ 8. Termination.
+
+ You may not propagate or modify a covered work except as expressly
+provided under this License. Any attempt otherwise to propagate or
+modify it is void, and will automatically terminate your rights under
+this License (including any patent licenses granted under the third
+paragraph of section 11).
+
+ However, if you cease all violation of this License, then your
+license from a particular copyright holder is reinstated (a)
+provisionally, unless and until the copyright holder explicitly and
+finally terminates your license, and (b) permanently, if the copyright
+holder fails to notify you of the violation by some reasonable means
+prior to 60 days after the cessation.
+
+ Moreover, your license from a particular copyright holder is
+reinstated permanently if the copyright holder notifies you of the
+violation by some reasonable means, this is the first time you have
+received notice of violation of this License (for any work) from that
+copyright holder, and you cure the violation prior to 30 days after
+your receipt of the notice.
+
+ Termination of your rights under this section does not terminate the
+licenses of parties who have received copies or rights from you under
+this License. If your rights have been terminated and not permanently
+reinstated, you do not qualify to receive new licenses for the same
+material under section 10.
+
+ 9. Acceptance Not Required for Having Copies.
+
+ You are not required to accept this License in order to receive or
+run a copy of the Program. Ancillary propagation of a covered work
+occurring solely as a consequence of using peer-to-peer transmission
+to receive a copy likewise does not require acceptance. However,
+nothing other than this License grants you permission to propagate or
+modify any covered work. These actions infringe copyright if you do
+not accept this License. Therefore, by modifying or propagating a
+covered work, you indicate your acceptance of this License to do so.
+
+ 10. Automatic Licensing of Downstream Recipients.
+
+ Each time you convey a covered work, the recipient automatically
+receives a license from the original licensors, to run, modify and
+propagate that work, subject to this License. You are not responsible
+for enforcing compliance by third parties with this License.
+
+ An "entity transaction" is a transaction transferring control of an
+organization, or substantially all assets of one, or subdividing an
+organization, or merging organizations. If propagation of a covered
+work results from an entity transaction, each party to that
+transaction who receives a copy of the work also receives whatever
+licenses to the work the party's predecessor in interest had or could
+give under the previous paragraph, plus a right to possession of the
+Corresponding Source of the work from the predecessor in interest, if
+the predecessor has it or can get it with reasonable efforts.
+
+ You may not impose any further restrictions on the exercise of the
+rights granted or affirmed under this License. For example, you may
+not impose a license fee, royalty, or other charge for exercise of
+rights granted under this License, and you may not initiate litigation
+(including a cross-claim or counterclaim in a lawsuit) alleging that
+any patent claim is infringed by making, using, selling, offering for
+sale, or importing the Program or any portion of it.
+
+ 11. Patents.
+
+ A "contributor" is a copyright holder who authorizes use under this
+License of the Program or a work on which the Program is based. The
+work thus licensed is called the contributor's "contributor version".
+
+ A contributor's "essential patent claims" are all patent claims
+owned or controlled by the contributor, whether already acquired or
+hereafter acquired, that would be infringed by some manner, permitted
+by this License, of making, using, or selling its contributor version,
+but do not include claims that would be infringed only as a
+consequence of further modification of the contributor version. For
+purposes of this definition, "control" includes the right to grant
+patent sublicenses in a manner consistent with the requirements of
+this License.
+
+ Each contributor grants you a non-exclusive, worldwide, royalty-free
+patent license under the contributor's essential patent claims, to
+make, use, sell, offer for sale, import and otherwise run, modify and
+propagate the contents of its contributor version.
+
+ In the following three paragraphs, a "patent license" is any express
+agreement or commitment, however denominated, not to enforce a patent
+(such as an express permission to practice a patent or covenant not to
+sue for patent infringement). To "grant" such a patent license to a
+party means to make such an agreement or commitment not to enforce a
+patent against the party.
+
+ If you convey a covered work, knowingly relying on a patent license,
+and the Corresponding Source of the work is not available for anyone
+to copy, free of charge and under the terms of this License, through a
+publicly available network server or other readily accessible means,
+then you must either (1) cause the Corresponding Source to be so
+available, or (2) arrange to deprive yourself of the benefit of the
+patent license for this particular work, or (3) arrange, in a manner
+consistent with the requirements of this License, to extend the patent
+license to downstream recipients. "Knowingly relying" means you have
+actual knowledge that, but for the patent license, your conveying the
+covered work in a country, or your recipient's use of the covered work
+in a country, would infringe one or more identifiable patents in that
+country that you have reason to believe are valid.
+
+ If, pursuant to or in connection with a single transaction or
+arrangement, you convey, or propagate by procuring conveyance of, a
+covered work, and grant a patent license to some of the parties
+receiving the covered work authorizing them to use, propagate, modify
+or convey a specific copy of the covered work, then the patent license
+you grant is automatically extended to all recipients of the covered
+work and works based on it.
+
+ A patent license is "discriminatory" if it does not include within
+the scope of its coverage, prohibits the exercise of, or is
+conditioned on the non-exercise of one or more of the rights that are
+specifically granted under this License. You may not convey a covered
+work if you are a party to an arrangement with a third party that is
+in the business of distributing software, under which you make payment
+to the third party based on the extent of your activity of conveying
+the work, and under which the third party grants, to any of the
+parties who would receive the covered work from you, a discriminatory
+patent license (a) in connection with copies of the covered work
+conveyed by you (or copies made from those copies), or (b) primarily
+for and in connection with specific products or compilations that
+contain the covered work, unless you entered into that arrangement,
+or that patent license was granted, prior to 28 March 2007.
+
+ Nothing in this License shall be construed as excluding or limiting
+any implied license or other defenses to infringement that may
+otherwise be available to you under applicable patent law.
+
+ 12. No Surrender of Others' Freedom.
+
+ If conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot convey a
+covered work so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you may
+not convey it at all. For example, if you agree to terms that obligate you
+to collect a royalty for further conveying from those to whom you convey
+the Program, the only way you could satisfy both those terms and this
+License would be to refrain entirely from conveying the Program.
+
+ 13. Use with the GNU Affero General Public License.
+
+ Notwithstanding any other provision of this License, you have
+permission to link or combine any covered work with a work licensed
+under version 3 of the GNU Affero General Public License into a single
+combined work, and to convey the resulting work. The terms of this
+License will continue to apply to the part which is the covered work,
+but the special requirements of the GNU Affero General Public License,
+section 13, concerning interaction through a network will apply to the
+combination as such.
+
+ 14. Revised Versions of this License.
+
+ The Free Software Foundation may publish revised and/or new versions of
+the GNU General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Program specifies that a certain numbered version of the GNU General
+Public License "or any later version" applies to it, you have the
+option of following the terms and conditions either of that numbered
+version or of any later version published by the Free Software
+Foundation. If the Program does not specify a version number of the
+GNU General Public License, you may choose any version ever published
+by the Free Software Foundation.
+
+ If the Program specifies that a proxy can decide which future
+versions of the GNU General Public License can be used, that proxy's
+public statement of acceptance of a version permanently authorizes you
+to choose that version for the Program.
+
+ Later license versions may give you additional or different
+permissions. However, no additional obligations are imposed on any
+author or copyright holder as a result of your choosing to follow a
+later version.
+
+ 15. Disclaimer of Warranty.
+
+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+ 16. Limitation of Liability.
+
+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
+SUCH DAMAGES.
+
+ 17. Interpretation of Sections 15 and 16.
+
+ If the disclaimer of warranty and limitation of liability provided
+above cannot be given local legal effect according to their terms,
+reviewing courts shall apply local law that most closely approximates
+an absolute waiver of all civil liability in connection with the
+Program, unless a warranty or assumption of liability accompanies a
+copy of the Program in return for a fee.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+state the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+
+ Copyright (C)
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+
+Also add information on how to contact you by electronic and paper mail.
+
+ If the program does terminal interaction, make it output a short
+notice like this when it starts in an interactive mode:
+
+ Copyright (C)
+ This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, your program's commands
+might be different; for a GUI interface, you would use an "about box".
+
+ You should also get your employer (if you work as a programmer) or school,
+if any, to sign a "copyright disclaimer" for the program, if necessary.
+For more information on this, and how to apply and follow the GNU GPL, see
+.
+
+ The GNU General Public License does not permit incorporating your program
+into proprietary programs. If your program is a subroutine library, you
+may consider it more useful to permit linking proprietary applications with
+the library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License. But first, please read
+.
diff --git a/[qb]/qb-storerobbery/README.md b/[qb]/qb-storerobbery/README.md
new file mode 100644
index 0000000..cc8e435
--- /dev/null
+++ b/[qb]/qb-storerobbery/README.md
@@ -0,0 +1,21 @@
+# qb-storerobbery
+Store Robberies For QB-Core
+
+# License
+
+ QBCore Framework
+ Copyright (C) 2021 Joshua Eger
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see
+
diff --git a/[qb]/qb-storerobbery/client/main.lua b/[qb]/qb-storerobbery/client/main.lua
new file mode 100644
index 0000000..748c4bb
--- /dev/null
+++ b/[qb]/qb-storerobbery/client/main.lua
@@ -0,0 +1,463 @@
+local QBCore = exports['qb-core']:GetCoreObject()
+local currentRegister = 0
+local currentSafe = 0
+local copsCalled = false
+local CurrentCops = 0
+local PlayerJob = {}
+local onDuty = false
+local usingAdvanced = false
+
+CreateThread(function()
+ Wait(1000)
+ if QBCore.Functions.GetPlayerData().job ~= nil and next(QBCore.Functions.GetPlayerData().job) then
+ PlayerJob = QBCore.Functions.GetPlayerData().job
+ end
+end)
+
+CreateThread(function()
+ while true do
+ Wait(1000 * 60 * 5)
+ if copsCalled then
+ copsCalled = false
+ end
+ end
+end)
+
+CreateThread(function()
+ Wait(1000)
+ setupRegister()
+ setupSafes()
+ while true do
+ local ped = PlayerPedId()
+ local pos = GetEntityCoords(ped)
+ local inRange = false
+ for k in pairs(Config.Registers) do
+ local dist = #(pos - Config.Registers[k][1].xyz)
+ if dist <= 1 and Config.Registers[k].robbed then
+ inRange = true
+ DrawText3Ds(Config.Registers[k][1].xyz, Lang:t("text.the_cash_register_is_empty"))
+ end
+ end
+ if not inRange then
+ Wait(2000)
+ end
+ Wait(3)
+ end
+end)
+
+CreateThread(function()
+ while true do
+ Wait(1)
+ local inRange = false
+ if QBCore ~= nil then
+ local pos = GetEntityCoords(PlayerPedId())
+ for safe,_ in pairs(Config.Safes) do
+ local dist = #(pos - Config.Safes[safe][1].xyz)
+ if dist < 3 then
+ inRange = true
+ if dist < 1.0 then
+ if not Config.Safes[safe].robbed then
+ DrawText3Ds(Config.Safes[safe][1].xyz, Lang:t("text.try_combination"))
+ if IsControlJustPressed(0, 38) then
+ if CurrentCops >= Config.MinimumStoreRobberyPolice then
+ currentSafe = safe
+ if math.random(1, 100) <= 65 and not IsWearingGloves() then
+ TriggerServerEvent("evidence:server:CreateFingerDrop", pos)
+ end
+ if math.random(100) <= 50 then
+ TriggerServerEvent('hud:server:GainStress', math.random(1, 3))
+ end
+ if Config.Safes[safe].type == "keypad" then
+ SendNUIMessage({
+ action = "openKeypad",
+ })
+ SetNuiFocus(true, true)
+ else
+ QBCore.Functions.TriggerCallback('qb-storerobbery:server:getPadlockCombination', function(combination)
+ TriggerEvent("SafeCracker:StartMinigame", combination)
+ end, safe)
+ end
+
+ if not copsCalled then
+ pos = GetEntityCoords(PlayerPedId())
+ local s1, s2 = GetStreetNameAtCoord(pos.x, pos.y, pos.z)
+ local street1 = GetStreetNameFromHashKey(s1)
+ local street2 = GetStreetNameFromHashKey(s2)
+ local streetLabel = street1
+ if street2 ~= nil then
+ streetLabel = streetLabel .. " " .. street2
+ end
+ TriggerServerEvent("qb-storerobbery:server:callCops", "safe", currentSafe, streetLabel, pos)
+ copsCalled = true
+ end
+ else
+ QBCore.Functions.Notify(Lang:t("error.minimum_store_robbery_police", { MinimumStoreRobberyPolice = Config.MinimumStoreRobberyPolice}), "error")
+ end
+ end
+ else
+ DrawText3Ds(Config.Safes[safe][1].xyz, Lang:t("text.safe_opened"))
+ end
+ end
+ end
+ end
+ end
+
+ if not inRange then
+ Wait(2000)
+ end
+ end
+end)
+
+RegisterNetEvent('QBCore:Client:OnPlayerLoaded', function()
+ PlayerJob = QBCore.Functions.GetPlayerData().job
+ onDuty = true
+end)
+
+RegisterNetEvent('QBCore:Client:SetDuty', function(duty)
+ onDuty = duty
+end)
+
+RegisterNetEvent('QBCore:Client:OnJobUpdate', function(JobInfo)
+ PlayerJob = JobInfo
+ onDuty = true
+end)
+
+RegisterNetEvent('police:SetCopCount', function(amount)
+ CurrentCops = amount
+end)
+
+RegisterNetEvent('lockpicks:UseLockpick', function(isAdvanced)
+ usingAdvanced = isAdvanced
+ for k in pairs(Config.Registers) do
+ local ped = PlayerPedId()
+ local pos = GetEntityCoords(ped)
+ local dist = #(pos - Config.Registers[k][1].xyz)
+ if dist <= 1 and not Config.Registers[k].robbed then
+ if CurrentCops >= Config.MinimumStoreRobberyPolice then
+ if usingAdvanced then
+ lockpick(true)
+ currentRegister = k
+ if not IsWearingGloves() then
+ TriggerServerEvent("evidence:server:CreateFingerDrop", pos)
+ end
+ if not copsCalled then
+ local s1, s2 = GetStreetNameAtCoord(pos.x, pos.y, pos.z)
+ local street1 = GetStreetNameFromHashKey(s1)
+ local street2 = GetStreetNameFromHashKey(s2)
+ local streetLabel = street1
+ if street2 ~= nil then
+ streetLabel = streetLabel .. " " .. street2
+ end
+ TriggerServerEvent("qb-storerobbery:server:callCops", "cashier", currentRegister, streetLabel, pos)
+ copsCalled = true
+ end
+ else
+ lockpick(true)
+ currentRegister = k
+ if not IsWearingGloves() then
+ TriggerServerEvent("evidence:server:CreateFingerDrop", pos)
+ end
+ if not copsCalled then
+ local s1, s2 = GetStreetNameAtCoord(pos.x, pos.y, pos.z)
+ local street1 = GetStreetNameFromHashKey(s1)
+ local street2 = GetStreetNameFromHashKey(s2)
+ local streetLabel = street1
+ if street2 ~= nil then
+ streetLabel = streetLabel .. " " .. street2
+ end
+ TriggerServerEvent("qb-storerobbery:server:callCops", "cashier", currentRegister, streetLabel, pos)
+ copsCalled = true
+ end
+
+ end
+
+ else
+ QBCore.Functions.Notify(Lang:t("error.minimum_store_robbery_police", { MinimumStoreRobberyPolice = Config.MinimumStoreRobberyPolice}), "error")
+ end
+ end
+ end
+end)
+
+function IsWearingGloves()
+ local armIndex = GetPedDrawableVariation(PlayerPedId(), 3)
+ local model = GetEntityModel(PlayerPedId())
+ local retval = true
+
+ if model == `mp_m_freemode_01` then
+ if Config.MaleNoGloves[armIndex] ~= nil and Config.MaleNoGloves[armIndex] then
+ retval = false
+ end
+ else
+ if Config.FemaleNoGloves[armIndex] ~= nil and Config.FemaleNoGloves[armIndex] then
+ retval = false
+ end
+ end
+ return retval
+end
+
+function setupRegister()
+ QBCore.Functions.TriggerCallback('qb-storerobbery:server:getRegisterStatus', function(Registers)
+ for k in pairs(Registers) do
+ Config.Registers[k].robbed = Registers[k].robbed
+ end
+ end)
+end
+
+function setupSafes()
+ QBCore.Functions.TriggerCallback('qb-storerobbery:server:getSafeStatus', function(Safes)
+ for k in pairs(Safes) do
+ Config.Safes[k].robbed = Safes[k].robbed
+ end
+ end)
+end
+
+DrawText3Ds = function(coords, text)
+ SetTextScale(0.35, 0.35)
+ SetTextFont(4)
+ SetTextProportional(1)
+ SetTextColour(255, 255, 255, 215)
+ SetTextEntry("STRING")
+ SetTextCentre(true)
+ AddTextComponentString(text)
+ SetDrawOrigin(coords, 0)
+ DrawText(0.0, 0.0)
+ local factor = (string.len(text)) / 370
+ DrawRect(0.0, 0.0+0.0125, 0.017+ factor, 0.03, 0, 0, 0, 75)
+ ClearDrawOrigin()
+end
+
+function lockpick(bool)
+ SetNuiFocus(bool, bool)
+ SendNUIMessage({
+ action = "ui",
+ toggle = bool,
+ })
+ SetCursorLocation(0.5, 0.2)
+end
+
+function loadAnimDict(dict)
+ while (not HasAnimDictLoaded(dict)) do
+ RequestAnimDict(dict)
+ Wait(100)
+ end
+end
+
+function takeAnim()
+ local ped = PlayerPedId()
+ while (not HasAnimDictLoaded("amb@prop_human_bum_bin@idle_b")) do
+ RequestAnimDict("amb@prop_human_bum_bin@idle_b")
+ Wait(100)
+ end
+ TaskPlayAnim(ped, "amb@prop_human_bum_bin@idle_b", "idle_d", 8.0, 8.0, -1, 50, 0, false, false, false)
+ Wait(2500)
+ TaskPlayAnim(ped, "amb@prop_human_bum_bin@idle_b", "exit", 8.0, 8.0, -1, 50, 0, false, false, false)
+end
+
+local openingDoor = false
+
+RegisterNUICallback('success', function(_, cb)
+ if currentRegister ~= 0 then
+ lockpick(false)
+ TriggerServerEvent('qb-storerobbery:server:setRegisterStatus', currentRegister)
+ local lockpickTime = 25000
+ LockpickDoorAnim(lockpickTime)
+ QBCore.Functions.Progressbar("search_register", Lang:t("text.emptying_the_register"), lockpickTime, false, true, {
+ disableMovement = true,
+ disableCarMovement = true,
+ disableMouse = false,
+ disableCombat = true,
+ }, {
+ animDict = "veh@break_in@0h@p_m_one@",
+ anim = "low_force_entry_ds",
+ flags = 16,
+ }, {}, {}, function() -- Done
+ openingDoor = false
+ ClearPedTasks(PlayerPedId())
+ TriggerServerEvent('qb-storerobbery:server:takeMoney', currentRegister, true)
+ end, function() -- Cancel
+ openingDoor = false
+ ClearPedTasks(PlayerPedId())
+ QBCore.Functions.Notify(Lang:t("error.process_canceled"), "error")
+ currentRegister = 0
+ end)
+ CreateThread(function()
+ while openingDoor do
+ TriggerServerEvent('hud:server:GainStress', math.random(1, 3))
+ Wait(10000)
+ end
+ end)
+ else
+ SendNUIMessage({
+ action = "kekw",
+ })
+ end
+ cb('ok')
+end)
+
+function LockpickDoorAnim(time)
+ time = time / 1000
+ loadAnimDict("veh@break_in@0h@p_m_one@")
+ TaskPlayAnim(PlayerPedId(), "veh@break_in@0h@p_m_one@", "low_force_entry_ds" ,3.0, 3.0, -1, 16, 0, false, false, false)
+ openingDoor = true
+ CreateThread(function()
+ while openingDoor do
+ TaskPlayAnim(PlayerPedId(), "veh@break_in@0h@p_m_one@", "low_force_entry_ds", 3.0, 3.0, -1, 16, 0, 0, 0, 0)
+ Wait(2000)
+ time = time - 2
+ TriggerServerEvent('qb-storerobbery:server:takeMoney', currentRegister, false)
+ if time <= 0 then
+ openingDoor = false
+ StopAnimTask(PlayerPedId(), "veh@break_in@0h@p_m_one@", "low_force_entry_ds", 1.0)
+ end
+ end
+ currentRegister = 0
+ end)
+end
+
+RegisterNUICallback('callcops', function(_, cb)
+ TriggerEvent("police:SetCopAlert")
+ cb('ok')
+end)
+
+RegisterNetEvent('SafeCracker:EndMinigame', function(won)
+ if currentSafe ~= 0 then
+ if won then
+ if currentSafe ~= 0 then
+ if not Config.Safes[currentSafe].robbed then
+ SetNuiFocus(false, false)
+ TriggerServerEvent("qb-storerobbery:server:SafeReward", currentSafe)
+ TriggerServerEvent("qb-storerobbery:server:setSafeStatus", currentSafe)
+ currentSafe = 0
+ takeAnim()
+ end
+ else
+ SendNUIMessage({
+ action = "kekw",
+ })
+ end
+ end
+ end
+ copsCalled = false
+end)
+
+RegisterNUICallback('PadLockSuccess', function(_, cb)
+ if currentSafe ~= 0 then
+ if not Config.Safes[currentSafe].robbed then
+ SendNUIMessage({
+ action = "kekw",
+ })
+ end
+ else
+ SendNUIMessage({
+ action = "kekw",
+ })
+ end
+ cb('ok')
+end)
+
+RegisterNUICallback('PadLockClose', function(_, cb)
+ SetNuiFocus(false, false)
+ copsCalled = false
+ cb('ok')
+end)
+
+RegisterNUICallback("CombinationFail", function(_, cb)
+ PlaySound(-1, "Place_Prop_Fail", "DLC_Dmod_Prop_Editor_Sounds", 0, 0, 1)
+ cb("ok")
+end)
+
+RegisterNUICallback('fail', function(_ ,cb)
+ if usingAdvanced then
+ if math.random(1, 100) < 20 then
+ TriggerServerEvent("qb-storerobbery:server:removeAdvancedLockpick")
+ TriggerEvent('inventory:client:ItemBox', QBCore.Shared.Items["advancedlockpick"], "remove")
+ end
+ else
+ if math.random(1, 100) < 40 then
+ TriggerServerEvent("qb-storerobbery:server:removeLockpick")
+ TriggerEvent('inventory:client:ItemBox', QBCore.Shared.Items["lockpick"], "remove")
+ end
+ end
+ if (IsWearingGloves() and math.random(1, 100) <= 25) then
+ local pos = GetEntityCoords(PlayerPedId())
+ TriggerServerEvent("evidence:server:CreateFingerDrop", pos)
+ QBCore.Functions.Notify(Lang:t("error.you_broke_the_lock_pick"))
+ end
+ lockpick(false)
+ cb('ok')
+end)
+
+RegisterNUICallback('exit', function(_, cb)
+ lockpick(false)
+ cb('ok')
+end)
+
+RegisterNUICallback('TryCombination', function(data, cb)
+ QBCore.Functions.TriggerCallback('qb-storerobbery:server:isCombinationRight', function(combination)
+ if tonumber(data.combination) ~= nil then
+ if tonumber(data.combination) == combination then
+ TriggerServerEvent("qb-storerobbery:server:SafeReward", currentSafe)
+ TriggerServerEvent("qb-storerobbery:server:setSafeStatus", currentSafe)
+ SetNuiFocus(false, false)
+ SendNUIMessage({
+ action = "closeKeypad",
+ error = false,
+ })
+ currentSafe = 0
+ takeAnim()
+ else
+ TriggerEvent("police:SetCopAlert")
+ SetNuiFocus(false, false)
+ SendNUIMessage({
+ action = "closeKeypad",
+ error = true,
+ })
+ currentSafe = 0
+ end
+ end
+ cb("ok")
+ end, currentSafe)
+end)
+
+RegisterNetEvent('qb-storerobbery:client:setRegisterStatus', function(batch, val)
+ -- Has to be a better way maybe like adding a unique id to identify the register
+ if(type(batch) ~= "table") then
+ Config.Registers[batch] = val
+ else
+ for k in pairs(batch) do
+ Config.Registers[k] = batch[k]
+ end
+ end
+end)
+
+RegisterNetEvent('qb-storerobbery:client:setSafeStatus', function(safe, bool)
+ Config.Safes[safe].robbed = bool
+end)
+
+RegisterNetEvent('qb-storerobbery:client:robberyCall', function(_, _, _, coords)
+ if (PlayerJob.name == "police" or PlayerJob.type == "leo") and onDuty then
+ PlaySound(-1, "Lose_1st", "GTAO_FM_Events_Soundset", 0, 0, 1)
+ TriggerServerEvent('police:server:policeAlert', Lang:t("email.storerobbery_progress"))
+
+ local transG = 250
+ local blip = AddBlipForCoord(coords.x, coords.y, coords.z)
+ SetBlipSprite(blip, 458)
+ SetBlipColour(blip, 1)
+ SetBlipDisplay(blip, 4)
+ SetBlipAlpha(blip, transG)
+ SetBlipScale(blip, 1.0)
+ BeginTextCommandSetBlipName('STRING')
+ AddTextComponentString(Lang:t("email.shop_robbery"))
+ EndTextCommandSetBlipName(blip)
+ while transG ~= 0 do
+ Wait(180 * 4)
+ transG = transG - 1
+ SetBlipAlpha(blip, transG)
+ if transG == 0 then
+ SetBlipSprite(blip, 2)
+ RemoveBlip(blip)
+ return
+ end
+ end
+ end
+end)
diff --git a/[qb]/qb-storerobbery/config.lua b/[qb]/qb-storerobbery/config.lua
new file mode 100644
index 0000000..33626ab
--- /dev/null
+++ b/[qb]/qb-storerobbery/config.lua
@@ -0,0 +1,72 @@
+Config = {}
+
+Config.minEarn = 100
+Config.maxEarn = 450
+Config.RegisterEarnings = math.random(Config.minEarn, Config.maxEarn)
+Config.MinimumStoreRobberyPolice = 2
+Config.resetTime = (60 * 1000) * 30
+Config.tickInterval = 1000
+
+Config.Registers = {
+ [1] = {vector3(-47.24,-1757.65, 29.53), robbed = false, time = 0, safeKey = 1, camId = 4},
+ [2] = {vector3(-48.58,-1759.21, 29.59), robbed = false, time = 0, safeKey = 1, camId = 4},
+ [3] = {vector3(-1486.26,-378.0, 40.16), robbed = false, time = 0, safeKey = 2, camId = 5},
+ [4] = {vector3(-1222.03,-908.32, 12.32), robbed = false, time = 0, safeKey = 3, camId = 6},
+ [5] = {vector3(-706.08, -915.42, 19.21), robbed = false, time = 0, safeKey = 4, camId = 7},
+ [6] = {vector3(-706.16, -913.5, 19.21), robbed = false, time = 0, safeKey = 4, camId = 7},
+ [7] = {vector3( 24.47, -1344.99, 29.49), robbed = false, time = 0, safeKey = 5, camId = 8},
+ [8] = {vector3(24.45, -1347.37, 29.49), robbed = false, time = 0, safeKey = 5, camId = 8},
+ [9] = {vector3(1134.15, -982.53, 46.41), robbed = false, time = 0, safeKey = 6, camId = 9},
+ [10] = {vector3(1165.05, -324.49, 69.2), robbed = false, time = 0, safeKey = 7, camId = 10},
+ [11] = {vector3(1164.7, -322.58, 69.2), robbed = false, time = 0, safeKey = 7, camId = 10},
+ [12] = {vector3(373.14, 328.62, 103.56), robbed = false, time = 0, safeKey = 8, camId = 11},
+ [13] = {vector3(372.57, 326.42, 103.56), robbed = false, time = 0, safeKey = 8, camId = 11},
+ [14] = {vector3(-1818.9, 792.9, 138.08), robbed = false, time = 0, safeKey = 9, camId = 12},
+ [15] = {vector3(-1820.17, 794.28, 138.08), robbed = false, time = 0, safeKey = 9, camId = 12},
+ [16] = {vector3(-2966.46, 390.89, 15.04), robbed = false, time = 0, safeKey = 10, camId = 13},
+ [17] = {vector3(-3041.14, 583.87, 7.9), robbed = false, time = 0, safeKey = 11, camId = 14},
+ [18] = {vector3(-3038.92, 584.5, 7.9), robbed = false, time = 0, safeKey = 11, camId = 14},
+ [19] = {vector3(-3244.56, 1000.14, 12.83), robbed = false, time = 0, safeKey = 12, camId = 15},
+ [20] = {vector3(-3242.24, 999.98, 12.83), robbed = false, time = 0, safeKey = 12, camId = 15},
+ [21] = {vector3(549.42, 2669.06, 42.15), robbed = false, time = 0, safeKey = 13, camId = 16},
+ [22] = {vector3(549.05, 2671.39, 42.15), robbed = false, time = 0, safeKey = 13, camId = 16},
+ [23] = {vector3(1165.9, 2710.81, 38.15), robbed = false, time = 0, safeKey = 14, camId = 17},
+ [24] = {vector3(2676.02, 3280.52, 55.24), robbed = false, time = 0, safeKey = 15, camId = 18},
+ [25] = {vector3(2678.07, 3279.39, 55.24), robbed = false, time = 0, safeKey = 15, camId = 18},
+ [26] = {vector3(1958.96, 3741.98, 32.34), robbed = false, time = 0, safeKey = 16, camId = 19},
+ [27] = {vector3(1960.13, 3740.0, 32.34), robbed = false, time = 0, safeKey = 16, camId = 19},
+ [28] = {vector3(1728.86, 6417.26, 35.03), robbed = false, time = 0, safeKey = 17, camId = 20},
+ [29] = {vector3(1727.85, 6415.14, 35.03), robbed = false, time = 0, safeKey = 17, camId = 20},
+ [30] = {vector3(-161.07, 6321.23, 31.5), robbed = false, time = 0, safeKey = 18, camId = 27},
+ [31] = {vector3(160.52, 6641.74, 31.6), robbed = false, time = 0, safeKey = 19, camId = 28},
+ [32] = {vector3(162.16, 6643.22, 31.6), robbed = false, time = 0, safeKey = 19, camId = 29},
+}
+
+Config.Safes = {
+ [1] = {vector4(-43.43, -1748.3, 29.42, 52.5), type = "keypad", robbed = false, camId = 4},
+ [2] = {vector4(-1478.94, -375.5, 39.16, 229.5), type = "padlock", robbed = false, camId = 5},
+ [3] = {vector4(-1220.85, -916.05, 11.32, 229.5), type = "padlock", robbed = false, camId = 6},
+ [4] = {vector4(-709.74, -904.15, 19.21, 229.5), type = "keypad", robbed = false, camId = 7},
+ [5] = {vector3(28.21, -1339.14, 29.49), type = "keypad", robbed = false, camId = 8},
+ [6] = {vector3(1126.77, -980.1, 45.41), type = "padlock", robbed = false, camId = 9},
+ [7] = {vector3(1159.46, -314.05, 69.2), type = "keypad", robbed = false, camId = 10},
+ [8] = {vector3(378.17, 333.44, 103.56), type = "keypad", robbed = false, camId = 11},
+ [9] = {vector3(-1829.27, 798.76, 138.19), type = "keypad", robbed = false, camId = 12},
+ [10] = {vector3(-2959.64, 387.08, 14.04), type = "padlock", robbed = false, camId = 13},
+ [11] = {vector3(-3047.88, 585.61, 7.9), type = "keypad", robbed = false, camId = 14},
+ [12] = {vector3(-3250.02, 1004.43, 12.83), type = "keypad", robbed = false, camId = 15},
+ [13] = {vector3(546.41, 2662.8, 42.15), type = "keypad", robbed = false, camId = 16},
+ [14] = {vector3(1169.31, 2717.79, 37.15), type = "padlock", robbed = false, camId = 17},
+ [15] = {vector3(2672.69, 3286.63, 55.24), type = "keypad", robbed = false, camId = 18},
+ [16] = {vector3(1959.26, 3748.92, 32.34), type = "keypad", robbed = false, camId = 19},
+ [17] = {vector3(1734.78, 6420.84, 35.03), type = "keypad", robbed = false, camId = 20},
+ [18] = {vector3(-168.40, 6318.80, 30.58), type = "padlock", robbed = false, camId = 27},
+ [19] = {vector3(168.95, 6644.74, 31.70), type = "keypad", robbed = false, camId = 30},
+}
+
+Config.MaleNoGloves = {
+ [0] = true, [1] = true, [2] = true, [3] = true, [4] = true, [5] = true, [6] = true, [7] = true, [8] = true, [9] = true, [10] = true, [11] = true, [12] = true, [13] = true, [14] = true, [15] = true, [18] = true, [26] = true, [52] = true, [53] = true, [54] = true, [55] = true, [56] = true, [57] = true, [58] = true, [59] = true, [60] = true, [61] = true, [62] = true, [112] = true, [113] = true, [114] = true, [118] = true, [125] = true, [132] = true,
+}
+Config.FemaleNoGloves = {
+ [0] = true, [1] = true, [2] = true, [3] = true, [4] = true, [5] = true, [6] = true, [7] = true, [8] = true, [9] = true, [10] = true, [11] = true, [12] = true, [13] = true, [14] = true, [15] = true, [19] = true, [59] = true, [60] = true, [61] = true, [62] = true, [63] = true, [64] = true, [65] = true, [66] = true, [67] = true, [68] = true, [69] = true, [70] = true, [71] = true, [129] = true, [130] = true, [131] = true, [135] = true, [142] = true, [149] = true, [153] = true, [157] = true, [161] = true, [165] = true,
+}
diff --git a/[qb]/qb-storerobbery/fxmanifest.lua b/[qb]/qb-storerobbery/fxmanifest.lua
new file mode 100644
index 0000000..bcf51ac
--- /dev/null
+++ b/[qb]/qb-storerobbery/fxmanifest.lua
@@ -0,0 +1,26 @@
+fx_version 'cerulean'
+game 'gta5'
+
+description 'QB-StoreRobbery'
+version '1.2.0'
+
+ui_page 'html/index.html'
+
+shared_scripts {
+ 'config.lua',
+ '@qb-core/shared/locale.lua',
+ 'locales/en.lua',
+ 'locales/*.lua'
+}
+
+client_script 'client/main.lua'
+server_script 'server/main.lua'
+
+files {
+ 'html/index.html',
+ 'html/script.js',
+ 'html/style.css',
+ 'html/reset.css'
+}
+
+lua54 'yes'
diff --git a/[qb]/qb-storerobbery/html/index.html b/[qb]/qb-storerobbery/html/index.html
new file mode 100644
index 0000000..f840783
--- /dev/null
+++ b/[qb]/qb-storerobbery/html/index.html
@@ -0,0 +1,93 @@
+
+
+
+
+
+
+
+
+ SY Lockpick
+
+
+
+
+
+
diff --git a/[qb]/qb-target/html/js/app.js b/[qb]/qb-target/html/js/app.js
new file mode 100644
index 0000000..fb0b331
--- /dev/null
+++ b/[qb]/qb-target/html/js/app.js
@@ -0,0 +1,159 @@
+const Targeting = Vue.createApp({
+ data() {
+ return {
+ Show: false, // leave this
+ ChangeTextIconColor: false, // This is if you want to change the color of the icon next to the option text with the text color
+ StandardEyeIcon: "far fa-eye", // This is the default eye icon
+ CurrentIcon: this.StandardEyeIcon, // leave this
+ SuccessColor: "rgb(30, 144, 255)", // This is the color when the target has found the option
+ StandardColor: "white", // This is the standard color, change this to the same as the StandardColor if you have changed it
+ TargetEyeStyleObject: {
+ color: this.StandardColor, // leave this
+ },
+ }
+ },
+ destroyed() {
+ window.removeEventListener("message", this.messageListener);
+ window.removeEventListener("mousedown", this.mouseListener);
+ window.removeEventListener("keydown", this.keyListener);
+ window.removeEventListener("mouseover", this.mouseOverListener);
+ window.removeEventListener("mouseout", this.mouseOutListener);
+ },
+ mounted() {
+ this.targetLabel = document.getElementById("target-label");
+
+ this.messageListener = window.addEventListener("message", (event) => {
+ switch (event.data.response) {
+ case "openTarget":
+ this.OpenTarget();
+ break;
+ case "closeTarget":
+ this.CloseTarget();
+ break;
+ case "foundTarget":
+ this.FoundTarget(event.data);
+ break;
+ case "validTarget":
+ this.ValidTarget(event.data);
+ break;
+ case "leftTarget":
+ this.LeftTarget();
+ break;
+ }
+ });
+
+ this.mouseListener = window.addEventListener("mousedown", (event) => {
+ let element = event.target;
+ if (element.id) {
+ const split = element.id.split("-");
+ if (split[0] === "target" && split[1] !== "eye" && event.button == 0) {
+ fetch(`https://${GetParentResourceName()}/selectTarget`, {
+ method: "POST",
+ headers: { "Content-Type": "application/json; charset=UTF-8" },
+ body: JSON.stringify(split[2])
+ }).then(resp => resp.json()).then(_ => {});
+ this.targetLabel.innerHTML = "";
+ this.Show = false;
+ }
+ }
+
+ if (event.button == 2) {
+ this.LeftTarget();
+ fetch(`https://${GetParentResourceName()}/leftTarget`, {
+ method: "POST",
+ headers: { "Content-Type": "application/json; charset=UTF-8" },
+ body: ""
+ }).then(resp => resp.json()).then(_ => {});
+ }
+ });
+
+ this.keyListener = window.addEventListener("keydown", (event) => {
+ if (event.key == "Escape" || event.key == "Backspace") {
+ this.CloseTarget();
+ fetch(`https://${GetParentResourceName()}/closeTarget`, {
+ method: "POST",
+ headers: { "Content-Type": "application/json; charset=UTF-8" },
+ body: ""
+ }).then(resp => resp.json()).then(_ => {});
+ }
+ });
+
+ this.mouseOverListener = window.addEventListener("mouseover", (event) => {
+ const element = event.target;
+ if (element.id) {
+ const split = element.id.split("-");
+ if (split[0] === "target" && split[1] === "option") {
+ event.target.style.color = this.SuccessColor;
+ if (this.ChangeTextIconColor) document.getElementById(`target-icon-${index}`).style.color = this.SuccessColor;
+ }
+ }
+ });
+
+ this.mouseOutListener = window.addEventListener("mouseout", (event) => {
+ const element = event.target;
+ if (element.id) {
+ const split = element.id.split("-");
+ if (split[0] === "target" && split[1] === "option") {
+ element.style.color = this.StandardColor;
+ if (this.ChangeTextIconColor) document.getElementById(`target-icon-${index}`).style.color = this.StandardColor;
+ }
+ }
+ });
+ },
+ methods: {
+ OpenTarget() {
+ this.targetLabel.innerHTML = "";
+ this.Show = true;
+ this.TargetEyeStyleObject.color = this.StandardColor;
+ },
+
+ CloseTarget() {
+ this.targetLabel.innerHTML = "";
+ this.TargetEyeStyleObject.color = this.StandardColor;
+ this.Show = false;
+ this.CurrentIcon = this.StandardEyeIcon;
+ },
+
+ FoundTarget(item) {
+ if (item.data) this.CurrentIcon = item.data;
+ else this.CurrentIcon = this.StandardEyeIcon;
+ this.TargetEyeStyleObject.color = this.SuccessColor;
+ },
+
+ ValidTarget(item) {
+ this.targetLabel.innerHTML = "";
+ for (let [index, itemData] of Object.entries(item.data)) {
+ if (itemData !== null) {
+ index = Number(index) + 1;
+
+ if (this.ChangeTextIconColor) {
+ this.targetLabel.innerHTML +=
+ `
+
+
+
+ ${itemData.label}
+
`;
+ } else {
+ this.targetLabel.innerHTML +=
+ `
+
+
+
+ ${itemData.label}
+
`;
+ }
+ }
+ }
+ },
+
+ LeftTarget() {
+ this.targetLabel.innerHTML = "";
+ this.CurrentIcon = this.StandardEyeIcon;
+ this.TargetEyeStyleObject.color = this.StandardColor;
+ }
+ }
+});
+
+Targeting.use(Quasar, { config: {} });
+Targeting.mount("#target-wrapper");
\ No newline at end of file
diff --git a/[qb]/qb-target/init.lua b/[qb]/qb-target/init.lua
new file mode 100644
index 0000000..8bd126b
--- /dev/null
+++ b/[qb]/qb-target/init.lua
@@ -0,0 +1,224 @@
+function Load(name)
+ local resourceName = GetCurrentResourceName()
+ local chunk = LoadResourceFile(resourceName, ('data/%s.lua'):format(name))
+ if chunk then
+ local err
+ chunk, err = load(chunk, ('@@%s/data/%s.lua'):format(resourceName, name), 't')
+ if err then
+ error(('\n^1 %s'):format(err), 0)
+ end
+ return chunk()
+ end
+end
+
+-------------------------------------------------------------------------------
+-- Settings
+-------------------------------------------------------------------------------
+
+Config = {}
+
+-- It's possible to interact with entities through walls so this should be low
+Config.MaxDistance = 7.0
+
+-- Enable debug options
+Config.Debug = false
+
+-- Supported values: true, false
+Config.Standalone = false
+
+-- Enable outlines around the entity you're looking at
+Config.EnableOutline = false
+
+-- Whether to have the target as a toggle or not
+Config.Toggle = false
+
+-- Draw a Sprite on the center of a PolyZone to hint where it's located
+Config.DrawSprite = false
+
+-- The default distance to draw the Sprite
+Config.DrawDistance = 10.0
+
+-- The color of the sprite in rgb, the first value is red, the second value is green, the third value is blue and the last value is alpha (opacity). Here is a link to a color picker to get these values: https://htmlcolorcodes.com/color-picker/
+Config.DrawColor = {255, 255, 255, 255}
+
+-- The color of the sprite in rgb when the PolyZone is targeted, the first value is red, the second value is green, the third value is blue and the last value is alpha (opacity). Here is a link to a color picker to get these values: https://htmlcolorcodes.com/color-picker/
+Config.SuccessDrawColor = {30, 144, 255, 255}
+
+-- The color of the outline in rgb, the first value is red, the second value is green, the third value is blue and the last value is alpha (opacity). Here is a link to a color picker to get these values: https://htmlcolorcodes.com/color-picker/
+Config.OutlineColor = {255, 255, 255, 255}
+
+-- Enable default options (Toggling vehicle doors)
+Config.EnableDefaultOptions = true
+
+-- Disable the target eye whilst being in a vehicle
+Config.DisableInVehicle = false
+
+-- Key to open the target eye, here you can find all the names: https://docs.fivem.net/docs/game-references/input-mapper-parameter-ids/keyboard/
+Config.OpenKey = 'LMENU' -- Left Alt
+
+-- Control for key press detection on the context menu, it's the Right Mouse Button by default, controls are found here https://docs.fivem.net/docs/game-references/controls/
+Config.MenuControlKey = 238
+
+-------------------------------------------------------------------------------
+-- Target Configs
+-------------------------------------------------------------------------------
+
+-- These are all empty for you to fill in, refer to the .md files for help in filling these in
+
+Config.CircleZones = {
+
+}
+
+Config.BoxZones = {
+
+}
+
+Config.PolyZones = {
+
+}
+
+Config.TargetBones = {
+
+}
+
+Config.TargetModels = {
+
+}
+
+Config.GlobalPedOptions = {
+
+}
+
+Config.GlobalVehicleOptions = {
+
+}
+
+Config.GlobalObjectOptions = {
+
+}
+
+Config.GlobalPlayerOptions = {
+
+}
+
+Config.Peds = {
+
+}
+
+-------------------------------------------------------------------------------
+-- Functions
+-------------------------------------------------------------------------------
+local function JobCheck() return true end
+local function GangCheck() return true end
+local function JobTypeCheck() return true end
+local function ItemCheck() return true end
+local function CitizenCheck() return true end
+
+CreateThread(function()
+ local state = GetResourceState('qb-core')
+ if state ~= 'missing' then
+ local timeout = 0
+ while state ~= 'started' and timeout <= 100 do
+ timeout += 1
+ state = GetResourceState('qb-core')
+ Wait(0)
+ end
+ Config.Standalone = false
+ end
+ if Config.Standalone then
+ local firstSpawn = false
+ local event = AddEventHandler('playerSpawned', function()
+ SpawnPeds()
+ firstSpawn = true
+ end)
+ -- Remove event after it has been triggered
+ while true do
+ if firstSpawn then
+ RemoveEventHandler(event)
+ break
+ end
+ Wait(1000)
+ end
+ else
+ local QBCore = exports['qb-core']:GetCoreObject()
+ local PlayerData = QBCore.Functions.GetPlayerData()
+
+ ItemCheck = QBCore.Functions.HasItem
+
+ JobCheck = function(job)
+ if type(job) == 'table' then
+ job = job[PlayerData.job.name]
+ if job and PlayerData.job.grade.level >= job then
+ return true
+ end
+ elseif job == 'all' or job == PlayerData.job.name then
+ return true
+ end
+ return false
+ end
+
+ JobTypeCheck = function(jobType)
+ if type(jobType) == 'table' then
+ jobType = jobType[PlayerData.job.type]
+ if jobType then
+ return true
+ end
+ elseif jobType == 'all' or jobType == PlayerData.job.type then
+ return true
+ end
+ return false
+ end
+
+ GangCheck = function(gang)
+ if type(gang) == 'table' then
+ gang = gang[PlayerData.gang.name]
+ if gang and PlayerData.gang.grade.level >= gang then
+ return true
+ end
+ elseif gang == 'all' or gang == PlayerData.gang.name then
+ return true
+ end
+ return false
+ end
+
+ CitizenCheck = function(citizenid)
+ return citizenid == PlayerData.citizenid or citizenid[PlayerData.citizenid]
+ end
+
+ RegisterNetEvent('QBCore:Client:OnPlayerLoaded', function()
+ PlayerData = QBCore.Functions.GetPlayerData()
+ SpawnPeds()
+ end)
+
+ RegisterNetEvent('QBCore:Client:OnPlayerUnload', function()
+ PlayerData = {}
+ DeletePeds()
+ end)
+
+ RegisterNetEvent('QBCore:Client:OnJobUpdate', function(JobInfo)
+ PlayerData.job = JobInfo
+ end)
+
+ RegisterNetEvent('QBCore:Client:OnGangUpdate', function(GangInfo)
+ PlayerData.gang = GangInfo
+ end)
+
+ RegisterNetEvent('QBCore:Player:SetPlayerData', function(val)
+ PlayerData = val
+ end)
+ end
+end)
+
+function CheckOptions(data, entity, distance)
+ if distance and data.distance and distance > data.distance then return false end
+ if data.job and not JobCheck(data.job) then return false end
+ if data.excludejob and JobCheck(data.excludejob) then return false end
+ if data.jobType and not JobTypeCheck(data.jobType) then return false end
+ if data.excludejobType and JobTypeCheck(data.excludejobType) then return false end
+ if data.gang and not GangCheck(data.gang) then return false end
+ if data.excludegang and GangCheck(data.excludegang) then return false end
+ if data.item and not ItemCheck(data.item) then return false end
+ if data.citizenid and not CitizenCheck(data.citizenid) then return false end
+ if data.canInteract and not data.canInteract(entity, distance, data) then return false end
+ return true
+end