Azrael666 Posted January 19, 2004 Share Posted January 19, 2004 Im trying to find the code for gun, but where sabers have their .sab files i can find nothing. Specifically i want to see if i can find how to make it so a lightsaber hittinga target causes the disintegration effect. Link to comment Share on other sites More sharing options...
[ONE]Mushroom Posted January 20, 2004 Share Posted January 20, 2004 AFAIK, you need to code C to get that effect. WP_DisruptorAltFire from g_weapon.c Link to comment Share on other sites More sharing options...
Azrael666 Posted January 20, 2004 Author Share Posted January 20, 2004 So wheres the actual code in assets? Will puting WP_DisruptorAltFire 1 in the .sab file work? I can do C if needed, working on it in Uni at the moment. Link to comment Share on other sites More sharing options...
razorace Posted January 21, 2004 Share Posted January 21, 2004 It's the .dll files that controls that behavior. You'll need the SDK to be able to change anything inside them. Link to comment Share on other sites More sharing options...
Azrael666 Posted January 21, 2004 Author Share Posted January 21, 2004 I have the SKD kit, i dont know what to do withit or where to find these .dll files! Link to comment Share on other sites More sharing options...
Azrael666 Posted January 21, 2004 Author Share Posted January 21, 2004 Anyway, all i want is the code to make it so that when i kill someone with a saber, they disintegrate like with a kill from a disruptor. The best i have at the moment is replacing the shader for cuts on bodies with orange glow effect for the disruptor, which just look weird. I need to know either: a. the code so that i can make kills from this saber disintergrate or b. where the code for the gun is kept, something more than just one files name, a file path within assets or something. Link to comment Share on other sites More sharing options...
[ONE]Mushroom Posted January 22, 2004 Share Posted January 22, 2004 OK, firstly realise that modding the .dlls is not necessarily trivial. They are stored in assets3.pk3 (if you have patched), but you will need to recompile (possibly just jampgamex86.dll), and put in your mod directory. It would be easier if you have MS Visual C++ 7, or at least MSVC6. This is the SDK you need. (IIRC there is also a modelling SDK). Unzip it, go into the codemp directory it creates. Read the MakeAMod_readme.txt (not very helpful I'm afraid). The best intro I've read for Quake 3 engine modding is Code3Arena. Be aware though that JK:JA does not use QVMs, for reasons best known to Raven it uses .dll files for Windows and .so files for Linux. Open up the project file in MSVC7, if you have MSVC6 there is a project converter here or here . Open up g_weapon.c, find the function WP_DisruptorAltFire, and see why the disruptor disintegrates the target. This seems to be the code: if (traceEnt->client && preHealth > 0 && traceEnt->health <= 0 && fullCharge && G_CanDisruptify(traceEnt)) { //was killed by a fully charged sniper shot, so disintegrate VectorCopy(preAng, traceEnt->client->ps.viewangles); traceEnt->client->ps.eFlags |= EF_DISINTEGRATION; VectorCopy(tr.endpos, traceEnt->client->ps.lastHitLoc); traceEnt->client->ps.legsAnim = preLegs; traceEnt->client->ps.torsoAnim = preTorso; traceEnt->r.contents = 0; VectorClear(traceEnt->client->ps.velocity); } Include something similar in the right place in w_saber.c and rebuild the .dll You may need to add more code to get it to work, but I'll leave that to you Link to comment Share on other sites More sharing options...
Azrael666 Posted January 22, 2004 Author Share Posted January 22, 2004 Hmm, well, im not sure i actually have to mess around with the weapons, i just wanted to understand the code. I guess the thing to do would be to create a new kind of saber in .dll, so now all saber have this effect. So the if statement would be for the type of lightsaber (maybe if sabername=disintegrator&& health <=0 then: or something) At eany rate, i proably need that in the saber file with a different if statement. Bonza. Link to comment Share on other sites More sharing options...
Azrael666 Posted January 22, 2004 Author Share Posted January 22, 2004 BTW, will textpad be ok for this stuff? Link to comment Share on other sites More sharing options...
[ONE]Mushroom Posted January 25, 2004 Share Posted January 25, 2004 You'll need a compiler (which I assume Textpad doesn't include), and preferably an Integrated Development Environment. You'll have to find (or create) project files / Make files yourself if you use anything other than MSVC6/7 though (although AFAIK you'd only need to build the server side game project). DevC++ is a very popular free solution. Maybe someone has already created the project files you'd need for this; ask on the coding forum. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.