marek12
Available for sprite works
- Joined
- Apr 8, 2020
- Messages
- 398
- Solutions
- 4
- Reaction score
- 394
Hi guys,
I am looking for a script that will allow only one player pass trough doors and only him or all the players on this one account.
I made an alter table in players called "room" in my database, what I am trying to do now is to allow the player to buy access to any room for 12hours.
Every room has it's own number so players know which room is which.
Now let's say player stay in front of room number 1 and type a command and buys it, now how do I make it that only him(or all players on same account) can access this room?
I don't know if I should do it with storage values or in database?
From what I know, If I want all the players in same account access this room it probably needs to be done in database(lua script but with db.Query function as well as creating new tables in db).
Would be also nice if I can make it work so if one player buy access to room 1, then if other player try to buy the same room it will show the cancel saying "Player XXX is owning this room at the moment".
I will be extremely thankful for your help. :3
Trying to learn new stuff all the time, I learned some lua in the past and now wanted try to something a bit harder, but unfortunately I don't know how to do it
I am looking for a script that will allow only one player pass trough doors and only him or all the players on this one account.
I made an alter table in players called "room" in my database, what I am trying to do now is to allow the player to buy access to any room for 12hours.
Every room has it's own number so players know which room is which.
Now let's say player stay in front of room number 1 and type a command and buys it, now how do I make it that only him(or all players on same account) can access this room?
I don't know if I should do it with storage values or in database?
From what I know, If I want all the players in same account access this room it probably needs to be done in database(lua script but with db.Query function as well as creating new tables in db).
Would be also nice if I can make it work so if one player buy access to room 1, then if other player try to buy the same room it will show the cancel saying "Player XXX is owning this room at the moment".
I will be extremely thankful for your help. :3
Trying to learn new stuff all the time, I learned some lua in the past and now wanted try to something a bit harder, but unfortunately I don't know how to do it