[RELEASE][ESX] KASHacters Multi Character

esx
characters

#22

Awesome realease.
Unfortunatly i am getting this error.

Error: (node:1592) UnhandledPromiseRejectionWarning: TypeError: Cannot convert undefined or null to object
    at Function.values (<anonymous>)
    at execute.then (mysql-async.js:5002:48)
Error: (node:1592) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
Error: (node:1592) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
[MySQL] [Slow Query Warning] [kashacters] [51594ms] UPDATE `addon_account_data` SET `owner` = 'Char1:1100001067b9109' WHERE `owner` = 'steam:1100001067b9109'
[ERROR] [MySQL] [kashacters] An error happens on MySQL for query "[object Object]": ER_LOCK_WAIT_TIMEOUT: Lock wait timeout exceeded; try restarting transaction
Error: (node:1592) UnhandledPromiseRejectionWarning: AssertionError [ERR_ASSERTION]: unexpected PromiseRejectEvent
    at process.<anonymous> (internal/process/promises.js:27:25)
    at <anonymous>
    at Query.db.query [as _callback] (mysql-async.js:4973:13)
    at Query.Sequence.end (mysql-async.js:280:24)
    at Query.ErrorPacket (mysql-async.js:2122:8)
    at Protocol._parsePacket (mysql-async.js:5941:23)
    at Parser.write (mysql-async.js:6198:12)
    at Protocol.write (mysql-async.js:5701:16)
    at Socket.<anonymous> (mysql-async.js:693:28)
    at emitOne (events.js:116:13)
Error: (node:1592) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
Error: (node:1592) UnhandledPromiseRejectionWarning: Error: ER_LOCK_WAIT_TIMEOUT: Lock wait timeout exceeded; try restarting transaction
    at Query.Sequence._packetToError (mysql-async.js:244:14)
    at Query.ErrorPacket (mysql-async.js:2109:18)
    at Protocol._parsePacket (mysql-async.js:5941:23)
    at Parser.write (mysql-async.js:6198:12)
    at Protocol.write (mysql-async.js:5701:16)
    at Socket.<anonymous> (mysql-async.js:693:28)
    at emitOne (events.js:116:13)
    at Socket.emit (events.js:211:7)
    at addChunk (_stream_readable.js:263:12)
    at readableAddChunk (_stream_readable.js:250:11)
    --------------------
    at Pool.query (mysql-async.js:4728:23)
    at Promise (mysql-async.js:4970:12)
    at new Promise (<anonymous>)
    at execute (mysql-async.js:4967:26)
    at Object.global.exports [as callback] (mysql-async.js:4993:5)
    at citizen:/scripting/v8/main.js:87:41
Error: (node:1592) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 3)

#23

Awesome!


#24

Did you implement the SQL portion of the install?


#25

yes i did what the readme told me. So i got to the point where i click on one of the box. Then i click my character then it stays high in the sky looking down to the city and its blurry. And if i check my server cmd then i saw that error.


#26

Nice and good name!


#27

How did u fix the camera floating problem i got the same :frowning:


#28

I didn’t as of yet


#29

The problem of not triggering the "kashactersC:SpawnCharacter" is mostly because a lot of people didn’t edit the local IdentifierTables (on line 5) the right way, either there is a column thats wrong or a table that is wrong. The event won’t trigger because there is not a result when searching for the wrong columns or tables so make SURE that the IdentifierTables are edited correctly.

And for the esx_status, I didn’t see any problem on my server you might need to add

if xPlayer ~= nil then

end

under the local xPlayer part and put the rest of the code in between the if statement


#30

Nice Release Man, LOVE IT GOOD WORK :smile:


#31

Great release, does this change the job based on the character? If so do we need to make changes?


#32

Seems decent.


#34

haHAA


#35

I’ve got some questions:

  • Does all es_extended/server/classes/player.lua work?
  • How does es_extended & essentialmode know which character is choosed?
  • If an user is admin and changes character is he still a admin?

I just want to know if it does all this stated above.


#36

Roles will be changed becuase of the following:

What this script does it manipulates ESX for loading characters
So when you are choosing your character it changes your steam id which is normally steam:<yourid> to Char<charid>:<yourid> this prevents ESX from loading another character because it is looking for you exact steamid. So when you choose your character it will change it from Char<charid>:<yourid> to your normal steam id (steam:<yourid>). When creating a new character it will spawn you without an exact steamid which creates a new database entry for your steamid

As for player functions and classes it should work fine because it loads in with the exact steamid, I have some people that have problems with the PlayerFunctions but I have tested them and they worked fine.


#37

Well done.


#38

I edited the post a bit which will solve a lot of problems:
THE RESOURCE NAME SHOULD BE esx_kashacters BECAUSE OF THE JAVASCRIPT

Thnx @Ludvig_Bartholdsson for the headsup


#39

i have read the README but everytime i get in game the menu openes up but i cant click on anything

EDIT nevermind i have fixed it


#40

I actually saw this on your github last night. I was wondering what was going to come of this and decided to wait. This is really cool and a lot of people that use esx have requested it thank you for your contribution and skills!


#41

Awesome yup that fixed my problem :smiley: I love your script. Thank your very much :stuck_out_tongue: You made someone very happy :smiley: woot woot


#42

When I made the second character I got an error on the server window and it even didn’t bring up a Name,lastname,height and birth table to let me register the second character and when I wen’t to database I saw under the user_lastcharacter table it changed my charId from 1 to 2.So I gues its not working for me.