Skip to content
Snippets Groups Projects
Commit 7dfadbfa authored by dg's avatar dg
Browse files

smooth shadows work in non-fbo mode

git-svn-id: http://svn.net-core.org/repos/t-engine4@2765 51575b47-30f0-44d4-a5cc-537603b46e54
parent c9a4ccd3
No related branches found
No related tags found
No related merge requests found
......@@ -712,7 +712,7 @@ function _M:display(nb_keyframes)
map:display(0, 0, nb_keyframes, config.settings.tome.smooth_fov)
if self.level.data.foreground then self.level.data.foreground(self.level, 0, 0, nb_keyframes) end
if self.level.data.weather_particle then self.state:displayWeather(self.level, self.level.data.weather_particle, nb_keyframes) end
if config.settings.tome.smooth_fov then map._map:updateSeensTexture() map._map:drawSeensTexture(nb_keyframes) end
if config.settings.tome.smooth_fov then map._map:updateSeensTexture() map._map:drawSeensTexture(0, 0, nb_keyframes) end
self.fbo:use(false)
_2DNoise:bind(1, false)
......@@ -722,10 +722,11 @@ function _M:display(nb_keyframes)
-- Basic display; no FBOs
else
if self.level.data.background then self.level.data.background(self.level, map.display_x, map.display_y, nb_keyframes) end
map:display(nil, nil, nb_keyframes)
map:display(nil, nil, nb_keyframes, config.settings.tome.smooth_fov)
self.target:display()
if self.level.data.foreground then self.level.data.foreground(self.level, map.display_x, map.display_y, nb_keyframes) end
if self.level.data.weather_particle then self.state:displayWeather(self.level, self.level.data.weather_particle, nb_keyframes) end
if config.settings.tome.smooth_fov then map._map:updateSeensTexture() map._map:drawSeensTexture(map.display_x, map.display_y, nb_keyframes) end
end
if not self.zone_name_s then self:updateZoneName() end
......
......@@ -814,9 +814,11 @@ static int map_update_seen_texture(lua_State *L)
static int map_draw_seen_texture(lua_State *L)
{
map_type *map = (map_type*)auxiliar_checkclass(L, "core{map}", 1);
int nb_keyframes = luaL_checknumber(L, 2);
int x = -map->tile_w;
int y = -map->tile_h;
int x = lua_tonumber(L, 2);
int y = lua_tonumber(L, 3);
int nb_keyframes = luaL_checknumber(L, 4);
x += -map->tile_w;
y += -map->tile_h;
int w = (map->mwidth + 3) * map->tile_w;
int h = (map->mheight + 3) * map->tile_h;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment