View previous topic :: View next topic |
Author |
Message |
Team Xlink
Joined: 25 Jun 2009 Posts: 320
|
Posted: Mon Jan 18, 2010 10:18 pm Post subject: Bad MoveType & Alternateive To Stuffcmding |
|
|
Hello.
I am trying to change the player model when he has a certain weapon this is what I have:
if (self.weapon == IT_GROWINATOR)
{
setmodel(self,"progs/giant.mdl");
modelindex_player = self.modelindex;
self.movetype = MOVETYPE_WALK;
self.impulse = 0;
}
It gives me an error that says this:
Svphysics: bad movetype
I don't know why it is doing that.
Thank you.
Hello.
I am trying to slow the players turning speed and stuffcmding to cl_yawspeed isn't a good way to do it, is there an easy alternative to it?
Thank you. _________________
Anonymous wrote: | if it works, it works. if it doesn't, HAHAHA! |
|
|
Back to top |
|
 |
Orion

Joined: 12 Jan 2007 Posts: 413 Location: Brazil
|
Posted: Mon Jan 18, 2010 11:03 pm Post subject: |
|
|
Player models are changed via .modelindex.
Also, you don't need to redeclare MOVETYPE_WALK nor self.impulse after changing a model.
Try something like this at PutClientInServer() (client.qc):
Code: |
setmodel (self, "progs/giant.mdl");
modelindex_giant = self.modelindex;
|
The player's modelindexes are checked by CheckPowerups() (also client.qc), you might also want to take a look at it.
Don't forget to put a (float modelindex_giant) at the bottom of defs.qc.
But the second question I kinda don't know much, though. _________________ There's no signature here. Stop looking for one. |
|
Back to top |
|
 |
Wazat
Joined: 15 Oct 2004 Posts: 732 Location: Middle 'o the desert, USA
|
Posted: Tue Jan 19, 2010 2:10 am Post subject: |
|
|
We recently had a discussion on slowing the player's turn speed... I forget which thread. Does anyone have the link? _________________ When my computer inevitably explodes and kills me, my cat inherits everything I own. He may be the only one capable of continuing my work. |
|
Back to top |
|
 |
Baker

Joined: 14 Mar 2006 Posts: 1538
|
Posted: Tue Jan 19, 2010 3:51 am Post subject: |
|
|
Wazat wrote: | We recently had a discussion on slowing the player's turn speed... I forget which thread. Does anyone have the link? |
http://forums.inside3d.com/viewtopic.php?t=1874
(Obtained via: this Google query) _________________ Tomorrow Never Dies. I feel this Tomorrow knocking on the door ... |
|
Back to top |
|
 |
Spike
Joined: 05 Nov 2004 Posts: 944 Location: UK
|
Posted: Tue Jan 19, 2010 10:16 am Post subject: |
|
|
in regular quake, not all entities support movetype_walk, only players do. Are you sure your 'self' is really the player? _________________ What's a signature? |
|
Back to top |
|
 |
Urre

Joined: 05 Nov 2004 Posts: 1073 Location: Sweden
|
Posted: Tue Jan 19, 2010 1:17 pm Post subject: |
|
|
As I understand it, your target platform is PSP, correct? For that you'll probably have to stuffcmd to restrict turning speed, as whatever engine you're using probably doesn't have an alternative. Truth is it can be hard with engines which supposedly have alternatives, too. I can only imagine it being possible with CSQC, and I haven't tried it out personally. That is, if you're planning to restrict the mouse aiming speed too, not just the turning speed by keys.
Does the PSP Quake engine you're using use cl_yawspeed for turning? It might base it on some other cvar. _________________ Look out for Twigboy |
|
Back to top |
|
 |
mh

Joined: 12 Jan 2008 Posts: 910
|
Posted: Tue Jan 19, 2010 4:09 pm Post subject: |
|
|
If you're SP-only you can use cvar_set ("cl_yawspeed", "100") from QC and it should work. For MP it won't get from server to client(s) however. _________________ DirectQ Engine - New release 1.8.666a, 9th August 2010
MHQuake Blog (General)
Direct3D 8 Quake Engines |
|
Back to top |
|
 |
Wazat
Joined: 15 Oct 2004 Posts: 732 Location: Middle 'o the desert, USA
|
Posted: Wed Jan 20, 2010 4:58 am Post subject: |
|
|
Well, as discussed in the other thread, if you jump to 3rd person mode (or even stay in 1st person) and use a dummy object as the player, you CAN restrict turn speed very effectively that way (this is how most games do turrets & vehicles, etc).
If you don't want to use a dummy object as the player, a stuffcmd may be the only option. Hopefully that doesn't clobber the player's config if they quit at the wrong time, though! _________________ When my computer inevitably explodes and kills me, my cat inherits everything I own. He may be the only one capable of continuing my work. |
|
Back to top |
|
 |
|