mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-03-27 08:09:31 +00:00
Tools directory for ticket #1
This commit is contained in:
parent
ecfd936095
commit
8337cad7ee
207 changed files with 25761 additions and 0 deletions
17
Tools/projectGenerator/smarty/plugins/modifier.uid.php
Normal file
17
Tools/projectGenerator/smarty/plugins/modifier.uid.php
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<?php
|
||||
|
||||
// Written for GarageGames project generator Xcode files
|
||||
|
||||
// Map a file path to a unique 23-digit number [unique for the life of the PHP execution]
|
||||
function smarty_modifier_uid($string)
|
||||
{
|
||||
static $uid = 1;
|
||||
static $map = array();
|
||||
|
||||
if ( !array_key_exists( $string, $map ) )
|
||||
$map[$string] = sprintf( "%023X", $uid++ );
|
||||
|
||||
return $map[$string];
|
||||
}
|
||||
|
||||
?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue