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
1 registered members (TipmyPip), 18,449 guests, and 6 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
Page 2 of 3 1 2 3
Re: ENABLE_IMPACT doesn´t work [Re: MoRRoW] #284673
08/14/09 13:50
08/14/09 13:50
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
So is your "re-created" project in C-Script (*.WDL files), or Lite-C (*.C & *.H files)?

If its all WDL files (like A6) then it is C-Script, and you are in the wrong forum.
I suspect this to be the case, and no harm done, we'll still try to help.

And NO, Im not complaining, just clarifying.
People will keep giving you Lite-C answers, because they THINK you are using lite-c,
because you are in the Lite-C forum, and that will just confuse things more.

So what are you? C-Script (still living and breathing in A7), or the new and wonderous Lite-C?
Dont be afraid to answer, I think MOST of the true experts around here still prefer C-Script.
But we do need to know cause there are many little differences in syntax between c-script and lite-c,
so we need to know where you stand to know which syntax's will work for you.


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial
Re: ENABLE_IMPACT doesn´t work [Re: EvilSOB] #284675
08/14/09 13:56
08/14/09 13:56
Joined: Jun 2009
Posts: 44
NRW,Germany
MoRRoW Offline OP
Newbie
MoRRoW  Offline OP
Newbie

Joined: Jun 2009
Posts: 44
NRW,Germany
It´s C-Script so you´re right I´m in the wrong Forum sry for that
,didn´t think about it.


If you are unable to learn new stuff,you have to learn to learn new stuff!
A7 7.80 Commercial
Re: ENABLE_IMPACT doesn´t work [Re: MoRRoW] #284676
08/14/09 13:59
08/14/09 13:59
Joined: May 2009
Posts: 137
Ohio, U.S.A.
PigHunter Offline
Member
PigHunter  Offline
Member

Joined: May 2009
Posts: 137
Ohio, U.S.A.
Also, it might help if you post the relevant part/s of the script/s.

Re: ENABLE_IMPACT doesn´t work [Re: PigHunter] #284678
08/14/09 14:08
08/14/09 14:08
Joined: Jun 2009
Posts: 44
NRW,Germany
MoRRoW Offline OP
Newbie
MoRRoW  Offline OP
Newbie

Joined: Jun 2009
Posts: 44
NRW,Germany
So heres the top of the main script with the included scripts in order they are loaded

// Included files
include <gid01.wdl>;
include <display00.wdl>;
include <lflare.wdl>;
include <player.wdl>;
include <Gateworlds.wdl>;
include <dhdop.wdl>;
include <dhdopa.wdl>;
include <default.fx>;
include <mtlFX.wdl>;
include <MtlTerrainMulti.wdl>;

The function I want to call is defined in Gateworlds.wdl

Here now the script with the IMPACT function
It´s not written very clean so sry for that.

var the_gate = 2345678;
var the_gateb = 1234567;
var entered_number = 0;
string entry_line[8]; // ein leerer string
string adress = "ENTER GATE ADRESS";
sound horizon = <horizo.wav>;
sound gateclose = <gateclose.wav>;
sound chevs = <chevlock.wav>;
sound spin = <spinner.wav>;
sound openst = <gateopen1st.wav>;
sound opennd = <gateopen2nd.wav>;
string horizont = <eh3.mdl>;
string res1 = <planet2.wmb>;
string res2 = <eh3.mdl>;
var indicator = 0;
var my_pos[3];
var my_angle[3];
var_nsave gateoffen;
var_nsave drehen;
var x = 0;
var y = 0;
var b = 0;
var k = 0;
var l = 0;
define _alpha__00C, skill1;
define _vel_x__00C,skill2;
define _vel_y__00C,skill3;
define _vel_z__00C,skill4;
define _damage__00C, skill2;
var dhd;
var vektor[3];
var vektor2[3];
include <chevrons.wdl>;
include <chevronsa.wdl>;




text screen_txt // text objekt
{
font = _a4font;
pos_x = 260;
pos_y = 240;
}

function print(str)
{
screen_txt.string = str;
screen_txt.visible = on;
}


function scan_me()
{
my_pos.x = camera.x;
my_pos.y = camera.y;
my_pos.z = camera.z;
my_angle.pan = camera.pan;
my_angle.tilt = camera.tilt;
dhd.x = 120;
dhd.y = 180;
dhd.z = 300; // scan reichweite 200 quants
indicator = 1;
c_scan(camera.x,camera.pan,vector(120,0,200),dhd);
}

on_space = scan_me;

entity tor
{
type = <erdetorohnechevs.mdl>;
layer = 2;
flags = visible;
view = CAMERA;

}




Function ziela()
{

my.lightrange = 700;
my.Light = on;
my.blue = 255;
my.enable_impact = on; <------ That´s the Problem
my.event = level_A;
my._gid01_id = gid01_forcefield_const;
my.transparent = on;
my.alpha = 75;
vec_set(my._gid01_vel_x,my._vel_x__00C);
wait(1);

ent_playsound(tor, opennd , 1000);
wait(1);
gateoffen = ent_playloop(me,horizon,1000);

while (x < 3200)
{
x += 1;
my.skin = my.skill1 % 10;
my.skill1 += 0.5*time;
wait (1);
}
wait(1);
x -= 3200;
wait(1);
snd_stop (gateoffen);
wait(1);
ent_playsound(tor, gateclose, 1000);
wait (1);
while (y < 80)
{
y += 1;
my.skin = my.skill1 % 10; // Skins
my.skill1 += 0.5*time; // 5 skins pro second
wait (1);
}
wait(1);
y -= 80;
wait(1);
ent_remove(me);
wait(1);

}


function anwahl
{

if (entered_number == the_gate)
{
ziela();
}

else
{
ent_remove(me);
}
}



function check_gate
{
proc_kill(4);
waitt(16); // warte 16 ticks (1 sekunde)
print(adress);
sleep(1);
print(entry_line);
inkey(entry_line); // fordert eingabe der tastatur an
entered_number = str_to_num(entry_line); // konvertiert eingabe in eine zahlenfolge
drehen = ent_playloop(tor, spin, 1000);
sleep(4);
ent_playsound(tor, chevs, 1000);
ent_create (chevli1on,ch1,che1);
sleep(4);
ent_playsound(tor, chevs, 1000);
ent_create (chevli2on,ch2,che2);
sleep(4);
ent_playsound(tor, chevs, 1000);
ent_create (chevli3on,ch3,che3);
sleep(4);
ent_playsound(tor, chevs, 1000);
ent_create (chevli4on,ch4,che4);
sleep(4);
ent_playsound(tor, chevs, 1000);
ent_create (chevli5on,ch5,che5);
sleep(4);
ent_playsound(tor, chevs, 1000);
ent_create (chevli6on,ch6,che6);
sleep(4);
ent_playsound(tor, chevs, 1000);
ent_create (chevli7on,ch7,che7);
sleep(1);
snd_stop(drehen);
wait(4);
ent_playsound(tor, openst, 1000);
wait(1);
screen_txt.visible = off;
wait(17);
ent_create (horizont, vektor, anwahl);
}


function start
{ wait(1);
my.passable = on;
my.lightrange = 700;
my.Light = on;
my.blue = 255;

my._gid01_id = gid01_forcefield_const;
my.transparent = on;
my.alpha = 75;
vec_set(my._gid01_vel_x,my._vel_x__00C);
wait(1);
gateoffen = ent_playloop(me,horizon,1000);


while (k < 500)
{
k += 1;
my.skin = my.skill1 % 10;
my.skill1 += 0.5*time;
wait (1);
}
wait(1);
k -= 500;
wait(1);
snd_stop (gateoffen);
wait(1);
ent_playsound(tor, gateclose, 1000);
wait (1);
while (l < 75)
{
l += 1;
my.skin = my.skill1 % 10; // Skins
my.skill1 += 0.5*time; // 5 skins pro second
wait (1);
}
wait(1);
l -= 75;
wait(1);
ent_remove(me);
wait(1);
}


action dhd_akt
{
my.metal = on;
my.albedo = 30;
my.enable_scan = on;
my.event = check_gate;


}


P.S. This is the unmodified original Script


Last edited by MoRRoW; 08/14/09 14:13.

If you are unable to learn new stuff,you have to learn to learn new stuff!
A7 7.80 Commercial
Re: ENABLE_IMPACT doesn´t work [Re: MoRRoW] #284680
08/14/09 14:31
08/14/09 14:31
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
OK, I'll apply my limited C-Script skills and see how we go.

1> Try changing the my.enable_impact = on; line to be my.ENABLE_IMPACT = on;
just in case capitals for ENABLE_IMPACT is important.(I dont think it is though)

2> Try adding (before my.event gets set) my.push = 100;
(This entities push value must be higher than whatever it gets hit by)

3> Show us the "Level_A" function, in case its something wrong in there...

Otherwise everything looks OK to my limited skills.


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial
Re: ENABLE_IMPACT doesn´t work [Re: EvilSOB] #284682
08/14/09 14:36
08/14/09 14:36
Joined: Jun 2009
Posts: 44
NRW,Germany
MoRRoW Offline OP
Newbie
MoRRoW  Offline OP
Newbie

Joined: Jun 2009
Posts: 44
NRW,Germany
No the changes didn´t work.
Thanks anyway,here the called function

var movie_handle;

function level_A()
{ proc_kill(3);
player.passable = on;
wait(1);
movie_handle = media_play("pegasustravel11.mpg",null,100);
while (media_playing (movie_handle) == 0) {wait (1);}
while (media_playing (movie_handle) != 0) {wait (1);}
wait(1);
level_load ("P3X-771.wmb");
wait(1);
}


If you are unable to learn new stuff,you have to learn to learn new stuff!
A7 7.80 Commercial
Re: ENABLE_IMPACT doesn´t work [Re: MoRRoW] #284688
08/14/09 15:17
08/14/09 15:17
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline
Expert
Germanunkol  Offline
Expert

Joined: Jun 2006
Posts: 2,640
Earth
take out the line player.passable = on;

A passable player won't collide and thus not call any events.


~"I never let school interfere with my education"~
-Mark Twain
Re: ENABLE_IMPACT doesn´t work [Re: Germanunkol] #284718
08/14/09 18:29
08/14/09 18:29
Joined: Jun 2009
Posts: 44
NRW,Germany
MoRRoW Offline OP
Newbie
MoRRoW  Offline OP
Newbie

Joined: Jun 2009
Posts: 44
NRW,Germany
@ Germanunkol
First thanks for your post,but you misunderstood the situation,the player isn´t passable when he should collide with the Entity.The function level_A I had posted has to be called after the collide,so you see the player gets passable,but isn´t in the situation my problem ocured.


If you are unable to learn new stuff,you have to learn to learn new stuff!
A7 7.80 Commercial
Re: ENABLE_IMPACT doesn´t work [Re: MoRRoW] #284733
08/14/09 19:13
08/14/09 19:13
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline
Expert
Germanunkol  Offline
Expert

Joined: Jun 2006
Posts: 2,640
Earth
uh, my bad. i must admit, I didn't read it all very carefully, i just skipped through fast ...


~"I never let school interfere with my education"~
-Mark Twain
Re: ENABLE_IMPACT doesn´t work [Re: Germanunkol] #284739
08/14/09 19:34
08/14/09 19:34
Joined: Jun 2009
Posts: 44
NRW,Germany
MoRRoW Offline OP
Newbie
MoRRoW  Offline OP
Newbie

Joined: Jun 2009
Posts: 44
NRW,Germany
No Problem


If you are unable to learn new stuff,you have to learn to learn new stuff!
A7 7.80 Commercial
Page 2 of 3 1 2 3

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

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