Forum

Adding SVC like svc_cdtrack but w/fullname music file

Discuss programming topics for the various GPL'd game engine sources.

Moderator: InsideQC Admins

Postby Baker » Sun Apr 24, 2011 7:35 pm

mh wrote:Now, I can definitely see the advantages of Baker's proposals for new content, but what of existing content? What of the 15 years worth of accumulated maps and mods?


Well, I have a few different total conversions I have been working on, on and off. I'm not suggesting any changes to actual Quake. (I was kind of trying to keep actual Quake out of the discussion with this ... "Please no 'But existing Quake mods/maps use cd track' stuff ... this isn't for that ..." at the top of the first post).

Quake is what it is, I'm not looking to change/improve/modify or supercede any exist standard (and I wouldn't think of polluting the Quake map pool with a Quake map using an alternate standard). But it doesn't mean something like Nexuiz or Kurok has to inherent things it doesn't like.

Even that said, aside from Travail and those .xm music files (or whatever they are) in Nehahra, I don't think there is really a meaningful body of work of single player stuff using a soundtrack.

But again, I'm not even remotely suggesting "actual Quake" use for this.
The night is young. How else can I annoy the world before sunsrise? 8) Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
User avatar
Baker
 
Posts: 3666
Joined: Tue Mar 14, 2006 5:15 am

Postby metlslime » Sun Apr 24, 2011 11:39 pm

I just wanted to say, enumerating the files so "05" gets mapped to file #5 in the directory listing is pretty fragile. This means if the user adds one new track named aaa.mp3 then every other map is broken.

As much as I don't like using stuffcmd for things that should be built into the protocol of any well-designed engine+mod, I would concede that it's the least amount of work and is truly "extensible" in that even a stock client running protocol 15 won't crash on it. It's the most under-engineered (in a good way) of all solutions. It is dirty though; i dislike the idea that console commands or cvars become part of the API for quakec to use.

One thing I don't have time to check right now, is stuffcmd handled in a reliable packet, or is it possible to get lost forever if it goes into a dropped packet?
metlslime
 
Posts: 316
Joined: Tue Feb 05, 2008 11:03 pm

Postby mh » Mon Apr 25, 2011 12:07 am

Well my view is that it's really no different to what happens if the player pops in a different CD. Same end result.

Using actual file names could also be argued to be fragile as the player could rename a file just as easily. Or get the file name wrong if adding their own music. And in both cases the player could delete a file. Ultimately you've just to accept that there are some things outside of your control. This one can go round and round in circles with nothing more constructive being generated than "I'm right because I think I'm right" in fact...

OK, so I missed Bakers "please, no 'but...'" in the first post so I think I'm gonna shut up on that point now and apologise for bringing it up.

Back on topic: yeah, agreed that stuffcmd - despite all it's faults - is definitely the way to go with this one.
We had the power, we had the space, we had a sense of time and place
We knew the words, we knew the score, we knew what we were fighting for
User avatar
mh
 
Posts: 2292
Joined: Sat Jan 12, 2008 1:38 am

Postby metlslime » Mon Apr 25, 2011 5:31 am

I don't know, it seems more likely for users to add files to the music directory (including adding them to id1) than to open up a mod's pak file and delete or rename files in there.

I'm thinking of, for examples, the way map files are referred to by name in the trigger_changelevel, and the way skyboxes are referred to by name in the worldspawn.

These are both cases where users often install more and more content over time, and the extra bsp files and skyboxes clutter up the same directories without breaking the previous ones.

Imagine if installing a new quoth map with its own skybox would cause all other quoth maps to use the wrong skybox.
metlslime
 
Posts: 316
Joined: Tue Feb 05, 2008 11:03 pm

Postby mh » Tue Apr 26, 2011 12:01 am

My experience is that in the real world players are likely to do neither. They want to play Quake with the original soundtrack so they get a rip of the tracks, pop it into ID1 and then leave it be forever more. Changing around the music files - either adding, deleting or renaming - is something that just doesn't happen, and all arguments against either approach on that basis are more or less bogus. I'm prepared to change my position on that if I can see hard evidence to support a counter argument, but like I said - I've been using this code for 2 years and have had zero problems or complaints from people, so any fragility in the approach is purely theoretical IMO.
We had the power, we had the space, we had a sense of time and place
We knew the words, we knew the score, we knew what we were fighting for
User avatar
mh
 
Posts: 2292
Joined: Sat Jan 12, 2008 1:38 am

Postby Spike » Tue Apr 26, 2011 12:31 am

mh wrote:My experience is that in the real world players are likely to do neither.

My experience is that in the real world, players will not be directly controlling the svcs sent by the server. That's for mappers or modders, who are the people that I would imagine Baker would be trying to target with this.
If you want a random track, you don't care what number it uses. If you actually care which track, then you need more than a pseudo-random number.

If the filename is specified at map load time, a client can know to predownload it, which is but one reason why I suggested listing the mappings from the entities list.
Spike
 
Posts: 2892
Joined: Fri Nov 05, 2004 3:12 am
Location: UK

Previous

Return to Engine Programming

Who is online

Users browsing this forum: No registered users and 1 guest