Vruki Salet Posted December 14, 2005 Share Posted December 14, 2005 I have the source for JK2 jedimod 1.2 which is supposed to have Tchouky's model scaling code in it. Before I go through the bother of porting it to JA myself - assuming that's necessary - is there already a JA version floating about or is someone willing to fork it over? Link to comment Share on other sites More sharing options...
razorace Posted December 14, 2005 Share Posted December 14, 2005 mmm, I'm not sure about that. Maybe XMod has it. Anyway, it would probably be easier and better to just impliment it yourself. The code pretty much already uses modelscale for all the models, it just that the modelscale needs to be modifiable by the players. Link to comment Share on other sites More sharing options...
guest Posted December 18, 2005 Share Posted December 18, 2005 here is my code from my yet-unnamed mod else if(!Q_stricmp (cmd, "scale")){ int TargetNum = 0, TheScale = 0; char arg1[MAX_STRING_CHARS]; gentity_t *TheEnt; if(!CheckAdminCmd( ent, CMD_SCALE )) return; if(trap_Argc() <= 1 || trap_Argc() > 2){ trap_SendServerCommand( clientNum, "print \"USAGE: \'/scale <player> <scale>\', If no player is specified, it performs the scale on you.\n\""); return; } trap_Argv(1, arg1, sizeof(arg1)); if(trap_Argc() == 2){ TargetNum = ent->client->ps.clientNum; TheScale = atoi(arg1); } else{ //trap_Argv(1, arg1, sizeof(arg1)); TargetNum = atoi(arg1); trap_Argv(2, arg1, sizeof(arg1)); TheScale = atoi(arg1); } if(TargetNum > MAX_CLIENTS || TargetNum < 0){ trap_SendServerCommand( clientNum, "print \"Invalid client number\n\""); return; } if(TheScale > 1023 || TheScale < 0){ trap_SendServerCommand( clientNum, "print \"Invalid model scale\n\""); return; } TheEnt = &g_entities[TargetNum]; //ohh, icarus model scaling stuff //static void Q3_SetScale(int entID, float float_data) //good ol' icarus will allways show the way if(!TheEnt->client){ trap_SendServerCommand( clientNum, "print \"Invalid player (player not active?)\n\""); return; } TheEnt->client->ps.iModelScale = TheScale; //TheEnt->s.iModelScale = TheScale; //TheEnt->modelScale = TheScale; } if you want any code samples from the mod I'm working on, go to bwap.pipobona.com, as I rarely visit these forums. I think pipo has it set so you need to be registered to view the c++ area where I post the code. I allready posted a /place command very much like the one used in lugormod there if your interested -robo85045 (Tree2.0) Link to comment Share on other sites More sharing options...
Vruki Salet Posted December 19, 2005 Author Share Posted December 19, 2005 Thanks for this & that address, mysterious stranger. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.