This paper provides a theoretical basis for performing time limited planning within Belief-Desire-Intention (BDI) agents. The BDI agent architecture is recognised as one of the most popular architectures for developing agents for complex and dynamic environments, in addition to which they have a strong theoretical foundation. Recent work has extended a BDI agent specification language to include HTNstyle planning as a built-in feature. However, the extended semantics assume that agents have an unlimited amount of time available to perform planning, which is often not the case in many dynamic real world environments. We extend previous research by using ideas from anytime algorithms, and allow programmer control over the amount of time the agent spends on planning. We show that the resulting integrated agent specification language has advantages over regular BDI agent reasoning.