]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge remote-tracking branch 'origin/master' into Mario/mutators
authorSamual Lenks <samual@xonotic.org>
Thu, 8 Aug 2013 19:20:05 +0000 (15:20 -0400)
committerSamual Lenks <samual@xonotic.org>
Thu, 8 Aug 2013 19:20:05 +0000 (15:20 -0400)
defaultXonotic.cfg
qcsrc/client/command/cl_cmd.qc
qcsrc/client/csqc_builtins.qc [deleted file]
qcsrc/client/particles.qc
qcsrc/client/projectile.qc
qcsrc/client/target_music.qc
qcsrc/common/mapinfo.qc
qcsrc/dpdefs/csprogsdefs.qc
qcsrc/server/g_world.qc
qcsrc/warpzonelib/common.qc

index 48a7b58cbcb11cd328219d406f4945df929f9383..392ba9f905e0bf926931b4abad05386e1e2b5015 100644 (file)
@@ -37,6 +37,8 @@ alias -hook -button6
 alias use "impulse 21"
 
 // for backwards compatibility
+// TODO Remove after 0.8 release!
+cl_particles_forcetraileffects 1
 
 alias dropweapon "impulse 17"
 alias +show_info +button7
@@ -994,19 +996,22 @@ set con_completion_vnextmap       map
 set con_completion_vdomap      map
 set con_completion_playermodel models/player/*.iqm
 
+// helper
 // these non-saved engine cvars shall be saved
-seta cl_port $cl_port
-seta r_showsurfaces $r_showsurfaces
-seta r_ambient $r_ambient
-seta skill 4
-seta gl_finish $gl_finish
-seta v_kicktime $v_kicktime
-seta r_subdivisions_tolerance $r_subdivisions_tolerance
-seta vid_gl20 $vid_gl20
-seta vid_gl13 $vid_gl13
-seta r_drawviewmodel $r_drawviewmodel
-seta v_idlescale $v_idlescale
-seta net_slist_queriespersecond $net_slist_queriespersecond
+alias makesaved "seta $1 \"${$1 ?}\"
+makesaved cl_maxfps_alwayssleep
+makesaved cl_port
+makesaved gl_finish
+makesaved net_slist_queriespersecond
+makesaved r_ambient
+makesaved r_drawviewmodel
+makesaved r_showsurfaces
+makesaved r_subdivisions_tolerance
+makesaved skill
+makesaved vid_gl13
+makesaved vid_gl20
+makesaved v_idlescale
+makesaved v_kicktime
 
 // ticrate
 //sys_ticrate 0.0166667
index 7926544d4b785d06c06aadf75377b0686c03c0a3..cbf294fa8a2f6598851d29f1f098dad3e121d524 100644 (file)
@@ -26,7 +26,7 @@ void LocalCommand_blurtest(float request)
 {
        // Simple command to work with postprocessing temporarily... possibly completely pointless, the glsl shader is used for a real feature now...
        // Anyway, to enable it, just compile the client with -DBLURTEST and then you can use the command.
-       
+
        #ifdef BLURTEST
        switch(request)
        {
@@ -57,6 +57,57 @@ void LocalCommand_blurtest(float request)
        #endif
 }
 
+void LocalCommand_boxparticles(float request, float argc)
+{
+       switch(request)
+       {
+               case CMD_REQUEST_COMMAND:
+               {
+                       if (argc == 9)
+                       {
+                               float effect = particleeffectnum(argv(1));
+                               if (effect >= 0)
+                               {
+                                       float index = stof(argv(2));
+                                       entity own;
+                                       if(index <= 0)
+                                               own = entitybyindex(-index);
+                                       else
+                                               own = findfloat(world, entnum, index);
+                                       vector org_from = stov(argv(3));
+                                       vector org_to = stov(argv(4));
+                                       vector dir_from = stov(argv(5));
+                                       vector dir_to = stov(argv(6));
+                                       float countmultiplier = stof(argv(7));
+                                       float flags = stof(argv(8));
+                                       boxparticles(effect, own, org_from, org_to, dir_from, dir_to, countmultiplier, flags);
+                                       return;
+                               }
+                       }
+               }
+
+               default:
+                       print("Incorrect parameters for ^2boxparticles^7\n");
+               case CMD_REQUEST_USAGE:
+               {
+                       print("\nUsage:^3 lv_cmd boxparticles effectname own org_from org_to, dir_from, dir_to, countmultiplier, flags\n");
+                       print("  'effectname' is the name of a particle effect in effectinfo.txt\n");
+                       print("  'own' is the entity number of the owner (negative for csqc ent, positive for svqc ent)\n");
+                       print("  'org_from' is the starting origin of the box\n");
+                       print("  'org_to' is the ending origin of the box\n");
+                       print("  'dir_from' is the minimum velocity\n");
+                       print("  'dir_to' is the maximum velocity\n");
+                       print("  'countmultiplier' defines a multiplier for the particle count (affects count only, not countabsolute or trailspacing)\n");
+                       print("  'flags' can contain:\n");
+                       print("    1 to respect globals particles_alphamin, particles_alphamax (set right before via prvm_globalset client)\n");
+                       print("    2 to respect globals particles_colormin, particles_colormax (set right before via prvm_globalset client)\n");
+                       print("    4 to respect globals particles_fade (set right before via prvm_globalset client)\n");
+                       print("    128 to draw a trail, not a box\n");
+                       return;
+               }
+       }
+}
+
 void LocalCommand_create_scrshot_ent(float request)
 {
        switch(request)
@@ -351,6 +402,7 @@ void LocalCommand_(float request)
 // Normally do not hard code aliases for these, instead create them in commands.cfg... also: keep in alphabetical order, please ;)
 #define CLIENT_COMMANDS(request,arguments) \
        CLIENT_COMMAND("blurtest", LocalCommand_blurtest(request), "Feature for testing blur postprocessing") \
+       CLIENT_COMMAND("boxparticles", LocalCommand_boxparticles(request, arguments), "Spawn particles manually") \
        CLIENT_COMMAND("create_scrshot_ent", LocalCommand_create_scrshot_ent(request), "Create an entity at this location for automatic screenshots") \
        CLIENT_COMMAND("debugmodel", LocalCommand_debugmodel(request, arguments), "Spawn a debug model manually") \
        CLIENT_COMMAND("handlevote", LocalCommand_handlevote(request, arguments), "System to handle selecting a vote or option") \
diff --git a/qcsrc/client/csqc_builtins.qc b/qcsrc/client/csqc_builtins.qc
deleted file mode 100644 (file)
index 0fabb0d..0000000
+++ /dev/null
@@ -1,359 +0,0 @@
-void (vector ang)                                                      makevectors = #1;
-void(entity e, vector o) setorigin     = #2;
-void (entity e, string m)                                              setmodel = #3;
-void(entity e, vector min, vector max) setsize = #4;
-
-void ()                                                                        break = #6;
-float ()                                                               random = #7;
-void (entity e, float chan, string samp, float vol, float atten)       sound = #8;
-vector (vector v)                                                      normalize = #9;
-void (string e)                                                                error = #10;
-void (string e)                                                                objerror = #11;
-float (vector v)                                                       vlen = #12;
-float (vector v)                                                       vectoyaw = #13;
-entity ()                                                              spawn = #14;
-void (entity e)                                                                remove = #15;
-
-void (vector v1, vector v2, float nomonsters, entity forent)           traceline = #16;
-
-entity (entity start, .string fld, string match)                       find = #18;
-string (string s)                                                      precache_sound = #19;
-string (string s)                                                      precache_model = #20;
-
-void (string s, ...)                                           dprint = #25;
-string (float f)                                                       ftos = #26;
-string (vector v)                                                      vtos = #27;
-void ()                                                                        coredump = #28;
-void ()                                                                        traceon = #29;
-void ()                                                                        traceoff = #30;
-void (entity e)                                                                eprint = #31;
-
-float (float v)                                                                rint = #36;
-float (float v)                                                                floor = #37;
-float (float v)                                                                ceil = #38;
-
-float (vector v)                                                       pointcontents = #41;
-float (float f)                                                                fabs = #43;
-
-float (string s)                                                       cvar = #45;
-void (string s, ...)                                                   localcmd = #46;
-entity (entity e)                                                      nextent = #47;
-
-vector (vector v)                                                      vectoangles = #51;
-vector (vector v, vector w)                                                    vectoangles2 = #51;
-
-void (string var, string val)                                          cvar_set = #72;
-
-
-float()                                                                        ReadByte = #360;
-float()                                                                        ReadChar = #361;
-float()                                                                        ReadShort = #362;
-float()                                                                        ReadLong = #363;
-float()                                                                        ReadCoord = #364;
-float()                                                                        ReadAngle = #365;
-string()                                                               ReadString = #366;      //warning: this returns a temporary!
-
-float(string s)                                                                stof = #81;
-
-
-void (vector v1, vector min, vector max, vector v2, float nomonsters, entity forent)   tracebox = #90;
-float (string name, string value, ...)                                 registercvar = #93;
-
-entity (entity start, .entity fld, entity match)                       findentity = #98;
-entity (entity start, .float fld, float match)                         findfloat = #98;
-
-float (string s)                                                       checkextension = #99;
-
-float (string filename, float mode)                                    fopen = #110;
-void (float fhandle)                                                   fclose = #111;
-string (float fhandle)                                                 fgets = #112;
-void (float fhandle, string s)                                         fputs = #113;
-float (string s)                                                       strlen = #114;
-string (...)                                                           strcat = #115;
-string (string s, float start, float length)                           substring = #116;
-vector (string s)                                                      stov = #117;
-string (string s)                                                      strzone = #118;
-void (string s)                                                                strunzone = #119;
-
-void ()                                                                        R_ClearScene = #300;
-void (float mask)                                                      R_AddEntities = #301;
-void (entity e)                                                                R_AddEntity = #302;
-float (float property, ...)                                            R_SetView = #303;
-vector (float property, ...)                                           R_SetView3fv = #303;
-void ()                                                                        R_RenderScene = #304;
-void (vector org, float radius, vector rgb)                            R_AddDynamicLight = #305;
-void ()                                                                        R_CalcRefDef = #306;
-
-vector (vector v)                                                      cs_unproject = #310;
-vector (vector v)                                                      cs_project = #311;
-
-void   drawline(float width, vector pos1, vector pos2, vector rgb, float alpha, float flags) = #315;
-float  iscachedpic(string name)        = #316;
-string precache_pic(string name, ...)  = #317;
-vector draw_getimagesize(string pic) = #318;
-void   freepic(string name)            = #319;
-float  drawcharacter(vector position, float character, vector scale, vector rgb, float alpha, float flag) = #320;
-float  drawstring(vector position, string text, vector scale, vector rgb, float alpha, float flag) = #321;
-float  drawpic(vector position, string pic, vector size, vector rgb, float alpha, float flag) = #322;
-float  drawfill(vector position, vector size, vector rgb, float alpha, float flag) = #323;
-void   drawsetcliparea(float x, float y, float width, float height) = #324;
-void   drawresetcliparea(void) = #325;
-float  drawcolorcodedstring(vector position, string text, vector scale, float alpha, float flag) = #326;
-float  stringwidth(string text, float handleColors, vector fontSize) = #327;
-float  drawsubpic(vector position, vector size, string pic, vector srcPosition, vector srcSize, vector rgb, float alpha, float flag) = #328;
-
-
-float (float statnum)                                                  getstatf = #330;
-float (float statnum)                                                  getstati = #331;
-string (float statnum)                                                 getstats = #332;
-
-void (entity e, float i)                                               setmodelindex = #333;
-string (float i)                                                       modelnameforindex = #334;
-
-float(string efname)                                                   particleeffectnum = #335;
-void(entity ent, float effectnum, vector start, vector end, ...)       trailparticles = #336;
-void (float efnum, vector org, vector vel, float countmultiplier, ...) pointparticles = #337;
-
-void (string s, ...)                                                   cprint = #338;
-void (string s, ...)                                                   print = #339;
-
-void (float scale)                                                     setsensitivityscale = #346;
-
-
-float (float framenum)                                                 getinputstate = #345;
-void (entity e)                                                                        runstandardplayerphysics = #347;
-
-string (float playernum, string key)                                   getplayerkeyvalue = #348;
-void (string cmdname)                                                  registercmd = #352;
-void(float usecursor)                                                  setcursormode = #343;
-vector ()                                                              getmousepos = #344;
-
-string (string s)                                                      uncolorstring = #170;
-
-void (vector org, vector forward, vector right, vector up)             setlistener = #351;
-
-float (vector start, vector end, float ignore, float csqcents)         selecttraceline = #355;
-float ()                                                               isdemo = #349;
-float ()                                                               isserver = #350;
-
-void (float f)                                                         setwantsmousemove = #343;
-string (float key)                                                     getkeybind = #342;
-//string (float f)                                                     chr = #78;
-string (float f)                                                       chr = #78;
-float(string str, float ofs)                                           str2chr = #222;
-string(float c, ...)                                                   chr2str = #223;
-
-vector (vector org)                                                    getlight = #92;
-
-entity (.string fld, string match)                                     findchain = #402;
-entity (.float fld, float match)                                       findchainflags = #450;
-entity (.entity fld, entity match)                                     findchainentity = #403;
-entity (.float fld, float match)                                       findchainfloat = #403;
-entity (entity start, .float fld, float match)                         findflags = #449;
-
-float (string pattern, float caseinsensitive, float quiet)             search_begin = #444;
-void (float handle)                                                    search_end = #445;
-float (float handle)                                                   search_getsize = #446;
-string (float handle, float num)                                       search_getfilename = #447;
-
-
-#define SPA_POSITION 0
-#define SPA_S_AXIS 1
-#define SPA_T_AXIS 2
-#define SPA_R_AXIS 3
-#define SPA_TEXCOORDS0 4
-#define SPA_LIGHTMAP0_TEXCOORDS 5
-#define SPA_LIGHTMAP_COLOR 6
-float (entity e, float s)                                              getsurfacenumpoints = #434;
-vector (entity e, float s, float n)                                    getsurfacepoint = #435;
-vector (entity e, float s)                                             getsurfacenormal = #436;
-string (entity e, float s)                                             getsurfacetexture = #437;
-float (entity e, vector p)                                             getsurfacenearpoint = #438;
-vector (entity e, float s, vector p)                                   getsurfaceclippedpoint = #439;
-vector(entity e, float s, float n, float a) getsurfacepointattribute = #486;
-float(entity e, float s) getsurfacenumtriangles = #628;
-vector(entity e, float s, float n) getsurfacetriangle = #629;
-
-
-float (float a, float b, ...) min = #94;
-float (float a, float b, float c) min3 = #94;
-float (float a, float b, float c, float d) min4 = #94;
-float (float a, float b, float c, float d, float e) min5 = #94;
-float (float a, float b, float c, float d, float e, float f) min6 = #94;
-float (float a, float b, float c, float d, float e, float f, float g) min7 = #94;
-float (float a, float b, float c, float d, float e, float f, float g, float h) min8 = #94;
-float (float a, float b, ...) max = #95;
-float (float a, float b, float c) max3 = #95;
-float (float a, float b, float c, float d) max4 = #95;
-float (float a, float b, float c, float d, float e) max5 = #95;
-float (float a, float b, float c, float d, float e, float f) max6 = #95;
-float (float a, float b, float c, float d, float e, float f, float g) max7 = #95;
-float (float a, float b, float c, float d, float e, float f, float g, float h) max8 = #95;
-float (float minimum, float val, float maximum) bound = #96;
-
-vector () randomvec = #91;
-
-float (float val)              sin = #60;
-float (float val)              cos = #61;
-float (float val)              sqrt = #62;
-float (float a, float b)       pow = #97;
-
-void (vector org, string modelname, float startframe, float endframe, float framerate) effect = #404;
-
-void (vector org, vector velocity, float howmany) te_blood = #405;
-void (vector mincorner, vector maxcorner, float explosionspeed, float howmany) te_bloodshower = #406;
-void (vector org, float radius, float lifetime, vector color) te_customflash = #417;
-void(vector org, vector color) te_explosionrgb = #407;
-void(vector mincorner, vector maxcorner, vector vel, float howmany, float color, float gravityflag, float randomveljitter) te_particlecube = #408;
-void(vector mincorner, vector maxcorner, vector vel, float howmany, float color) te_particlerain = #409;
-void(vector mincorner, vector maxcorner, vector vel, float howmany, float color) te_particlesnow = #410;
-void(vector org) te_plasmaburn = #433;
-void(vector org) te_gunshotquad = #412;
-void(vector org) te_spikequad = #413;
-void(vector org) te_superspikequad = #414;
-void(vector org) te_explosionquad = #415;
-void(vector org) te_smallflash = #416;
-void(vector org, vector vel, float howmany) te_spark = #411;
-
-void(vector org) te_gunshot = #418;
-void(vector org) te_spike = #419;
-void(vector org) te_superspike = #420;
-void(vector org) te_explosion = #421;
-void(vector org) te_tarexplosion = #422;
-void(vector org) te_wizspike = #423;
-void(vector org) te_knightspike = #424;
-void(vector org) te_lavasplash = #425;
-void(vector org) te_teleport = #426;
-void(vector org, float color, float colorlength) te_explosion2 = #427;
-void(entity own, vector start, vector end) te_lightning1 = #428;
-void(entity own, vector start, vector end) te_lightning2 = #429;
-void(entity own, vector start, vector end) te_lightning3 = #430;
-void(entity own, vector start, vector end) te_beam = #431;
-
-float (entity ent, string tagname)     gettagindex = #451;
-vector (entity ent, float tagindex)    gettaginfo = #452;
-
-float (string s)       tokenize = #441;
-string (float argnum)  argv = #442;
-
-string (string s) cvar_string = #448;
-string (string s) cvar_defstring = #482;
-
-float ()                                               buf_create = #460;
-void (float bufhandle)                                 buf_del = #461;
-float (float bufhandle)                                        buf_getsize = #462;
-void (float bufhandle_from, float bufhandle_to)                buf_copy = #463;
-void (float bufhandle, float sortpower, float backward)        buf_sort = #464;
-string (float bufhandle, string glue)                  buf_implode = #465;
-string (float bufhandle, float string_index)           bufstr_get = #466;
-void (float bufhandle, float string_index, string str) bufstr_set = #467;
-float (float bufhandle, string str, float order)       bufstr_add = #468;
-void (float bufhandle, float string_index)             bufstr_free = #469;
-
-float () onground = #355;
-
-void(string texturename, ...) R_BeginPolygon = #306;
-void(vector org, vector texcoords, vector rgb, float alpha) R_PolygonVertex = #307;
-void() R_EndPolygon = #308;
-
-float(string s, float num) charindex = #356;
-
-// Darkplaces Additional Functions
-string(string s) strdecolorize = #477;
-string(string s) strtolower = #480; // returns the passed in string in pure lowercase form
-string(string s) strtoupper = #481; // returns the passed in string in pure uppercase form
-float(string s) strlennocol = #476;
-
-void(vector origin, string sample, float volume, float attenuation) pointsound = #483;
-
-// added by blub
-
-string(string key)                                     serverkey = #354;
-float(string s1, string s2)                            strcasecmp = #229;
-float(string s1, string s2, float len)                 strncasecmp = #230;
-float(string str, string sub, float startoffs)         strstrofs = #221;
-//float(string str, string sub)                        strstrofs = #221;
-entity(float num)                                      edict_num = #459;
-string(void)                                           ReadPicture = #501;
-string(string filename)                                        whichpack = #503;
-float(entity ent)                                      num_for_edict = #512;
-float(string s, string separator1, ...) tokenizebyseparator = #479;
-string(string in) uri_unescape = #511;
-float(float caseinsensitive, string s, ...) crc16 = #494;
-string(string info, string key) infoget = #227;
-string(string info, string key, string value, ...) infoadd = #226;
-string(string in) uri_escape = #510;
-
-float stringtokeynum(string keyname) = #341;
-string keynumtostring(float keynum) = #520;
-string findkeysforcommand(string command) = #521;
-
-string(float ccase, float calpha, float cnum, string s, ...) strconv = #224;
-float(entity ent) wasfreed = #353;
-
-entity(vector org, float rad) findradius = #22;
-
-string(float uselocaltime, string format, ...) strftime = #478;
-float(float timer) gettime = #519;
-#define GETTIME_REALTIME 1
-#define GETTIME_CDTRACK 4
-
-float(string s) tokenize_console = #514;
-float(float i) argv_start_index = #515;
-float(float i) argv_end_index = #516;
-
-float(float s) asin = #471; // returns angle in radians for a given sin() value, the result is in the range -PI*0.5 to PI*0.5
-float(float c) acos = #472; // returns angle in radians for a given cos() value, the result is in the range 0 to PI
-float(float t) atan = #473; // returns angle in radians for a given tan() value, the result is in the range -PI*0.5 to PI*0.5
-float(float c, float s) atan2 = #474; // returns angle in radians for a given cos() and sin() value pair, the result is in the range -PI to PI (this is identical to vectoyaw except it returns radians rather than degrees)
-float(float a) tan = #475; // returns tangent value (which is simply sin(a)/cos(a)) for the given angle in radians, the result is in the range -infinity to +infinity
-float DEG2RAD = 0.0174532925199432957692369076848861271344287188854172545609719144;
-float RAD2DEG = 57.2957795130823208767981548141051703324054724665643215491602438612;
-float PI      = 3.1415926535897932384626433832795028841971693993751058209749445923;
-float log(float f) = #532;
-
-void(entity e, entity ignore) tracetoss = #64;
-
-float(entity e, float ch) getsoundtime = #533; // (DP_SND_GETSOUNDTIME)
-
-#define PARTICLES_USEALPHA 1
-float particles_alphamin, particles_alphamax;
-#define PARTICLES_USECOLOR 2
-vector particles_colormin, particles_colormax;
-void(float effectindex, entity own, vector org_from, vector org_to, vector dir_from, vector dir_to, float countmultiplier, float flags)        boxparticles = #502;
-string(string format, ...) sprintf = #627;
-
-float(string name) cvar_type = #495;
-float CVAR_TYPEFLAG_EXISTS = 1;
-float CVAR_TYPEFLAG_SAVED = 2;
-float CVAR_TYPEFLAG_PRIVATE = 4;
-float CVAR_TYPEFLAG_ENGINE = 8;
-float CVAR_TYPEFLAG_HASDESCRIPTION = 16;
-float CVAR_TYPEFLAG_READONLY = 32;
-
-void (entity e, float chan, string samp, float vol, float atten, float pitchshift, float flags)        sound7 = #8;
-
-float trace_dphitcontents;
-float trace_networkentity;
-
-string(string search, string replace, string subject) strreplace = #484;
-
-//DP_QC_DIGEST
-//idea: motorsep, Spike
-//DarkPlaces implementation: divVerent
-//builtin definitions:
-string(string digest, string data, ...) digest_hex = #639;
-//description:
-//returns a given hex digest of given data
-//the returned digest is always encoded in hexadecimal
-//only the "MD4" digest is always supported!
-//if the given digest is not supported, string_null is returned
-//the digest string is matched case sensitively, use "MD4", not "md4"!
-
-//DP_CSQC_MINFPS_QUALITY
-//idea: divVerent
-//darkplaces implementation: divVerent
-//constant definitions:
-const float VF_MINFPS_QUALITY   = 213;
-//use getproperty(VF_MINFPS_QUALITY); to do CSQC based LOD based on cl_minfps
-//1 should lead to an unmodified view
index 3e2222f4aae07fc017cde94d3895caa779919bc3..00343a432d30d431f8a9f7de4a2acd274b507680 100644 (file)
@@ -295,9 +295,10 @@ void Net_ReadNexgunBeamParticle()
        
        //draw either the old v2.3 beam or the new beam
        charge = sqrt(charge); // divide evenly among trail spacing and alpha
-       particles_alphamin = particles_alphamax = charge;
+       particles_alphamin = particles_alphamax = particles_fade = charge;
+
        if (autocvar_cl_particles_oldnexbeam && (getstati(STAT_ALLOW_OLDNEXBEAM) || isdemo()))
-               WarpZone_TrailParticles_WithMultiplier(world, particleeffectnum("TE_TEI_G3"), shotorg, endpos, charge, 1);
+               WarpZone_TrailParticles_WithMultiplier(world, particleeffectnum("TE_TEI_G3"), shotorg, endpos, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE);
        else
-               WarpZone_TrailParticles_WithMultiplier(world, particleeffectnum("nex_beam"), shotorg, endpos, charge, 1);
+               WarpZone_TrailParticles_WithMultiplier(world, particleeffectnum("nex_beam"), shotorg, endpos, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE);
 }
index 4bc9c9fe87aa68c52ae9b264defb3a8c583328d7..de45141a136c1bb71aba06fafa4de21ad7fa027b 100644 (file)
@@ -40,8 +40,8 @@ void Projectile_DrawTrail(vector to)
 
        if (self.traileffect)
        {
-               particles_alphamin = particles_alphamax = sqrt(self.alpha);
-               boxparticles(self.traileffect, self, from, to, self.velocity, self.velocity, sqrt(self.alpha), PARTICLES_USEALPHA);
+               particles_alphamin = particles_alphamax = particles_fade = sqrt(self.alpha);
+               boxparticles(self.traileffect, self, from, to, self.velocity, self.velocity, 1, PARTICLES_USEALPHA | PARTICLES_USEFADE | PARTICLES_DRAWASTRAIL);
        }
 }
 
index 77cb2536eccad2d9e800b2f58695f049b0f5c81b..4bbbf03bc574582bb9981296d334e6ccc6998b9c 100644 (file)
@@ -2,6 +2,7 @@ float music_disabled;
 entity music_default;
 entity music_target;
 entity music_trigger;
+// FIXME also control bgmvolume here, to not require a target_music for the default track.
 
 .float state;
 .float lastvol;
index 82c5673d8b44ee22cb479844517c44e8e30cea73..7570393f4871669d6a649b396e15777e5b5b7f2d 100644 (file)
@@ -1073,20 +1073,21 @@ float MapInfo_Get_ByName_NoFallbacks(string pFilename, float pAllowGenerate, flo
                }
                else if(t == "fog")
                {
-                       if not(cvar_value_issafe(t))
+                       if not(cvar_value_issafe(s))
                                print("Map ", pFilename, " contains a potentially harmful fog setting, ignored\n");
                        else
                                MapInfo_Map_fog = s;
                }
                else if(t == "cdtrack")
                {
-                       if(pGametypeToSet)
+                       t = car(s); s = cdr(s);
+                       if(pGametypeToSet) // FIXME is this check right here?
                        {
                                if not(cvar_value_issafe(t))
                                        print("Map ", pFilename, " contains a potentially harmful cdtrack, ignored\n");
                                else
                                        MapInfo_Map_clientstuff = strcat(
-                                               MapInfo_Map_clientstuff, "cd loop \"", s, "\"\n"
+                                               MapInfo_Map_clientstuff, "cd loop \"", t, "\"\n"
                                        );
                        }
                }
index 79d33fd3c2167931f75c3150e7d1e6ee9924a967..fb3ddb46a4ac4b07c40972653d37d5f90fe6dfba 100644 (file)
@@ -1447,6 +1447,9 @@ float PARTICLES_USEALPHA = 1;
 float particles_alphamin, particles_alphamax;
 float PARTICLES_USECOLOR = 2;
 vector particles_colormin, particles_colormax;
+float PARTICLES_USEFADE = 4;  // fades the COUNT (fade alpha using alphamin/alphamax)
+float particles_fade;
+float PARTICLES_DRAWASTRAIL = 128;
 void(float effectindex, entity own, vector org_from, vector org_to, vector dir_from, vector dir_to, float countmultiplier, float flags) boxparticles = #502;
 float trace_networkentity;
 const float RF_FULLBRIGHT      = 256;
index 19961d8ae607066ad60f884ac03e0730d3278fbf..e8b34509838cb2e56d05b685165ddb792cade3b9 100644 (file)
@@ -883,7 +883,7 @@ void spawnfunc_worldspawn (void)
                s = "";
                n = tokenize_console(cvar_string("sv_curl_serverpackages"));
                for(i = 0; i < n; ++i)
-                       if(substring(argv(i), -14, -1) != "-serverpackage.txt")
+                       if(substring(argv(i), -18, -1) != "-serverpackage.txt")
                        if(substring(argv(i), -14, -1) != ".serverpackage") // OLD legacy
                                s = strcat(s, " ", argv(i));
                fd = search_begin("*-serverpackage.txt", TRUE, FALSE);
index 9040c72407a8914972d2e4533b2852a767753702..c2a6e8a89fdfdb1d38e962cc49690f586fb40cb7 100644 (file)
@@ -469,12 +469,13 @@ void WarpZone_TrailParticles_WithMultiplier_trace_callback(vector from, vector e
        boxparticles(WarpZone_TrailParticles_trace_callback_eff, WarpZone_TrailParticles_trace_callback_own, from, endpos, WarpZone_TrailParticles_trace_callback_own.velocity, WarpZone_TrailParticles_trace_callback_own.velocity, WarpZone_TrailParticles_trace_callback_f, WarpZone_TrailParticles_trace_callback_flags);
 }
 
+float PARTICLES_DRAWASTRAIL = 128;
 void WarpZone_TrailParticles_WithMultiplier(entity own, float eff, vector org, vector end, float f, float boxflags)
 {
        WarpZone_TrailParticles_trace_callback_own = own;
        WarpZone_TrailParticles_trace_callback_eff = eff;
        WarpZone_TrailParticles_trace_callback_f = f;
-       WarpZone_TrailParticles_trace_callback_flags = boxflags;
+       WarpZone_TrailParticles_trace_callback_flags = boxflags | PARTICLES_DRAWASTRAIL;
        WarpZone_TraceBox_ThroughZone(org, '0 0 0', '0 0 0', end, MOVE_NOMONSTERS, world, world, WarpZone_TrailParticles_WithMultiplier_trace_callback);
 }
 #endif