Module utils

Module utils 

Source
Expand description

This module contains various utilities for debugging and processing structs

Structs§

Benchmark
Benchmark struct, used for recording execution time desc: descriptor for benchmark inst: when benchmark timer was started

Functions§

b64_decode
Quick function for decoding base64 bytes
b64_encode
Quick function for encoding base64 bytes
clamp_to_values
Quick function for clamping val to the nearest value in clamps
dbg_write
Debug function that writes val to .debug file
get_local_levels_path
Returns path of CCLocalLevels.dat if it exists, otherwise return Err
proper_plist_tags
Replaces Robtop’s plist format with actual plist tags; i.e. <s> becomes <string>
properties_from_json
Converts properties in serde_json::Value dict to a HashMap<String, Value>
vec_as_str
Converts Vec<u8> utf8 to String