X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Futil.qc;h=2c6636a3b9a8bd8169ba0cacbc3c9b47cf9d6b92;hb=bcf94da3a222912685cb3f0c3a63ffd7536eba64;hp=bdf80e5d1cb92f698d3944743f7d4a5375258570;hpb=b7d32c1f333da63877913b30c861230243ce1213;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/util.qc b/qcsrc/common/util.qc index bdf80e5d1..2c6636a3b 100644 --- a/qcsrc/common/util.qc +++ b/qcsrc/common/util.qc @@ -2106,6 +2106,8 @@ float get_model_parameters(string m, float sk) get_model_parameters_weight = stof(s); if(c == "age") get_model_parameters_age = stof(s); + if(c == "description") + get_model_parameters_description = s; if(c == "bone_upperbody") get_model_parameters_bone_upperbody = s; if(c == "bone_weapon") @@ -2789,3 +2791,18 @@ float Mod_Q1BSP_NativeContentsFromSuperContents(float supercontents) return CONTENT_EMPTY; } #endif + +vector bezier_quadratic_getpoint(vector a, vector b, vector c, float t) +{ + return + (c - 2 * b + a) * (t * t) + + (b - a) * (2 * t) + + a; +} + +vector bezier_quadratic_getderivative(vector a, vector b, vector c, float t) +{ + return + (c - 2 * b + a) * (2 * t) + + (b - a) * 2; +}