|
7 registered members (TipmyPip, Martin_HH, Volkovstudio, AndrewAMD, JMMAC, Grant, 1 invisible),
5,432
guests, and 2
spiders. |
|
Key:
Admin,
Global Mod,
Mod
|
|
|
My hero starts flying? WHY?!
#10802
10/27/02 15:10
10/27/02 15:10
|
Joined: Oct 2002
Posts: 291 Sydney, Australia
MGS
OP
Member
|
OP
Member
Joined: Oct 2002
Posts: 291
Sydney, Australia
|
Hello, everybody. To start with, I haven't got any answer to my question in the Beginners forum, so I really hope that anyone would be experienced enough here to help me. I would appreciate any hint. I have the following problem: I'm trying to study one of the code snippets (game templates) from our beloved AUM - air combat game where a player shoots helicopters with a rocket. I have modified a couple of things like helicopters generation and player data indication, but what I don't like at all is how the sky looks. It's simply terrible - that sky cube with standard animated sky texture. I have found one very nice sky sphere with a texture on "Terminal 26" website and wanted to replace that awful sky cube with that nice sky sphere. I didn't change anything else - I swear. You know what happens now? When I start my level, my hero simply starts slowly floating into the air! Getting higher and higher, verdammt noch mal! Really surprising, because the only thing that I've changed was deleting the cube and inserting that sphere into my level. I HAVEN'T changed player movement code anyhow. Here is how it looks like: code:
action player_moves { player = me; my.health = 100; my.invisible = on;
my.enable_impact = on; my.enable_entity = on; my.event = player_event;
while (my.health > 0) { vec_set (camera.pos, my.pos); camera.tilt += 20 * mouse_force.y * time; camera.pan -= 20 * mouse_force.x * time; my.pan = camera.pan; my.tilt = camera.tilt; player_speed.x = 15 * (key_w - key_s) * time - 0.5 * recoil; player_speed.y = 10 * (key_a - key_d) * time; vec_set (temp, my.x); temp.z -= 1000; trace_mode = ignore_me + use_box; player_speed.z = -trace (my.x, temp); move_mode = ignore_you + ignore_passable; ent_move(player_speed, nullvector);
wait (1); } }
Please, could anyone tell me what could be the reason for such a ridiculous model behaviour?
|
|
|
Re: My hero starts flying? WHY?!
#10803
10/28/02 03:40
10/28/02 03:40
|
Anonymous
Unregistered
|
Anonymous
Unregistered
|
In the manual it says something about setting your Z axis movement to 0.
Keeps your character from moving up or something...
|
|
|
Re: My hero starts flying? WHY?!
#10808
10/29/02 00:38
10/29/02 00:38
|
Anonymous
Unregistered
|
Anonymous
Unregistered
|
Yeah, this sounds like your model is in some geometry. You will start floating if that happens.
Make your sphere passable and make sure your character isn't "in" anything.
-Jeff
|
|
|
Re: My hero starts flying? WHY?!
#10810
10/29/02 06:34
10/29/02 06:34
|
Anonymous
Unregistered
|
Anonymous
Unregistered
|
Hmm, I had this exact problem before and I remedied it by using an .mdl sphere with "My.passable = On" in it's action.
Remove your sky box again, bring in your sky sphere and attach this action to it.
Action SkyTest{ My.passable = on; }
See if that works.
|
|
|
Re: My hero starts flying? WHY?!
#10811
10/29/02 14:52
10/29/02 14:52
|
Joined: Oct 2002
Posts: 291 Sydney, Australia
MGS
OP
Member
|
OP
Member
Joined: Oct 2002
Posts: 291
Sydney, Australia
|
Sorry, Jeff, it's still not working. Really really strange. You have seen my movement code and read all my explanations - I ONLY replace cube with sphere. Here, I made two screenshots so that you get a picture of what's happening: 1). Normal behaviour - SKY BOX (CUBE) 2). Floating in the air - SKY SPHERE
|
|
|
|