Hosting and domain costs until October 2024 have been generously sponsored by dumptruck_ds. Thank you!
Editing DP QC ENTITYDATA
From Quake Wiki
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 21: | Line 21: | ||
'''WARNING:''' .entity fields cannot be saved and restored between map loads as they will leave dangling pointers. Entity fields might still be useful, for example if you wish to dump entities straight to a web server for inspection there, in the event of an error. | '''WARNING:''' .entity fields cannot be saved and restored between map loads as they will leave dangling pointers. Entity fields might still be useful, for example if you wish to dump entities straight to a web server for inspection there, in the event of an error. | ||
− | + | ''numentityfields'' returns the number of entity fields. NOT offsets. Vectors comprise 4 fields: v, v_x, v_y and v_z. | |
− | + | ''entityfieldname'' returns the name as a string, eg. "origin" or "classname" or whatever. | |
− | + | ''entityfieldtype'' returns a value that the constants represent, but the field may be of another type in more exotic progs.dat formats or compilers. | |
− | + | ''getentityfieldstring'' returns data as would be written to a savegame, eg... "0.05" (float), "0 0 1" (vector), or "Hello World!" (string). Function names can also be returned. | |
− | + | ''putentityfieldstring'' puts the data returned by getentityfieldstring back into the entity. | |
− |