]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/mutators/mutator/damagetext/cl_damagetext.qc
Merge branch 'master' into martin-t/dmgtext
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mutators / mutator / damagetext / cl_damagetext.qc
index a26ecdfa96349c48339e22fb2e7b98fa2661ae50..c6cc40effeda874c00bafb3f4c949c28e280e2f1 100644 (file)
@@ -161,8 +161,7 @@ CLASS(DamageText, Object)
             );
         }
 
-        if (this.text) strunzone(this.text);
-        this.text = strzone(s);
+        strcpy(this.text, s);
 
         this.m_size = map_bound_ranges(potential,
             autocvar_cl_damagetext_size_min_damage, autocvar_cl_damagetext_size_max_damage,
@@ -186,7 +185,7 @@ CLASS(DamageText, Object)
     }
 
     DESTRUCTOR(DamageText) {
-        if (this.text) strunzone(this.text);
+        strfree(this.text);
         if (this == DamageText_screen_first) {
             // start from 0 offset again, hopefully, others (if any) will have faded away by now
             DamageText_screen_first = NULL;