[RELEASE] [PAID] Magic Script (w/ Logs) [QBCore]

Hi all! This is a “magic” script that adds different usable potions to your server. Currently, it includes potions of teleportation, speed, healing, speed, hallucination, and summoning. In the coming days and weeks, I will continue updating the script with more and more potions for players to mess around with. I hope you all enjoy and find this useful for the players on your server!

Features:
↳ Logs
↳ Extensive configuration
↳ Clean/minimal potion inventory images
↳ 6 unique potions
… and even more coming in future updates!

Dependencies:
QBCore Framework

Buy ($10):
Tebex

Showcase:

Magic Script (w/ Logs) | @NadPlayz (Try this link if preview does not work)

Configuration:

Config = {}
Locale = {}
Config.markerColor = {}

-- [[ 🟢 Configuration 🟢 ]] --

-- QBCore
Config.qbVersion = 'new' -- Change to 'new' if you are using the new QBCore version. If you do not, core functions of the script will simply not work!

-- General
Config.keybind = 18 -- Keybind to select potion position (https://docs.fivem.net/docs/game-references/controls/)
Config.minTime = 1000 -- Minimum amount of time it takes to use the potions
Config.maxTime = 2000 -- Maximum amount of time it takes to use the potions
Config.distance = 1.90 -- Max distance away from the marker you can to be for the potion to work on you
Config.infiniteUse = true -- Do not remove the potion after one use

-- Notifications
Config.notifications = true -- Enable notifications for the target players
Config.notificationType = "success" -- Type of notification to send

-- Particle Animation (https://gist.github.com/alexguirre/af70f0122957f005a5c12bef2618a786)
Config.particleDict = "scr_josh3"
Config.particleName = "scr_josh3_light_explosion"

-- Animation (https://alexguirre.github.io/animations-list/)
Config.animDict = "anim@mp_point"
Config.anim = "1st_person_med_blocked"

-- Marker
Config.markerType = 27 -- Type of the marker (https://docs.fivem.net/docs/game-references/markers/)
Config.markerSize = 1.5 -- Size of the marker
Config.markerColor['r'] = 120 -- Color of the marker (R)
Config.markerColor['g'] = 120 -- Color of the marker (G)
Config.markerColor['b'] = 0 -- Color of the marker (B)

-- Logs
Config.enableLogs = true -- Change this to false if you want to disable logs
Config.logToFile = false -- Change this to false if you do not want to log to a file // NOTE: Must have a 'log.txt' file in the resource folder.
Config.printToConsole = true -- Change this to false if you do not want every event to print to server console
Config.logToDiscord = false -- Change this to true and set the webhook URL below if you want every event to be sent to a Discord webhook
Config.discordWebhook = "" -- Make sure to set the above option to true if you wish to send logs to Discord

-- [[ 🔴 Configuration 🔴 ]] --


-- [[ 🟢 Locale 🟢 ]] --

-- Progress bar
Locale.progressBar = "Using potion"

-- Notifications
Locale.teleportation = "Woah, you teleported!"
Locale.speed = "You feel speedy!"
Locale.invisibility = "Where'd you go?"
Locale.hallucination = "I feel dizzy..."
Locale.summon = "You were summoned!"

-- Logs
Locale.name = "Magic Potions"
Locale.logTeleportation = " used a teleportation potion."
Locale.logHealing = " used a healing potion."
Locale.logSpeed = " used a speed potion."
Locale.logInvisibility = " used an invisibility potion."
Locale.logHallucination = " used a hallucination potion."
Locale.logSummon = " used a summon potion."

-- [[ 🔴 Locale 🔴 ]] --

Note:
Protected by FiveM Asset Escrow system.

If you have any questions, please feel free to message me here - I would be more than happy to help. I appreciate feedback and constructive criticism. Thank you! :heart:

3 Likes

so well done!
THIS IS PERFECT!

1 Like

Thank you so much! :heart:

1 Like

Feels so weird bro I’d done this in the past for my framework, actually it’s still there iirc it was such a fun thing to work on!

1 Like

Oh, that’s sick! I had a lot of fun making this as well. Thanks for your comment!

1 Like

no problem!

Think this could ever be for esx? I would get this in a heartbeat if so