ds_priority_find_priority

Finds and returns the priority of the given value in the priority queue.

语法:

ds_priority_find_priority(id, val);


参数 描述
id The id of the priority queue to use.
val The value to find the priority of.


Returns: Real or undefined


描述

With this function you can retrieve the priority of any given value. If the value does not exist in the priority queue then undefined will be returned.


例如:

p = ds_priority_find_priority(ai_priority, "intelligence");

The above code will store the returned priority for the given value in the instance variable "p".


上一页: DS Priority Queues
下一页: ds_priority_copy
© Copyright YoYo Games Ltd. 2018 All Rights Reserved