Posts: 415
Threads: 145
Joined: Oct 2013
Reputation:
0
Hello guys, is possible to create trunk system, what will save weapons in it? I want to save weapons in trunk to .ini. For example how it should look. Player comes near trunk, he type some command, then will some dialog appear with 3 slots to save, then he can take weapons take back.. Rly big thx..
Posts: 235
Threads: 7
Joined: Nov 2013
Reputation:
0
Of course it's possible...
Create a file to each vehicle exist in your gamemode, and place them on a seperate folder, the index of the .txt files should have the vehicleid as the name of the file so it can be lately use, and store 3 variables inside each file or whatever amount of weapons you want.
When player wants to store a weapon, get the vehicle that he stands near, then format a string to that specific vehicleid file, and store x weapons in its variables (slots). Same goes with taking the guns, get the vehicleid and store inside them 0 on the slot you took. Not that hard.