We study a pathwise local time of even integer order p >= 2, defined as an occupation density, for continuous functions with finite pth variation along a sequence of time partitions. With this notion of local time and a new definition of the Follmer integral, we establish Tanaka-type change-of-variable formulas in a pathwise manner. We also derive some identities involving this high-order pathwise local time, each of which generalizes a corresponding identity from the theory of semimartingale local time. We then use collision local times between multiple functions of arbitrary regularity to study the dynamics of ranked continuous functions.