本文整理汇总了C++中SpriteCache::removeAll方法的典型用法代码示例。如果您正苦于以下问题:C++ SpriteCache::removeAll方法的具体用法?C++ SpriteCache::removeAll怎么用?C++ SpriteCache::removeAll使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SpriteCache
的用法示例。
在下文中一共展示了SpriteCache::removeAll方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: new_room
// new_room: changes the current room number, and loads the new room from disk
void new_room(int newnum,CharacterInfo*forchar) {
EndSkippingUntilCharStops();
Out::FPrint("Room change requested to room %d", newnum);
update_polled_stuff_if_runtime();
// we are currently running Leaves Screen scripts
in_leaves_screen = newnum;
// player leaves screen event
run_room_event(8);
// Run the global OnRoomLeave event
run_on_event (GE_LEAVE_ROOM, RuntimeScriptValue().SetInt32(displayed_room));
platform->RunPluginHooks(AGSE_LEAVEROOM, displayed_room);
// update the new room number if it has been altered by OnLeave scripts
newnum = in_leaves_screen;
in_leaves_screen = -1;
if ((playerchar->following >= 0) &&
(game.chars[playerchar->following].room != newnum)) {
// the player character is following another character,
// who is not in the new room. therefore, abort the follow
playerchar->following = -1;
}
update_polled_stuff_if_runtime();
// change rooms
unload_old_room();
if (psp_clear_cache_on_room_change)
{
// Delete all cached sprites
spriteset.removeAll();
// Delete all gui background images
for (int i = 0; i < game.numgui; i++)
{
delete guibg[i];
guibg[i] = NULL;
if (guibgbmp[i])
gfxDriver->DestroyDDB(guibgbmp[i]);
guibgbmp[i] = NULL;
}
guis_need_update = 1;
}
update_polled_stuff_if_runtime();
load_new_room(newnum,forchar);
}