Garry's Mod

Garry's Mod

Give Random Weapons - CSGO Case Inspired
 This topic has been pinned, so it's probably important
Froze  [developer] 2 Jan, 2024 @ 11:49pm
CASE CREATOR TUTORIAL
https://www.youtube.com/watch?v=HWWRNd6Iy-o


CREATING A CASE
1. Type "!grw case_creator" in chat or "give_random_cases_case_creator" in console.

2. A derma menu will pop up. I will only explain non self explanatory things.

3. First, to understand it, type "Test Case 1" in the case name text field.

4. Click the case rarity combo box ("Choose Rarity...") and pick Common.

5. Custom case icons are acceptable but you need to restart your game:
- Open your garrysmod/addons folder --> create a new folder named "grw_icons_addon"
- Inside grw_icons, create a folder called materials, then inside it a folder called "grw_icons"
- Put a .png file that you want for the custom case (preferrably sized 512x512)
- Rename the .png file to "custom_icon_1.png"
- If you haven't, restart garry's mod
- Open the case creator menu and inside case icon, type "grw_icons/custom_icon_1.png"

6. To insert weapons, you need their weapon class name. the text field offers an autocomplete that appears if you press space, and filters the autocomplete results to what you type. For example if you type "arccw_" then the autocomplete will be filled with arccw_ classnames.

7. Click the class name of the weapon you want. After clicking, hover over the text, and it will reveal the print name ("arccw_ur_db" --> "IZh-58") in case you're not sure what weapon it is.

8. Choose the rarity for your weapon. Drop chance is controlled by rarity. Press insert after choosing.

9. An entry will appear in the case drops table / listview.

10. Repeat the process of adding in new weapons.

11. If you inputted a mistake, then rapidly click on the entry, it will be removed.

12. Once you have what you want, click the "CREATE CASE" button. The fields will be cleaned up and your case is ready to be dropped by npcs and opened with !grw open [your case name]

It's possible to create cases that skips rarities! you don't have to input every single type of rarity in the weapons loot table.

MODIFYING A CASE
If you want to remove or add more weapons to a case:
1. Open the case creator, left click the case name text field, press space.
2. An autocomplete will appear listing the cases you've made. Click on the case you want to modify.
3. The text field will be filled with the case name, then press backspace on the last character in the text field. (if Test Case 1, then Test Case 1 --> pres backspace --> Test Case --> press 1 on your keyboard --> Test Case 1)
4. The case drops table will be filled up with Test Case 1's loot table.
5. Add and or remove as you need, then Pick the case rarity (has to be the same rarity as before) and press CREATE CASE.
6. Your old case data is now replaced with the new data.

DELETING A CASE
To remove a case, simply click on an autocomplete in the case name, and click the Delete button on the right.
Last edited by Froze; 2 Jan, 2024 @ 11:58pm
< >
Showing 1-15 of 18 comments
Froze  [developer] 2 Jan, 2024 @ 11:54pm 
RARITY DROP RATES:

COMMON
50.39%

UNCOMMON
25.2%

RARE
12.6%

MYTHICAL
6.3%

LEGENDARY
3.15%

ANCIENT
1.57%

IMMORTAL
0.79%
RedCapGreenCap 7 Jan, 2024 @ 6:42pm 
If Possible, make it so that crates save between game sessions. Its a pain having to create cases every single time I want to play with them enabled
Froze  [developer] 7 Jan, 2024 @ 7:21pm 
Originally posted by RedCapGreenCap:
If Possible, make it so that crates save between game sessions. Its a pain having to create cases every single time I want to play with them enabled
crates do save between game sessions
if u press space on the case name after laoding a different map, it will fill in with your already created cases

but i will take a look into the code if i missed anything.
Last edited by Froze; 7 Jan, 2024 @ 7:23pm
Froze  [developer] 7 Jan, 2024 @ 8:47pm 
Originally posted by RedCapGreenCap:
If Possible, make it so that crates save between game sessions. Its a pain having to create cases every single time I want to play with them enabled
fixed, i forgot to add the code that loads the .json file containing the stored cases' data.
RedCapGreenCap 8 Jan, 2024 @ 8:00pm 
Also If possible, please consider adding Bio-Annihalation 2 support. Its a really good mod and i hope you can add cases to these npc's when you get to it.
https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2416750969
Froze  [developer] 8 Jan, 2024 @ 8:02pm 
Originally posted by RedCapGreenCap:
Also If possible, please consider adding Bio-Annihalation 2 support. Its a really good mod and i hope you can add cases to these npc's when you get to it.
https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2416750969
What do you mean? what is there to be supported? i am unfamiliar with bio annihilation 2.
Peacekeeper 1 Feb, 2024 @ 11:11pm 
not sure what he meant is the BIo-Annihilation NPC's will have crate drop supported?
Froze  [developer] 2 Feb, 2024 @ 1:11am 
Originally posted by RedCapGreenCap:
Also If possible, please consider adding Bio-Annihalation 2 support. Its a really good mod and i hope you can add cases to these npc's when you get to it.
https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2416750969


Originally posted by Peacekeeper:
not sure what he meant is the BIo-Annihilation NPC's will have crate drop supported?

I'm attempting it, but no guarantees.
Peacekeeper 2 Feb, 2024 @ 7:16am 
hope anyone will see this, also your addon is good man.
was putting my weapons with your GWR - crate addon :steamthumbsup:
Last edited by Peacekeeper; 2 Feb, 2024 @ 7:23am
GabeeeHD 11 Jun, 2024 @ 4:12am 
how do i disable the default case from dropping?
Froze  [developer] 11 Jun, 2024 @ 4:33am 
Originally posted by GabeeeHD:
how do i disable the default case from dropping?
go over give_random_cases_ console commands, it's there i forgot what it is
GabeeeHD 11 Jun, 2024 @ 5:03pm 
Originally posted by Froze:
Originally posted by GabeeeHD:
how do i disable the default case from dropping?
go over give_random_cases_ console commands, it's there i forgot what it is
i will check thx
GabeeeHD 12 Jun, 2024 @ 10:54pm 
Originally posted by Froze:
Originally posted by GabeeeHD:
how do i disable the default case from dropping?
go over give_random_cases_ console commands, it's there i forgot what it is
btw this is a bug i think, but when i get a case it also appears for my friend that THEY got the case
Froze  [developer] 12 Jun, 2024 @ 11:12pm 
Originally posted by GabeeeHD:
Originally posted by Froze:
go over give_random_cases_ console commands, it's there i forgot what it is
btw this is a bug i think, but when i get a case it also appears for my friend that THEY got the case
thanks for this info, might be fixed
GabeeeHD 13 Jun, 2024 @ 7:17pm 
Originally posted by Froze:
Originally posted by GabeeeHD:
btw this is a bug i think, but when i get a case it also appears for my friend that THEY got the case
thanks for this info, might be fixed
tell me when it gets fixed thx
< >
Showing 1-15 of 18 comments
Per page: 1530 50