So i'm playing a bit with the new rendering engine, but i noticed it crashing a few times.
So basically i have a few sprites in the background, and 1 line.
Then i'm rendering a sprite on the player, just because i can
rendering.draw_sprite{time_to_live = 2, sprite=file, orientation=game.players[1].character.orientation, x_scale=1, y_scale=1, target=game.players[1].character, surface=1}
I attached the scenario, dump and log file.
and a short video what it does.
Re: [0.17.36] Crash with rendering sprite.
Posted: Fri May 03, 2019 6:49 pm
by Bilka
It's crashing in rendering entities, not script rendering. Considering that your example does not include entities (except the player), could you post a log where it crashes with only your example setup?
Re: [0.17.36] Crash with rendering sprite.
Posted: Fri May 03, 2019 6:51 pm
by tha_snoetje
Just crashed again, prob the same thing but added the dump again.
Re: [0.17.36] Crash with rendering sprite.
Posted: Fri May 03, 2019 6:52 pm
by tha_snoetje
Oh I thought it was sprite rendering related, didn't read the log that well
Re: [0.17.36] Crash with rendering sprite.
Posted: Fri May 03, 2019 6:58 pm
by tha_snoetje
There isn't any entity build on the map, so i don't know what i should do
i just started the attached scenario, and kept it running for 10 minutes or so.
i could strip it down a bit further and only do the image attached to the player.
I will do that and let you know the results
Re: [0.17.36] Crash with rendering sprite.
Posted: Fri May 03, 2019 7:15 pm
by tha_snoetje
Okay crashed again, While doing nothing, I just loaded the scenario and walked a bit, and then stood still until it crashed. Also didn't build any entity.
I removed all the other code,
So on this crash only this code was running:
##############################################
global.frame = 1
local function tick()
file = "file/gif"..global.frame..".png"
rendering.draw_sprite{time_to_live = 2, sprite=file, orientation=game.players[1].character.orientation, x_scale=1, y_scale=1, target=game.players[1].character, surface=1}
if game.tick % 6 == 0 then
global.frame = global.frame + 1
if global.frame > 20 then
global.frame = 1
end
end
end
event.add(defines.events.on_tick, tick)
--event.add(defines.events.on_player_created, OnPlayerCreated)
--event.add(defines.events.on_player_respawned, on_player_respawned)
event.add(defines.events.on_tick, tick)
############################################
I noticed i'm running the on_tick event twice, so i will remove it once just to check if the same happens.
Re: [0.17.36] Crash with rendering sprite.
Posted: Fri May 03, 2019 7:16 pm
by Bilka
Hey, we figured out how to reproduce this (take a screenshot) and are working on a solution, thank you for the scenario for easy reproduction. So you don't need to investigate further.
Re: [0.17.36] Crash with rendering sprite.
Posted: Fri May 03, 2019 7:18 pm
by tha_snoetje
Oh nice,
Does the game make screenshots in the background/automaticly then?
Re: [0.17.36] Crash with rendering sprite.
Posted: Fri May 03, 2019 7:28 pm
by Bilka
It makes a screenshot when it autosaves.
Re: [posila] [0.17.36] Crash with rendering sprite.