[Release][ESX][Abandoned] New Reworked Bank Robbery System

No problem I like this version of the script and its how people learn.

Mainly (I tell you because I have no time right now to fix it) there are 3 different a counter (yeah a little ugly) one at client side , to know how many time less have to display, other at blowtorch clientside, to know how many time rest to stop animation , and other in holdupbank are server side, to control everything important about the time in the resource

is there an easy yay to change the time it takes for the blowtorch?

Yes im familiar with the Citzen.Wait functionality, its just that the animation was broken, fortunately Jack_Frost had the fix!

I guess what i mean is so instead of taking 5 mins could i change it to lets say 2 mins

For those want black money! Just set in server.lua in line 109 or 110
to this xPlayer.addAccountMoney (ā€˜black_moneyā€™, bank.reward)

1 Like

Doors do not close! (I already did tried just about everything). :sweat_smile:

I donā€™t know why but my server isent loading the script :confused:

Doors dont close and my bank stil continius after player gets black money

2 Likes

Tried it here everything worked and stopped when it should and I ended up with $25 Million black_money lol.
For the doors they reset, but if I leave the bank and teleport to a shop were I put the items for testing and TP back they are closed and I still have a cool down. Also if I donā€™t TP and stay for the whole cool down they reset.So their hit and miss I guess when they close.

1 Like

Man this resource is rough. I donā€™t see why it requires 4 resources to run one very basic script. This could all be compiled into one resource.

I will give it to you that it is a cool resource, it is just rough. I donā€™t have the time or will power to improve this but someone should.

Well, really it was my first script, maybe you are right, i just wanted to no reinventing the wheel, if Ā”there are already resources that do what i need, i pref dont duplicate code.

Finally a astute person, A gameobject (any like props) are only at client side, this mean are in memory with all data at client not a server, so this props have a default value for position, heading, textures,etc and much more, GtaV like any RPG game, to load the bigs map properly is divided by chunks (Remember the chunks? yeah, minecraft, other rpg game based), so, if there are not people at that chunk that chunk isnt loaded by any person, so the server will not load too (If there are any server data, remember props are client side only) So if a gameobject like a door is clientside only and the server will not save any state about it, how we sync it to open it? easy; saying to all client to open it for a time, but if we stop to say to all people to open it? easy: the clients will load automatically the normal state for that props (default data), which is closed (But remember there are other server script saying to all client the door is closed, yeah, esx_doorlock) SO -> if holdupbank is running a robbery the door will be open BUT if a robbery is finished or canceled, not more message to clients to set ā€œopen stateā€ will be send, so when THAT chunk go out of memory of the clients and loaded into memory other time (go far and go near other time) the door will be with the default state-> closed

Advantages of this crasy logic? -> 0 duplicate code, useless code or reiventing the wheel, if there are a resource that close the door, i dont need do it other time , just say to client dont open any more (That noccurs when robbery canceled or finished, if you want use a timer to auto reset the actual robbery, do it our self, you have the event for that)

I hope my horrible English and my explanation not get you crasy

Finish or cancel robbery -> go far -> come back -> see the magic

How do you put the items in the store or blackmarket?

in the database

Even after the robbery has finished, police still see the circle over the bank as if the robbery was still happening. Anyway to fix? Also I cant figure out how to get the door at blaine county savings bank to lock before being hacked and unlock after being hacked?
https://gyazo.com/bca0496ca309c6ed4cd6a6f15be4995e

Ok so I tried getting the door to lock at blaine county savings bank. I tried using the following code and adding it to the config file part of esx_doorlock. And the door is locked, but once you start the hacking. The actual main vault door closes on you? Im not sure what to do here. Any suggestions would be appreciated.

{
objName = ā€˜v_ilev_cbankvaulgate01ā€™,
objCoords = vector3(-105.11, 6472.81, 31.63),
textCoords = vector3(-105.11, 6472.81, 31.63),
authorizedJobs = { ā€˜policeā€™ },
locked = true,
distance = 0,
size = 0

}

*EDIT Tried the same thing with the other door at blaine county and got a similar issue. After the hack the door just barley opens and canā€™t get through

For the people using this script, I seem to be running into an issue. Every now and then, when people try the big bank robbery it seems to cause the server to lag out.

Itā€™s always filled with 32 people, and on restarted I tested and went through and did all three banks and they all worked perfectly. Only code Iā€™ve changed was making it so the blips/notifications that got stuck would disappear instead of always stay up.

So after the server was running for a few hours, someone hit the big bank and upon trying to place C4 it got stuck at 0 seconds and then the server hit a hugeeeeeeeeee hitch warning of 150k+. This is the second time itā€™s happened after someone trying the bank so I figured Iā€™d see if anyone else is having this issue, or if itā€™s just something else or conflicting with something I may have.

i have the same problem like you, if i failed to hack the door code. The sever gonna lagging, very very slow respond. It will be a big problem if someone fails to hacking.

1 Like