Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
0 registered members (), 17,758 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
E-Ball Problem #164262
10/29/07 17:30
10/29/07 17:30
Joined: Sep 2007
Posts: 28
C
craik Offline OP
Newbie
craik  Offline OP
Newbie
C

Joined: Sep 2007
Posts: 28
Hallo,
ich habe ne frage also:
ich will folgenden Code benutzen :
Code:
  
function wizard
{
clip_size = 0;
while (1)
{
while (my.skill10 < 95)
{
ent_cycle ("attack", my.skill10); // play the attack animation frames
my.skill10 += 3 * time;
wait (1);
}
eball_pos.x = my.x;
eball_pos.y = my.y;
eball_pos.z = my.z + 25; // the energy ball appears betwen wizard's hands
ent_create (energyball_mdl, eball_pos, energy_ball);
snd_play (energy_snd, 70, 0);
waitt (16);
while (my.skill10 > 2)
{
ent_cycle ("attack", my.skill10); // play the attack animation frames
my.skill10 -= 2 * time;
wait (1);
}
waitt (32);
}
}

function energy_ball()
{
wait (1);
my.enable_entity = on;
my.enable_block = on;
my.event = remove_eball;
my.pan = you.pan;
my.tilt = you.tilt;
my.lightred = 250;
my.lightgreen = 150;
my.lightrange = 200;
eball_speed.x = 20;
eball_speed.y = 0;
eball_speed.z = 0;
eball_speed *= time;
while (my != null)
{
my.roll += 20 * time;
move_mode = ignore_you + ignore_passents;
ent_move (eball_speed, nullvector);
wait (1);
}
}

function remove_eball()
{
wait (1);
if (you == player)
{
health -= 25; // decrease player's health
}
ent_remove (me);
}


mein Problem ist nun das wenn ich die function wizard nun auf eine taste speichere er mir natürlich sagt emty pointer my.skill etc wie kann ich es realiesieren das ich nen ordentlichen e-ball bekomme ohne daraus eine action zu machen (mein player hat schon eine und wenn ich sie dabei packe macht der komischen blödsinn ^^)
wäre net wenn ihr antworten hättet
mfg craik

Last edited by craik; 10/29/07 17:33.
Re: E-Ball Problem [Re: craik] #164263
10/29/07 17:51
10/29/07 17:51
Joined: Jul 2007
Posts: 959
nl
F
flits Offline
User
flits  Offline
User
F

Joined: Jul 2007
Posts: 959
nl
hey

ent_cycle is a old syntax you need to use:
ent_animate(my,"attack",my.skill10,anm_cycle);


"empty"
Re: E-Ball Problem [Re: flits] #164264
10/29/07 18:03
10/29/07 18:03
Joined: Sep 2007
Posts: 28
C
craik Offline OP
Newbie
craik  Offline OP
Newbie
C

Joined: Sep 2007
Posts: 28
Danke für die Antwort aber im Gurnde wirts mir nicht helfen oder ^^

Re: E-Ball Problem [Re: craik] #164265
10/29/07 18:15
10/29/07 18:15
Joined: Jul 2002
Posts: 4,436
Germany, Luebeck
Xarthor Offline
Expert
Xarthor  Offline
Expert

Joined: Jul 2002
Posts: 4,436
Germany, Luebeck
Willst du das dein player diesen E-Ball wirft?
Oder was ist dein ziel?

Re: E-Ball Problem [Re: Xarthor] #164266
10/29/07 18:51
10/29/07 18:51
Joined: Jul 2007
Posts: 959
nl
F
flits Offline
User
flits  Offline
User
F

Joined: Jul 2007
Posts: 959
nl
oke get the stupid problem
first pleacse say the preciese error that will speed up

then while(my.skill10 < 95) must be while(my.skill10 <= 95)
and then but not realy importent time == time_step but better


ow still not working are you sure you this function is connected white a entity

Last edited by flits; 10/29/07 18:56.

"empty"
Re: E-Ball Problem [Re: flits] #164267
10/29/07 18:59
10/29/07 18:59
Joined: Jul 2007
Posts: 959
nl
F
flits Offline
User
flits  Offline
User
F

Joined: Jul 2007
Posts: 959
nl
oke i tested it white ent_create and on my pc it worked and it wasnt the <= problem


"empty"
Re: E-Ball Problem [Re: flits] #164268
10/29/07 20:13
10/29/07 20:13
Joined: Sep 2007
Posts: 28
C
craik Offline OP
Newbie
craik  Offline OP
Newbie
C

Joined: Sep 2007
Posts: 28
ja ich würde es gerne so haben das mein playewr den ball wirft ^^

Re: E-Ball Problem [Re: craik] #164269
10/29/07 20:16
10/29/07 20:16
Joined: Jul 2002
Posts: 4,436
Germany, Luebeck
Xarthor Offline
Expert
Xarthor  Offline
Expert

Joined: Jul 2002
Posts: 4,436
Germany, Luebeck
Code:

function shoot_eBall()
{
while(!player) { wait(1); }
vec_set(eball_pos,player.x);
eball_pos.z += 25;
ent_create (energyball_mdl, eball_pos, energy_ball);
}

on_mouse_left = shoot_eball;




Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1