]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/client/miscfunctions.qc
Macro macro macro macro macro macro
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / miscfunctions.qc
index 7951962e6be9086aeace7b011b83c62852fdddcb..f78a3923d2d9397867d44cdac7ca690d50abee4c 100644 (file)
@@ -573,6 +573,20 @@ vector getplayerorigin(float pl)
        return GETPLAYERORIGIN_ERROR;
 }
 
+vector getcsqcplayercolor(float pl)
+{
+       entity e;
+       
+       e = CSQCModel_server2csqc(pl);
+       if(e)
+       {
+               if(e.colormap > 0)
+                       return colormapPaletteColor(((e.colormap >= 1024) ? e.colormap : stof(getplayerkeyvalue(e.colormap - 1, "colors"))) & 0x0F, TRUE);
+       }
+       
+       return '1 1 1';
+}
+
 float getplayerisdead(float pl)
 {
        entity e;