45 |                         
 57 |                         
 69 |                         
 81 |                         
 93 |                         
105 |                         
117 |                         
129 |                         ├── .gitignore ├── LICENSE ├── README.md └── cas-market ├── client ├── client_hook.lua └── main.lua ├── config.lua ├── fxmanifest.lua ├── html ├── Satoshi-Bold.otf ├── Satoshi-Regular.otf ├── app.css ├── app.js ├── home.png ├── images │ ├── weapon_flashlight.png │ ├── weapon_golfclub.png │ ├── weapon_gusenberg.png │ ├── weapon_hammer.png │ ├── weapon_hatchet.png │ ├── weapon_heavypistol.png │ ├── weapon_heavyshotgun.png │ ├── weapon_heavysniper.png │ ├── weapon_heavysniper_mk2.png │ ├── weapon_knife.png │ ├── weapon_knuckle.png │ ├── weapon_machete.png │ ├── weapon_machinepistol.png │ ├── weapon_microsmg.png │ └── weapon_smg_mk2.png ├── resim_2023-07-02_024117088-removebg-preview 1.png └── ui.html └── server ├── main.lua └── server_hook.lua /.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Lua sources 2 | luac.out 3 | 4 | # luarocks build files 5 | *.src.rock 6 | *.zip 7 | *.tar.gz 8 | 9 | # Object files 10 | *.o 11 | *.os 12 | *.ko 13 | *.obj 14 | *.elf 15 | 16 | # Precompiled Headers 17 | *.gch 18 | *.pch 19 | 20 | # Libraries 21 | *.lib 22 | *.a 23 | *.la 24 | *.lo 25 | *.def 26 | *.exp 27 | 28 | # Shared objects (inc. Windows DLLs) 29 | *.dll 30 | *.so 31 | *.so.* 32 | *.dylib 33 | 34 | # Executables 35 | *.exe 36 | *.out 37 | *.app 38 | *.i*86 39 | *.x86_64 40 | *.hex 41 | 42 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 Fatih 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # CAS-Market 2 | https://discord.gg/X8bTK9Stwk 3 | Hey everyone! 4 | Welcome to Code After S*x’s post. 5 | 6 | We are releasing CAS-BLACKMARKET script in this post, i hope you like it. 7 | 8 |  9 | 10 | Video: https://www.youtube.com/watch?v=-MheUh0hjFc 11 | 12 | #So what’s in this script? 13 | 14 | * This script working with ESX/QBCore 15 | * Detailed Config, what i can edit in config? Look at this photo; 16 |  17 | * Smooth and Nice UI design 18 | * Add item to cart 19 | * Increase the number of items in the basket 20 | * Decrease the number of items in the basket 21 | * Pay with bank 22 | * Pay with cash 23 | * Delete item in the basket 24 | * Using inventory patch for items 25 | * Using Sessionstore functions. 26 | * More optimized 27 | 28 | #How can i install this script? 29 | 30 | * Firstly, download file on my github. Click for github link 31 | * Move it to your resources file 32 | * Please change the filename to cas-market and keep it that way. 33 | * And start script, join server. 34 | 35 | #How can i change imagepatch? 36 | * Open app.js and look at first line 37 | 38 |  39 | 40 | * and change it according to your inventory. 41 | 42 | #I show you how to change the function to add items to your own inventory 43 | 44 | * First open server/server_hook.lua and find this; 45 | 46 |  47 | 48 | * then edit functions according to your inventory exports/functions. 49 | 50 | 51 | #How can i change notify export? 52 | * First open client_hook.lua and find this; 53 | 54 |  55 | 56 | * Change it according to your notify script’s export/function. 57 | 58 | 59 | 60 | 61 | 62 | -------------------------------------------------------------------------------- /cas-market/client/client_hook.lua: -------------------------------------------------------------------------------- 1 | if CAS.Framework == "qb" then 2 | QBCore = exports["qb-core"]:GetCoreObject() 3 | else 4 | ESX = exports["es_extended"]:getSharedObject() 5 | end 6 | 7 | 8 | 9 | Notify = function(text) 10 | if CAS.Framework == "qb" then 11 | return QBCore.Functions.Notify(text) 12 | else 13 | return ESX.ShowNotification(text) 14 | end 15 | end -------------------------------------------------------------------------------- /cas-market/client/main.lua: -------------------------------------------------------------------------------- 1 | 2 | 3 | Citizen.CreateThread(function() 4 | local pedCoords = CAS.PedCoords 5 | if CAS.Ped == nil then 6 | 7 | local pedHash = GetHashKey(CAS.PedHash) 8 | RequestModel(pedHash) 9 | while not HasModelLoaded(pedHash) do 10 | Wait(1) 11 | end 12 | CAS.Ped = CreatePed(1, pedHash, pedCoords.x, pedCoords.y, pedCoords.z-0.98, pedCoords.a, false, false) 13 | 14 | SetPedDefaultComponentVariation(ped) 15 | SetPedRandomProps(ped) 16 | SetPedRandomComponentVariation(ped, true) 17 | TaskStartScenarioInPlace(ped, "WORLD_HUMAN_SMOKING", 0, true) 18 | FreezeEntityPosition(ped, true) 19 | SetEntityInvincible(ped, true) 20 | SetBlockingOfNonTemporaryEvents(ped, true) 21 | end 22 | while true do 23 | local sleep = 750 24 | local ped = PlayerPedId() 25 | local coords = GetEntityCoords(ped) 26 | local distance = #(coords - vector3(pedCoords.x, pedCoords.y, pedCoords.z)) 27 | if distance < CAS.DrawDistance then 28 | sleep = 0 29 | DrawText3D(pedCoords.x, pedCoords.y, pedCoords.z+0.90, "[E] "..CAS.DrawText) 30 | if IsControlJustPressed(0, 38) then 31 | CASFunctions.DisplayUI() 32 | end 33 | end 34 | Citizen.Wait(sleep) 35 | end 36 | end) 37 | 38 | CASFunctions = { 39 | DisplayUI = function() 40 | local Items = {} 41 | for i in pairs(CAS.Items) do 42 | Items[#Items+1] = { 43 | label = CAS.Items[i].label, 44 | price = CAS.Items[i].price, 45 | imageSrc = CAS.Items[i].imageSrc, 46 | key = i, 47 | type = CAS.Items[i].type 48 | } 49 | end 50 | SendNUIMessage({ 51 | action = "market", 52 | items = Items 53 | }) 54 | SetNuiFocus(true,true) 55 | end 56 | } 57 | 58 | 59 | 60 | 61 | RegisterNUICallback("EscapeFromJs", function() 62 | SetNuiFocus(false,false) 63 | end) 64 | 65 | 66 | RegisterNUICallback("CompleteOrder", function(data, cb) 67 | print("yes") 68 | if not data.item or not data.price then return end 69 | print("none") 70 | if CAS.Framework == "qb" then 71 | QBCore.Functions.TriggerCallback("cas-server:BuyProducts",function(_) 72 | if (_) then 73 | Notify(CAS.CompleteText) 74 | end 75 | cb(_) 76 | end, data) 77 | elseif CAS.Framework == "esx" then 78 | ESX.TriggerServerCallback("cas-server:BuyProducts",function(_) 79 | if (_) then 80 | Notify(CAS.CompleteText) 81 | end 82 | cb(_) 83 | end,data) 84 | end 85 | end) 86 | 87 | 88 | function DrawText3D(x, y, z, text) 89 | SetTextScale(0.35, 0.35) 90 | SetTextFont(4) 91 | SetTextProportional(1) 92 | SetTextColour(255, 255, 255, 215) 93 | SetTextEntry('STRING') 94 | SetTextCentre(true) 95 | AddTextComponentString(text) 96 | SetDrawOrigin(x, y, z, 0) 97 | DrawText(0.0, 0.0) 98 | local factor = (string.len(text)) / 370 99 | DrawRect(0.0, 0.0 + 0.0125, 0.017 + factor, 0.03, 0, 0, 0, 75) 100 | ClearDrawOrigin() 101 | end 102 | -------------------------------------------------------------------------------- /cas-market/config.lua: -------------------------------------------------------------------------------- 1 | 2 | CAS = {} 3 | CAS.Framework = "qb" 4 | CAS.PedCoords = vector4(467.51, -1189.23, 29.29, 269.08) 5 | CAS.CompleteText = "Your order is complete, please check your inventory." 6 | CAS.PedHash = "csb_grove_str_dlr" 7 | CAS.DrawText = "Open Market" 8 | CAS.Ped = nil 9 | CAS.DrawDistance = 3 10 | CAS.Items = { 11 | ["weapon_pistol"] = { 12 | label = "Weapon Pistol", 13 | price = 100, 14 | imageSrc = "weapon_pistol", 15 | type = "weapon" 16 | }, 17 | ["weapon_heavypistol"] = { 18 | label = "Heavy Pistol", 19 | price = 300, 20 | imageSrc = "weapon_heavypistol", 21 | type = "weapon" 22 | }, 23 | ["lockpick"] = { 24 | label = "Lockpick", 25 | price = 300, 26 | imageSrc = "lockpick", 27 | type = "other" 28 | }, 29 | ["armor"] = { 30 | label = "Armor", 31 | price = 100, 32 | imageSrc = "armor", 33 | type = "other" 34 | }, 35 | ["bandage"] = { 36 | label = "Bandage", 37 | price = 300, 38 | imageSrc = "bandage", 39 | type = "other" 40 | }, 41 | ["acetone"] = { 42 | label = "Acetone", 43 | price = 300, 44 | imageSrc = "acetone", 45 | type = "other" 46 | }, 47 | ["cocaineleaf"] = { 48 | label = "Cocaine Leaf", 49 | price = 300, 50 | imageSrc = "cocaineleaf", 51 | type = "other" 52 | }, 53 | ["binoculars"] = { 54 | label = "Binoculars", 55 | price = 300, 56 | imageSrc = "binoculars", 57 | type = "other" 58 | }, 59 | ["cryptostick"] = { 60 | label = "Crypto Stick", 61 | price = 300, 62 | imageSrc = "cryptostick", 63 | type = "other" 64 | }, 65 | 66 | 67 | } 68 | -------------------------------------------------------------------------------- /cas-market/fxmanifest.lua: -------------------------------------------------------------------------------- 1 | fx_version 'adamant' 2 | game 'gta5' 3 | 4 | author 'MBL & URSU' 5 | description 'https://discord.gg/cas' 6 | 7 | lua54 'yes' 8 | version '1.0.0' 9 | 10 | client_scripts { 11 | 'config.lua', 12 | 'client/main.lua', 13 | 'client/client_hook.lua', 14 | } 15 | 16 | server_scripts { 17 | 'config.lua', 18 | 'server/server_hook.lua', 19 | 'server/main.lua', 20 | 21 | } 22 | 23 | ui_page 'html/ui.html' 24 | 25 | files { 26 | 'html/ui.html', 27 | 'html/app.css', 28 | 'html/app.js', 29 | 'html/*.png', 30 | 'html/*.otf', 31 | 'html/images/*.png' 32 | } -------------------------------------------------------------------------------- /cas-market/html/Satoshi-Bold.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mb-later/CAS-Market/519ec34863df9893c4f0b07735a7f957dd5360cd/cas-market/html/Satoshi-Bold.otf -------------------------------------------------------------------------------- /cas-market/html/Satoshi-Regular.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mb-later/CAS-Market/519ec34863df9893c4f0b07735a7f957dd5360cd/cas-market/html/Satoshi-Regular.otf -------------------------------------------------------------------------------- /cas-market/html/app.css: -------------------------------------------------------------------------------- 1 | 2 | @font-face { 3 | font-family: "Satoshi"; 4 | src: url(Satoshi-Bold.otf) 5 | } 6 | * { 7 | padding: 0; 8 | margin: 0; 9 | } 10 | 11 | 12 | 13 | .casNotify { 14 | display: flex; 15 | justify-content: center; 16 | align-items: center; 17 | width: auto; 18 | height: auto; 19 | left: 50%; 20 | transform: translate(-50%); 21 | position: absolute; 22 | 23 | flex-shrink: 0; 24 | border-radius: 19.911px; 25 | background: transparent; 26 | color: #BBB; 27 | font-size: 28.493px; 28 | font-family: Satoshi; 29 | font-style: normal; 30 | font-weight: 500; 31 | } 32 | 33 | 34 | .back-container { 35 | overflow: hidden; 36 | width: 100vw; 37 | height: 100vh; 38 | background-image: url("home.png"); 39 | background-size: cover; 40 | background-repeat: no-repeat; 41 | background-position: center; 42 | } 43 | 44 | 45 | 46 | .main-container { 47 | display: flex; 48 | position: absolute; 49 | top: 50%; 50 | left: 50%; 51 | transform: translate(-50%, -50%); 52 | width: 75%; 53 | height: 75%; 54 | } 55 | 56 | 57 | .left-container { 58 | width: 100%; 59 | margin-right: 3vh; 60 | } 61 | 62 | 63 | 64 | 65 | .header-div { 66 | display: flex; 67 | align-items: center; 68 | justify-content: center; 69 | width: 100%; 70 | height: 5vh; 71 | margin-bottom: 2vh; 72 | 73 | } 74 | 75 | .search-bar { 76 | display: flex; 77 | align-items: center; 78 | justify-content: flex-start; 79 | width: 100%; 80 | height: 100%; 81 | border-radius: 5.391px; 82 | padding-left: 2vh; 83 | border: 1.078px solid #3E3C41; 84 | background: radial-gradient(70.12% 70.12% at 50.00% 50.00%, rgba(67, 67, 67, 0.00) 0%, rgba(11, 10, 14, 0.10) 100%); 85 | } 86 | 87 | 88 | 89 | .searchBar-input { 90 | height: 100%; 91 | background: none; 92 | display: flex; 93 | align-items: center; 94 | justify-content: flex-start; 95 | border: none; 96 | outline: none; 97 | color: #8C8C8C; 98 | text-align: center; 99 | font-size: 1.5vh; 100 | font-family: Satoshi; 101 | font-style: normal; 102 | font-weight: 700; 103 | line-height: normal; 104 | } 105 | 106 | #svg { 107 | position: relative; 108 | left: 1vh; 109 | } 110 | 111 | 112 | .action-bar { 113 | display: flex; 114 | align-items: center; 115 | justify-content: flex-end; 116 | width: 70%; 117 | height: 100%; 118 | } 119 | 120 | 121 | .action { 122 | margin-left: 1.1vh; 123 | width: 5.4vh; 124 | height: 5.3vh; 125 | border-radius: 2.695px; 126 | outline: none; 127 | border: none; 128 | background: linear-gradient(141deg, rgba(217, 217, 217, 0.07) 0%, rgba(217, 217, 217, 0.00) 100%); 129 | } 130 | 131 | 132 | .item-body { 133 | display: flex; 134 | align-items: flex-start; 135 | justify-content: center; 136 | flex-wrap: wrap; 137 | width: 100%; 138 | height: 100%; 139 | overflow-y: auto; 140 | } 141 | 142 | .itemBox { 143 | padding: 2vh; 144 | display: flex; 145 | align-items: center; 146 | justify-content: center; 147 | flex-direction: column; 148 | margin: 1.4vh; 149 | width: 17vh; 150 | height: 14.5vh; 151 | border-radius: 6.324px; 152 | border: 1.265px solid #242226; 153 | background: radial-gradient(70.12% 70.12% at 50.00% 50.00%, rgba(255, 255, 255, 0.055) 0%, rgba(11, 10, 14, 0.10) 100%); 154 | } 155 | 156 | .img-box { 157 | width: 100%; 158 | display: flex; 159 | align-items: flex-start; 160 | justify-content: center; 161 | 162 | } 163 | 164 | .img-box img { 165 | width: 7vh; 166 | height: 7vh; 167 | } 168 | 169 | .item-name { 170 | height: 100%; 171 | width: 100%; 172 | display: flex; 173 | align-items: center; 174 | justify-content: center; 175 | color: #A4A4A4; 176 | font-size: 1.2vh; 177 | font-family: Satoshi; 178 | font-style: normal; 179 | font-weight: 700; 180 | line-height: normal; 181 | text-transform: uppercase; 182 | position: relative; 183 | top: 1vh; 184 | } 185 | 186 | .button-container { 187 | display: flex; 188 | align-items: center; 189 | justify-content: center; 190 | width: 100%; 191 | height: 100%; 192 | } 193 | 194 | .addToCart { 195 | color: #FFF; 196 | font-size: 1.1vh; 197 | font-family: Satoshi; 198 | font-style: normal; 199 | font-weight: 700; 200 | line-height: normal; 201 | border: none; 202 | outline: none; 203 | border-radius: 1.48px; 204 | background: #6C4FF5; 205 | box-shadow: 0px 0px 19.99262237548828px 0px rgba(108, 79, 245, 0.22); 206 | width: 9vh; 207 | height: 3.2vh; 208 | flex-shrink: 0; 209 | margin-right: 1vh; 210 | 211 | } 212 | 213 | .priceOfItem { 214 | display: flex; 215 | align-items: center; 216 | justify-content: center; 217 | color: #7D62F9; 218 | font-size: 1.2vh; 219 | font-family: Satoshi; 220 | font-style: normal; 221 | font-weight: 700; 222 | line-height: normal; 223 | width: 5vh; 224 | height: 3.2vh; 225 | border-radius: 1.48px; 226 | border: 0.6px solid #6C4FF5; 227 | background: rgba(108, 79, 245, 0.15); 228 | box-shadow: 0px 0px 19.99262237548828px 0px rgba(108, 79, 245, 0.22); 229 | } 230 | 231 | .active { 232 | border: 1px solid rgb(10, 10, 10); 233 | background: rgba(89, 33, 219, 0.623); 234 | } 235 | 236 | ::-webkit-scrollbar { 237 | width: 0.4vw; 238 | background: rgba(255, 255, 255, 0.13); 239 | } 240 | 241 | ::-webkit-scrollbar-thumb { 242 | background: #8D75EC; 243 | box-shadow: 0px 0px 4.2vh #8D75EC; 244 | border-radius: 0.4vh; 245 | } 246 | 247 | ::-webkit-scrollbar-thumb:hover { 248 | background: #8D75EC; 249 | box-shadow: 0px 0px 4.2vh #8D75EC; 250 | } 251 | 252 | 253 | 254 | 255 | .right-container { 256 | display: flex; 257 | align-items: center; 258 | justify-content: center; 259 | flex-direction: column; 260 | width: 70%; 261 | height: 100%; 262 | } 263 | 264 | 265 | .header-right { 266 | display: flex; 267 | align-items: flex-start; 268 | justify-content: center; 269 | flex-direction: column; 270 | width: 100%; 271 | margin-bottom: 1vh; 272 | } 273 | 274 | .header-top { 275 | color: #828282; 276 | font-size: 33.926px; 277 | font-family: Satoshi; 278 | font-style: normal; 279 | font-weight: 900; 280 | line-height: 162%; 281 | letter-spacing: 1.866px; 282 | margin: 0; 283 | } 284 | 285 | .footer-top { 286 | color: #575757; 287 | font-size: 20.214px; 288 | font-family: Satoshi; 289 | font-style: normal; 290 | font-weight: 500; 291 | line-height: 162%; 292 | margin: 0; 293 | /* letter-spacing: 1.112px; */ 294 | } 295 | 296 | .right-body { 297 | display: flex; 298 | padding-top: 3.4vh; 299 | padding-bottom: 3.4vh; 300 | justify-content: center; 301 | align-items: center; 302 | flex-direction: column; 303 | width: 100%; 304 | height: 100%; 305 | border-radius: 6.324px; 306 | border: 1.265px solid #242226; 307 | background: radial-gradient(70.12% 70.12% at 50.00% 50.00%, rgba(99, 99, 99, 0.00) 0%, rgba(11, 10, 14, 0.10) 100%); 308 | } 309 | 310 | 311 | .shopcart { 312 | display: flex; 313 | align-items: flex-start; 314 | justify-content: center; 315 | width: 90%; 316 | height: 100%; 317 | flex-wrap: wrap; 318 | overflow-x: auto; 319 | } 320 | 321 | 322 | .shopItem { 323 | display: flex; 324 | width: 100%; 325 | height: 11vh; 326 | border-radius: 5.717px; 327 | border: 1.143px solid #242226; 328 | margin-bottom: 2.1vh; 329 | background: radial-gradient(70.12% 70.12% at 50.00% 50.00%, rgba(99, 99, 99, 0.00) 0%, rgba(11, 10, 14, 0.10) 100%); 330 | } 331 | 332 | 333 | .shopItem-left { 334 | display: flex; 335 | align-items: center; 336 | justify-tracks: center; 337 | width: 100%; 338 | height: 100%; 339 | } 340 | 341 | .shopItem-img { 342 | display: flex; 343 | align-items: center; 344 | justify-content: center; 345 | width: 10vh; 346 | height: 100%; 347 | margin-right: 2vh; 348 | padding: 2vh; 349 | } 350 | 351 | .shopItem-img img { 352 | width: 8.5vh; 353 | height: 8vh; 354 | } 355 | 356 | .shopItem-right { 357 | display: flex; 358 | align-items: center; 359 | justify-content: center; 360 | width: 45%; 361 | height: 100%; 362 | position: relative; 363 | } 364 | 365 | .shopItem-info { 366 | display: flex; 367 | align-items: flex-start; 368 | justify-content: center; 369 | flex-direction: column; 370 | } 371 | 372 | .shopItem-name { 373 | color: #FFF; 374 | font-size: 14.969px; 375 | font-family: Satoshi; 376 | font-style: normal; 377 | font-weight: 700; 378 | line-height: 162%; 379 | letter-spacing: 0.823px; 380 | } 381 | 382 | .shopItem-price { 383 | color: #35FF93; 384 | font-size: 18.619px; 385 | font-family: Satoshi; 386 | font-style: normal; 387 | font-weight: 700; 388 | line-height: 162%; 389 | letter-spacing: 1.024px; 390 | } 391 | 392 | .countDown { 393 | display: flex; 394 | align-items: center; 395 | justify-content: center; 396 | width: 21.337px; 397 | height: 21.337px; 398 | border: none; 399 | outline: none; 400 | flex-shrink: 0; 401 | border-radius: 3.369px; 402 | background: rgba(245, 79, 79, 0.20); 403 | color: #F54F4F; 404 | font-size: 12.617px; 405 | font-family: Satoshi; 406 | font-style: normal; 407 | font-weight: 700; 408 | line-height: 162%; 409 | letter-spacing: 0.694px; 410 | } 411 | 412 | .currentCount { 413 | display: flex; 414 | align-items: center; 415 | justify-content: center; 416 | width: 51.214px; 417 | height: 24.259px; 418 | flex-shrink: 0; 419 | border-radius: 3.594px; 420 | background: rgba(108, 79, 245, 0.20); 421 | color: #A693FF; 422 | font-size: 12.617px; 423 | font-family: Satoshi; 424 | font-style: normal; 425 | font-weight: 700; 426 | line-height: 162%; 427 | letter-spacing: 0.694px; 428 | } 429 | 430 | .countUp { 431 | display: flex; 432 | align-items: center; 433 | justify-content: center; 434 | width: 21.337px; 435 | height: 21.337px; 436 | border: none; 437 | outline: none; 438 | flex-shrink: 0; 439 | border-radius: 3.369px; 440 | background: rgba(79, 245, 116, 0.20); 441 | color: #4FF574; 442 | font-size: 12.617px; 443 | font-family: Satoshi; 444 | font-style: normal; 445 | font-weight: 700; 446 | line-height: 162%; 447 | letter-spacing: 0.694px; 448 | } 449 | 450 | .act-btn { 451 | margin-right: 0.77vh; 452 | } 453 | 454 | .right-altBody { 455 | display: flex; 456 | justify-content: center; 457 | align-items: center; 458 | flex-direction: column; 459 | width: 100%; 460 | height: 50%; 461 | } 462 | 463 | 464 | .total-div { 465 | height: 100%; 466 | width: 100%; 467 | } 468 | 469 | 470 | 471 | 472 | .total-div { 473 | display: flex; 474 | width: 85%; 475 | align-items: center; 476 | justify-content: center; 477 | } 478 | 479 | .total-text { 480 | display: flex; 481 | align-items: center; 482 | justify-content: flex-start; 483 | width: 50%; 484 | height: 100%; 485 | color: #676767; 486 | font-size: 24.593px; 487 | font-family: Satoshi; 488 | font-style: normal; 489 | font-weight: 700; 490 | } 491 | 492 | .total-price { 493 | width: 50%; 494 | display: flex; 495 | align-items: center; 496 | justify-content: flex-end; 497 | height: 100%; 498 | color: #9A85FF; 499 | font-size: 30.655px; 500 | font-family: Satoshi; 501 | font-style: normal; 502 | font-weight: 900; 503 | line-height: 162%; 504 | letter-spacing: 1.686px; 505 | } 506 | 507 | 508 | 509 | .shopping-act-div { 510 | display: flex; 511 | align-items: center; 512 | justify-content: center; 513 | height: 100%; 514 | width: 85%; 515 | } 516 | 517 | 518 | .left-btn-cont { 519 | display: flex; 520 | align-items: center; 521 | justify-content: flex-start; 522 | width: 100%; 523 | height: 100%; 524 | } 525 | .right-btn-cont { 526 | display: flex; 527 | align-items: center; 528 | justify-content: flex-end; 529 | width: 100%; 530 | height: 100%; 531 | } 532 | .paywithcard { 533 | display: flex; 534 | align-items: center; 535 | justify-content: center; 536 | width: 19vh; 537 | height: 5.1vh; 538 | color: #FAFAFA; 539 | font-size: 13.054px; 540 | font-family: Satoshi; 541 | font-style: normal; 542 | font-weight: 600; 543 | line-height: 162%; 544 | letter-spacing: 0.718px; 545 | outline: none; 546 | border: none; 547 | border-radius: 2.193px; 548 | background: #9A85FF; 549 | } 550 | 551 | .paywithcash { 552 | display: flex; 553 | align-items: center; 554 | justify-content: center; 555 | width: 19vh; 556 | height: 5.1vh; 557 | color: #1A1A1A; 558 | font-size: 13.054px; 559 | font-family: Satoshi; 560 | font-style: normal; 561 | font-weight: 600; 562 | line-height: 162%; 563 | letter-spacing: 0.718px; 564 | outline: none; 565 | border: none; 566 | border-radius: 2.193px; 567 | background: #FF85A2; 568 | } 569 | -------------------------------------------------------------------------------- /cas-market/html/app.js: -------------------------------------------------------------------------------- 1 | var inventoryPatch = "nui://qb-inventory/html/images" 2 | 3 | 4 | window.addEventListener("message",function(data){ 5 | let item = data.data 6 | if (item.action == "market") { 7 | ShowMarket(item.items) 8 | } 9 | }) 10 | 11 | 12 | const ShowMarket = function(data) { 13 | console.log(JSON.stringify(data)) 14 | $("div.back-container").fadeIn(300, function() { 15 | let values = "" 16 | $("div.main-container").fadeIn(500) 17 | if (data.length > 0) { 18 | for (let index = 0; index < data.length; index++) { 19 | const element = data[index]; 20 | values = ` 21 |
 24 |                     
 69 |