Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - skuller

Pages: [1]
1
Quake / Re: Another Quake 2 package - nQuake2
« on: January 05, 2013, 08:57:21 AM »
I've added it today. You need to rebuild Q2PRO from latest git to get it working.

2
Quake / Re: Another Quake 2 package - nQuake2
« on: January 05, 2013, 04:47:08 AM »
Quote from: empezar
I have a feature request, pretty simple one. (I didn't find any way of submitting feature requests on your git page.)

Feel free to post feature requests the same way as other issues on github.

Quote from: empezar
I'd like to have a "user.cfg" or something in \baseq2 or \q2pro or something, which gets executed last of all configs, "system wide" i.e. even after mod autoexec.cfg. This means execution order should be default.cfg -> q2config.cfg -> autoexec.cfg (all mod specific) -> user.cfg (one file, system wide).

I've added logic to exec postexec.cfg file (if it exists) after mod-specific autoexec.cfg. If you place postexec.cfg in baseq2/ it will become "system wide".

Quote from: Jay Dolan
I'm sorry, but that test suite is laughably irrelevant. I've never used Q2Pro, so I can't comment on its stability in general and I don't question that you've made a significant effort to make it so. But I've also never in my 15 years of playing and eventually developing for Quake2 encountered a malicious .bsp file. You should develop a more practical test suite if you want to show off your client's stability.

A reference to that test suite is pretty relevant as it questions the idea that "R1Q2 is rock-solid". I'm making no claim that Q2PRO is rock-solid either, every software has bugs. I've spent some time to improve code robustness in areas other developers overlooked or didn't consider important, that is the point the test suite illustrates. It would be certainly nice to increase test suite coverage by expanding it to other resource formats loadable by Q2, but that is a lot of work.

That you've never seen a malicious .bsp file doesn't mean it can't be created on purpose for targeted attack. Computer security works by patching the hole before it gets exploited, not the other way around.

Quote from: Jay Dolan
Something that would actually impress me is showing that the code base is valgrind- and clang-clean.

Not sure what you mean by "clang-clean", but I regularly use clang for development builds and never had any problems with it. Feel free to report any issues you find with valgrind (from a few test runs with memcheck I didn't see anything suspicious).



3
Quake / Re: Another Quake 2 package - nQuake2
« on: January 03, 2013, 09:16:35 AM »
Quote from: empezar
Need help compiling the latest Q2pro client from sources. I have no idea how to do this. nQuake2 will be Windows only so I will only need a Windows binary.

I've prepared SDKs for MinGW-w64 and Visual C++ 10.0 to make building Windows version of Q2PRO from Git easier. These SDKs include all additional libraries and headers Q2PRO requires. See the Q2PRO homepage for download links and instructions. For building on Windows, Visual C++ compiler included in Windows SDK 7.1 package from Microsoft is probably the best option.

It would be a good idea to distribute resulting q2pro.stripped.pdb (after renaming it to q2pro.pdb) file along with q2pro.exe to make runtime crash dump generation more detailed.

Quote from: r1
The client is the single most important design decision here. Its stability is paramount and trumps features any day of the week. More players will no doubt experience the said crashes, resulting in more random confusion.

I do fully agree that client stability is important. All crashes that are properly reported will be investigated and fixed.

Quote from: r1
R1Q2 on the other hand has an extensive and proven track record that is solid as a rock.

It has an older code base so that no crash bugs are immediately visible. But throw a corrupt input at it for example, some robustness problems R1Q2 has will become more evident.

Quote from: empezar
I come from QuakeWorld and ezQuake, which I believed was an incredible client. With Q2pro I realise how bloated ezQuake really is.

Thanks for kind words, avoiding code (and feature, to lesser extent) bloat is one of design principles of Q2PRO :)


4
General Ownage / Re: is MCS_FaderJok0 legit winner div4 EDL
« on: June 12, 2012, 07:02:58 AM »
If SkulleR is merely saying: anticheat.dll encrypts its message channel to the AC root server; well, yes.  Isn't that what one would expect?

I was saying that I would expect anticheat to search just for active Quake 2 cheats currently loaded into memory, yet the anticheat protocol readily provides commands to read arbitrary directories and files from disk outside of Quake 2 base directory. While I suppose these commands have some semi-legitimate purpose (searching for offline cheats? checking for modified system files? maybe even scanning web browser history for cheating sites?), they are a security hole if someone gains unauthorized access to anticheat server and/or data stored there. (Anyway, silent anticheat.dll auto-update feature itself is a big security hole as well). Very little is known about how anticheat server is run, what user data exactly is preserved, etc. Earlier versions of anticheat.dll didn't event check server certificate making man-in-the-middle attacks on anticheat message channel possible.

I understand anticheat would be less efficient without these features, so they are perhaps "necessary evil". What I don't really like is that how many servers and even leagues are requiring use of anticheat lately. Instead of requiring known or suspected cheaters to use anticheat in order to play, they are forcing many legitimate players deliberately install a "backdoor" on their system and put their privacy to risk. I no longer want to make my client part of this.

5
0x1337c0de / Re: Entity List Management in Q2 Mods
« on: March 23, 2012, 02:48:11 PM »
Quote
I don't think so but I'd like to read your thoughts on why the Loxo server has not crashed with ED_Alloc: no free edicts nor has it crashed with SEG-FAULT or bad data overwrites. Typical LOX num_edicts runs in the 500 to 700 range on 12 players and custom maps. It's been a long time since the server had a heavy load.

Most likely it has never hit the 1024 entities limit. R1Q2 server will almost definitely crash once an attempt to link an entity beyond MAX_EDICTS is done.

Quote
But why does it say this in the original game.h?

Well that comment is generally true. It just needs to mention that server can handle not more than 1024 entities.

6
0x1337c0de / Re: Entity List Management in Q2 Mods
« on: March 22, 2012, 04:11:03 PM »
You seem to be mixing up MAX_PACKET_ENTITIES (maximum number of entities in client frame, which is 128) and MAX_EDICTS (maximum number of entities in game from server and client points of view).

7
0x1337c0de / Re: Entity List Management in Q2 Mods
« on: March 22, 2012, 04:27:35 AM »
Perhaps there was intent to make maxentities completely configurable, but that never got implemented in server and client. As a result, game allocates memory for entity array dynamically, while client and server use fixed arrays. Actually, ge->max_edicts field is never referenced by 3.20 server code, but in many places server implicitly assumes ge->num_edicts to be less than MAX_EDICTS. If server encounters an active entity beyond MAX_EDICTS, bad things will happen (server may silently overwrite memory).

So it is a good idea for a mod author to verify that maxclients < maxentities <= MAX_EDICTS at server startup.

8
0x1337c0de / Re: Entity List Management in Q2 Mods
« on: March 21, 2012, 02:28:58 PM »
You can't have more than 1024 entities in Q2 without bumping MAX_EDICTS constant and thus changing the network protocol. Setting ‘maxentities’ cvar alone to 2048 won't help (once 1025'th entity is allocated server will crash anyway).

9
Trouble Shooting / Re: KeyGrip recam
« on: May 07, 2011, 04:49:53 AM »
To convert between binary and text formats one can use these commands:
Code: [Select]
lmpc --game QUAKE2 --to-txt example.dm2 example.txt
lmpc --game QUAKE2 --to-bin example.txt example.dm2

When converting from binary to text LMPC shows "read error" message for some reason, but it appears to be harmless (apparently it doesn't handle end-of-demo packet well?).

To know which entity is assigned to what player, one needs to look up playerskin number by looking at configstrings packet (LMPC inserts handy comments to ease this task). Relative playerskin number is equal to client slot number on the server, and client entity number is always client slot number plus one.

For example, in that demo I got:
Code: [Select]
configstring {
 index 1324; // playerskin[12]
 string "iafa.isbjorn\\female/athena";
}

Relative playerskin number is 12, therefore entity number is 13.

10
Trouble Shooting / Re: KeyGrip recam
« on: May 01, 2011, 01:36:03 PM »
Changing modelindex to 255 on entity 13 worked fine for me with that demo, in a sense that player entity is now visible. I didn't use keygrip though, but LMPC and a text editor. Here's the result.

11
Trouble Shooting / Re: KeyGrip recam
« on: May 01, 2011, 10:30:21 AM »
Can't download attachments here...

12
Trouble Shooting / Re: KeyGrip recam
« on: May 01, 2011, 02:36:33 AM »
OpenTDM resets modelindex of the entity being chased to 0. You can try to fix it by changing modelindex back to 255.

13
0x1337c0de / Re: Need Help Coding Chase in-eyes View
« on: March 15, 2011, 05:32:40 AM »
Quote
Another solution might be to ID the chased player and then not render him in the chasing client.

This is how it works in OpenTDM/OpenFFA mods. It requires cooperation from the server to hide player entity from the specified client. Both R1Q2 and Q2PRO servers support this. Game API has been extended so that a new shared field ‘clientNum’ has been added to the beginning of gclient_s struct:
Code: [Select]
struct gclient_s
{
    player_state_t  ps;     // communicated by server to clients
    int             ping;

    // the game dll can add anything it wants after
    // this point in the structure
    int             clientNum;
};

A compatible game mod fills this field with current client POV number: it is equal to client slot number for normal players, and changes for spectators that are chasing other players. Server looks at this field and hides player entity from client frame if necessary. A question remains is how the server would know that game mod is ‘clientNum’ aware and actually fills it with meaningful information, and how the game mod would know if it can safely use ‘clientNum’ for in-eyes chasecam. This is implemented though game/server features cvars. On startup, R1Q2 and Q2PRO servers set a read-only cvar ‘sv_features’ to a bitmask of supported features, among them is GMF_CLIENTNUM feature:
Code: [Select]
#define GMF_CLIENTNUM   1
#define GMF_PROPERINUSE 2
#define GMF_MVDSPEC     4
#define GMF_WANT_ALL_DISCONNECTS 8

In turn, game mod sets a read-only cvar ‘g_features’, exporting a bitmask of features it supports. Server then looks if ‘g_features’ has GMF_CLIENTNUM bit set, and if so, it respects ‘clientNum’ field. Game mod looks if ‘sv_features’ has GMF_CLIENTNUM bit set, and if so, it implements ‘proper’ in-eyes chasecam view by simply copying the playerstate of chased player to spectator playerstate (changing pm_type to PM_FREEZE and setting PMF_NO_PREDICTION bit of course). This is an example of how it can be done:

Code: [Select]
static void UpdateChaseCam( gclient_t *client ) {
    edict_t *ent = client->edict;
    edict_t *targ = client->chase_target;

    client->clientNum = ( targ - g_edicts ) - 1;
    client->ps = targ->client->ps;
    client->ps.fov = client->pers.fov;
    client->ps.pmove.pm_flags |= PMF_NO_PREDICTION;
    client->ps.pmove.pm_type = PM_FREEZE;

    VectorCopy( client->ps.viewangles, ent->s.angles );
    VectorCopy( client->ps.viewangles, ent->client->v_angle );
    VectorScale( client->ps.pmove.origin, 0.125f, ent->s.origin );
    ent->viewheight = targ->viewheight;
}

Pages: [1]