This isn’t supported anymore, stop using it or figure it out yourself
Fantastic work as always, I have a better anim for you if you’re interested. When I get home I’ll PM you.
Yeah would love some to test, all the laying down ones I try you end up floating above the stupid things no matter what the coords you TP the ped to.
EDIT: Woops, just realized that the other day when I had changed around code I didn’t move defining the indexes I’m using for effects so it was being redefined every iteration. Should actually work now LOL. Oopsie
Pushed changes to it, added camera while in bed. It’s meh, but definitely better than what it was before. Added different animation, getting out animation is odd but not terrible. Fixed beds not being set as unoccupied if a player disconnects while in it. Also removed a few bits from my framework that I had missed so should actually work. Sorry about that
missing dependency mythic_base i took it out of the resource.lua and didnt fix it is it anywhere else?
nvm i found it forgot to implement framework and its billing/local for char in server.lua
Little new here
but i have all mythic_progbar mythic_notify and mythic_hosptial
all are on the server as we speak, but none of them work.
like if i get hurt it dosn’t work for example “spine hurts” etc
Am i missing something?
Saw someone wrote something about mythic_base, but can’t find that and i saw on another post it’s not publically out.
Anyone that can help me a little to get these to work?
Is the resource running? Like it started?
I derped and forgot to remove the dependency for mythic_base from the resource file, so pull latest changes from github and see if it works (Or remove it from the resource file yourself). Though depending when you downloaded the source there were changes that I had made to remove more framework stuff I missed before (Main issue being export call and the while loops checking a variable that isn’t used in the released version)
If it still doesn’t work, restart resource and check F8 for any errors
Hey, just wanted to say great job!
Just having a little issue on the part where you try to get out of bed. I’m sure it’s a simple fix but I’m no code genius.
It seems I can’t get out of bed or break the camera, and if I do manage to get out of bed the camera seems to be stuck in a birds eye view. Seems the script is failing to fire for me at a certain part I’m just struggling to find it.
In client/main.lua it should be in the LeaveBed() function.
RenderScriptCams(0, true, 1, true, true)
DestroyCam(cam, false)
Are you getting any errors? Is it actually healing you?
got it to work after removing this:
dependencies {
‘mythic_base’,
‘mythic_progbar’,
‘mythic_notify’,
But after getting hurt the notifications stays on the screen for a short time then disapear
How can i get the notifications to actually stay on the screen until healed?
And no after checking into Pillbox
the bed are not healing me
The notification pops up that doctors are healing you but no healing actual takes place. Then after that it seems can’t get out of bed.
I have another script that allows me to break animation but that doesn’t break the camera angle, hence you’ll just be walking around in birds eye view. Update with the error -
Started resource mythic_hospital-master
Error running system event handling function for resource mythic_hospital-master: citizen:/scripting/lua/scheduler.lua:41: Failed to execute thread: @mythic_hospital-master/server/main.lua:68: attempt to index a nil value (local ‘injuries’)
stack traceback:
@mythic_hospital-master/server/main.lua:68: in upvalue ‘handler’
citizen:/scripting/lua/scheduler.lua:219: in function citizen:/scripting/lua/scheduler.lua:218
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/scheduler.lua:41: in field ‘CreateThreadNow’
citizen:/scripting/lua/scheduler.lua:218: in function citizen:/scripting/lua/scheduler.lua:182
Change server\wound.lua
local playerInjury = {}
ESX = nil
TriggerEvent(‘esx:getSharedObject’, function(obj) ESX = obj end)
function GetCharsInjuries(source)
return playerInjury[source]
end
RegisterServerEvent(‘mythic_hospital:server:SyncInjuries’)
AddEventHandler(‘mythic_hospital:server:SyncInjuries’, function(data)
local src = source
playerInjury[src] = data
end)
Bleh, dammit. Seems I forgot even more changes for removing my framework stuff. Sorry >_>.
If you’re using ESX, can do @AbdulkadirAktas change. If you aren’t using ESX or don’t want it to be ESX dependant replace server/wound.lua with ;
local playerInjury = {}
function GetCharsInjuries(source)
return playerInjury[source]
end
RegisterServerEvent('mythic_hospital:server:SyncInjuries')
AddEventHandler('mythic_hospital:server:SyncInjuries', function(data)
playerInjury[source] = data
end)
And that should fix it.
Both of you are champions! thanks for doing gods work my friends.
Hmm
Using ESX and i copied in AbdulkadirAktas’s code but still i can’t seem to get a heal after checking in
also the camera won’t change for me, it’s stuck in birds eye view
As of right now, the best you can do is go into the notifications and change their duration to be the same long as it takes for an iteration to occur (30 seconds by default).
Standard, injury notifications show every 30 seconds for 15 seconds and bleeeding shows every 30 seconds for 25 seconds. If it’s not showing for that long, you may have an old mythic_notify.
I am planning on adding to my notification resource though to have that, just haven’t gotten around to it yet.
Restart server and delete cache folder.
I did restart
Is it the same error?
If it is, can you paste your entire wound.lua server file?