ABSTRACT

This chapter presents how to optimize a Goal-Oriented Action Planning (GOAP)-like planning procedure with actions as text files and forward breadth-first search so that it becomes practical to implement planning. It also presents the necessary steps before going into any optimization campaign, with examples specific to practical planning. The chapter describes what can be optimized in practical planning, focusing on practical planning data structures that lead to both runtime and memory footprint improvements. Planning generates sequences of actions called plans. Practical planning for game artificial intelligence (AI) refers to a planning procedure that fits in the AI budget of a game and supports playability so that nonplayer characters execute actions from the plans generated by this planning procedure. GOAP as the first ever implementation of practical planning for the game. There are two main features to optimize in practical planning: time and memory.