Forum

Defeat In Detail 2

Discuss anything not covered by any of the other categories.

Moderator: InsideQC Admins

Postby Urre » Mon Apr 14, 2008 8:01 am

Cool shit mate! Making a csqc HUD too?
I was once a Quake modder
User avatar
Urre
 
Posts: 1109
Joined: Fri Nov 05, 2004 2:36 am
Location: Moon

Postby MauveBib » Mon Apr 14, 2008 9:17 am

I have to recode the menu to integrate it with the new external scripting system, so that seems as good a time as any to start fiddling with some csqc. Of course I've not really looked at csqc at all before, so have no idea what I'm doing, but that's always half the fun, right?
Apathy Now!
User avatar
MauveBib
 
Posts: 634
Joined: Thu Nov 04, 2004 1:22 am

Postby Urre » Mon Apr 14, 2008 2:23 pm

Absolutely. If your cursor was csqc, it'd be a lot easier to do huds, but managing the units is a lot harder then, as you need to make them shared, and basicly code all the stuff yourself whcih prydoncursor does for you. I'm doing it the hard way, using csqc all the way, and I can tell you it's no fun. Until it works, ofcourse.

If not doing csqc, you'll have to use the same kind of hack Chris does for his game, where you disable all the unit selection code and whatnot whenever the cursor is within certain bounds, hardcoded on the server. Then manage mouse clicks according to where it is in the hud, also done on server. The only thing done on client in this case is the actual drawing of the hud. This works, but IMO is messy and doesn't allow as cool stuff.

Another idea, which I guess will work best for you, is a hybrid. Run both prydoncursor code and csqc mousepointer code, and disable/enable the two depending on wether the mouse position is above the hud or not, and just have one of the pointers be a hidden one. This way you don't have to hardcode things (as much) on the server, and can do cooler things on the client side of things. It will require you to send info about hud clicks to server though, which currently has no standardized way of doing it. Currently you need to stuffcmd all commands from the client, which is what I'm doing also, until something better comes along.
I was once a Quake modder
User avatar
Urre
 
Posts: 1109
Joined: Fri Nov 05, 2004 2:36 am
Location: Moon

Postby MauveBib » Mon Apr 14, 2008 2:38 pm

Hmm. That does sound a bit of a hassle. I guess I'll have a playaround and see what seems most natural.

Either way, the current floating entities system I'm using is pretty unsustainable, espectially for multiplayer.

I'll certainly be adding a CSQC HUD for the non-clickable elements such as the cash counter, unit buying counters etc.
Apathy Now!
User avatar
MauveBib
 
Posts: 634
Joined: Thu Nov 04, 2004 1:22 am

Postby MauveBib » Wed Apr 16, 2008 10:55 am

Having updated my video card drivers I have been able to update to the most recent version of DP, but I am having issues with BSP models such as the buildings, with FPS dropping to 1 when more than a couple are onscreen.

Looks like I'm going to have to remodel the buildings as models...

I've also been discussing with Harb the possibility of resurrecting Malefic as an RTS...
Apathy Now!
User avatar
MauveBib
 
Posts: 634
Joined: Thu Nov 04, 2004 1:22 am

Postby Urre » Wed Apr 16, 2008 12:49 pm

Cool mate :)

Yeah I'd recommend having the buildings as models in any case, it's always a bit faster.

Not to rob your thread, but it's really inspiring, makes me hope I'll have something to talk about/show sometime soon too.
I was once a Quake modder
User avatar
Urre
 
Posts: 1109
Joined: Fri Nov 05, 2004 2:36 am
Location: Moon

Postby MauveBib » Wed Apr 16, 2008 12:50 pm

Yeah, I'm very interested to hear how your project is coming along.
Apathy Now!
User avatar
MauveBib
 
Posts: 634
Joined: Thu Nov 04, 2004 1:22 am

Postby Chris » Thu Apr 17, 2008 8:11 pm

Urre wrote:Absolutely. If your cursor was csqc, it'd be a lot easier to do huds, but managing the units is a lot harder then, as you need to make them shared, and basicly code all the stuff yourself whcih prydoncursor does for you. I'm doing it the hard way, using csqc all the way, and I can tell you it's no fun. Until it works, ofcourse.

If not doing csqc, you'll have to use the same kind of hack Chris does for his game, where you disable all the unit selection code and whatnot whenever the cursor is within certain bounds, hardcoded on the server. Then manage mouse clicks according to where it is in the hud, also done on server. The only thing done on client in this case is the actual drawing of the hud. This works, but IMO is messy and doesn't allow as cool stuff.



Haha hacks what Chris does. First off I put as much in csqc as I can, second off that was a suggestion, not what I do since I'm not even making an RTS game. Before assuming I picked a "messy" way to do something its best to make sure I'm even doing it in the first place.

Also sharing csqc ents isn't difficult at all, the only issue is updating their locations constantly to the client, I suppose this couldn't be too bad but with the amount of units you want on screen and also it possibly being mp at some point thats a lot of data. The best solution is though to share all the incoming entities, not this "Server side hack" I'm being accused of.

On the other hand what I did suggest is a lot easier and cleaner, simply involves using a tracebox with the size and origin relevant to mouse clicks, and server side you could easily write some 2d->3d projection of where to place these points in the map from the cursor_screen offsets. Its far less work and achieves the same technique, its just not very extend able beyond that and you don't have a lot of the nifty graphical features you would in csqc to show your selection box etc.

Also if you want an example of shared entities you can try my inventory thing which has source:

viewtopic.php?t=927
Chris
 
Posts: 79
Joined: Sat Aug 05, 2006 5:31 am

Postby Urre » Fri Apr 18, 2008 6:36 am

I only quoted what you showed me a while back. Nothing wrong with hacks, that's what Quake modding is about in the end...

Shared entities aren't a problem, unless you're trying to make them match with very few updates (every 5 seconds or so). Try that one for size, have fun with the desyncs.
I was once a Quake modder
User avatar
Urre
 
Posts: 1109
Joined: Fri Nov 05, 2004 2:36 am
Location: Moon

Postby MauveBib » Sat Apr 26, 2008 8:21 pm

I've been experimenting with terrain for future DiD2 levels:

Image
Image

Getting there...
Apathy Now!
User avatar
MauveBib
 
Posts: 634
Joined: Thu Nov 04, 2004 1:22 am

Postby scar3crow » Sun Apr 27, 2008 12:10 am

damn Mauve, this mod is getting over the hill! *rimshot*

Looks nice though... What'dja use?
User avatar
scar3crow
InsideQC Staff
 
Posts: 1054
Joined: Tue Jan 18, 2005 8:54 pm
Location: Alabama

Postby jim » Sun Apr 27, 2008 11:58 am

Reminds me of Delta Force...
zbang!
User avatar
jim
 
Posts: 599
Joined: Fri Aug 05, 2005 2:35 pm
Location: In The Sun

Postby MauveBib » Sun Apr 27, 2008 4:59 pm

scar3crow wrote:Looks nice though... What'dja use?


Q3BSP, a couple of shaders and a terrain generator.
Apathy Now!
User avatar
MauveBib
 
Posts: 634
Joined: Thu Nov 04, 2004 1:22 am

Postby RenegadeC » Mon Apr 28, 2008 3:07 am

If those screenshots were a woman I'd make love to her.
User avatar
RenegadeC
 
Posts: 391
Joined: Fri Oct 15, 2004 10:19 pm
Location: The freezing hell; Canada

Postby leileilol » Mon Apr 28, 2008 4:27 am

Too bad there's no real texture blending on that so there would be a monotonous terrain lacking dirt paths and rocks
i should not be here
leileilol
 
Posts: 2783
Joined: Fri Oct 15, 2004 3:23 am

PreviousNext

Return to General Discussion

Who is online

Users browsing this forum: No registered users and 1 guest