Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
v42-Josh committed Oct 20, 2023
2 parents 64f328b + 27cdb43 commit 8475192
Show file tree
Hide file tree
Showing 2 changed files with 69 additions and 4 deletions.
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2023 v42

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
52 changes: 48 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
# v42-notify
# v42-notify [QB/ESX]

Preview:
Support Discord: https://discord.com/invite/ackuWrBVV3

Showcase YouTube: https://www.youtube.com/watch?v=jLbM1542Xi8

![notify-thumb](https://github.com/v42-Josh/v42-notify/assets/135979159/5b79caa1-19eb-456d-9d2d-bd6869e78ad4)


### Manual
### QBCore Manual

- Change the following line in qb-core/client/functions.lua default line 88:

Expand Down Expand Up @@ -45,8 +47,50 @@ function QBCore.Functions.Notify(text, texttype, length)
end
```

**Press F8 and type the following:**
```
ensure v42-notify
```

QBCore usage:
QBCore.Functions.Notify("messagge here", 'success', 5000)

### ESX Manual

- Change the following line in es_extended/client/functions.lua default line 73:

Replace these function:
```
function ESX.ShowNotification(message, notifyType, length)
if GetResourceState("esx_notify") ~= "missing" then
return exports['esx-notify']:Notify(message, notifyType, length);
end
print("[^1ERROR^7] ^5ESX Notify^7 is Missing!")
end
```

Replace the above code with the following:

```
function ESX.ShowNotification(message, notifyType, length)
if GetResourceState("v42-notify") ~= "missing" then
return exports['v42-notify']:notify(message, notifyType, length);
end
print("[^1ERROR^7] ^5v42-notify^7 is Missing!")
end
```

**Enable EsxNotifcation option in the config.lua**

**Press F8 and type the following:**
```
ensure v42-notify
```

**Restart your server to enjoy your new notifications <3!**
ESX Usage:
ESX.ShowNotification("message here", "success", 5000);

Create custom Notifications in the config.lua
```
Expand Down

0 comments on commit 8475192

Please sign in to comment.