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,484 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
converting to lite c #348029
11/21/10 23:47
11/21/10 23:47
Joined: Jan 2010
Posts: 145
Doc_Savage Offline OP
Member
Doc_Savage  Offline OP
Member

Joined: Jan 2010
Posts: 145
im trying to convert from c-script. is there any tool or guide that can help me with this? ive looked at "migrating to lite c" but it dosent tell as much as id hoped. i keep having a problem with:


Code:
action attach_weapon() 
{
set(my, PASSABLE); 
proc_mode = PROC_LATE;
while (player != null) { wait(1); } {
vec_for_vertex(temp.x,player,125); //hand palm base
vec_for_vertex(temp2.x,player,130); //hand palm tip
vec_set(my.x,temp.x);
vec_diff(temp.x,temp2.x,temp.x);
vec_to_angle(temp.pan,temp.x);
vec_set(my.pan,temp.pan);
wait(1);
}
}



it says "while (player != null) { wait(1); } {while (player != null) { wait(1); } {" is an undeclared identifier. what does that even mean? lol. so can anyone help me? ive heard so much about lite c i want to use it so bad.


Do not concern yourself with my race, personality or origin. find my record in the pits, and then make your wager.
Re: converting to lite c [Re: Doc_Savage] #348033
11/22/10 02:03
11/22/10 02:03
Joined: Jul 2008
Posts: 1,178
England
M
MrGuest Offline
Serious User
MrGuest  Offline
Serious User
M

Joined: Jul 2008
Posts: 1,178
England
null needs to be NULL, lite-c's now case sensitive grin

and make sure you've defined temp somewhere, that'll probably be your next issue

Re: converting to lite c [Re: MrGuest] #348035
11/22/10 02:11
11/22/10 02:11
Joined: Jan 2010
Posts: 145
Doc_Savage Offline OP
Member
Doc_Savage  Offline OP
Member

Joined: Jan 2010
Posts: 145
omg nice, ok now ive got a problem with this line:

vec_for_vertex(temp.x,player,125); //hand palm base

says x isnt a member of function. darn i wish i knew this better

Last edited by Doc_Savage; 11/22/10 02:17.

Do not concern yourself with my race, personality or origin. find my record in the pits, and then make your wager.
Re: converting to lite c [Re: Doc_Savage] #348036
11/22/10 04:07
11/22/10 04:07
Joined: Apr 2005
Posts: 4,506
Germany
F
fogman Offline
Expert
fogman  Offline
Expert
F

Joined: Apr 2005
Posts: 4,506
Germany
Try to define temp as vector, not as var!
And you don´t need to write temp.x...
Just do it like this:

vec_for_vertex(temp,player,125); //hand palm base

Edit: This one compiles, but I haven´t tested it:

Code:
action attach_weapon() 
{
VECTOR temp;
VECTOR temp2;	
	
set(my, PASSABLE); 
proc_mode = PROC_LATE;
while (player != NULL) { wait(1); } {
vec_for_vertex(temp,player,125); //hand palm base
vec_for_vertex(temp2,player,130); //hand palm tip
vec_set(my.x,temp);
vec_diff(temp,temp2,temp);
vec_to_angle(temp,temp);
vec_set(my.pan,temp);
wait(1);
}
}



Hope it helps...

Last edited by fogman; 11/22/10 04:12.

no science involved
Re: converting to lite c [Re: fogman] #348046
11/22/10 07:15
11/22/10 07:15
Joined: May 2009
Posts: 5,377
Caucasus
3run Offline
Senior Expert
3run  Offline
Senior Expert

Joined: May 2009
Posts: 5,377
Caucasus
Try this one (not tested, but without errors):
Code:
action attach_weapon() 
{
	VECTOR base_vec;
	VECTOR tip_vec;
	ANGLE base_ang;
	set(my,PASSABLE); 
	proc_mode = PROC_LATE;
	while (player != NULL) { wait(1); } 
	while(1)
	{
		vec_for_vertex(base_vec.x,player,125); //hand palm base
		vec_for_vertex(tip_vec.x,player,130); //hand palm tip
		vec_set(my.x,base_vec.x);
		vec_diff(base_vec.x,tip_vec.x,base_vec.x);
		vec_to_angle(base_ang.pan,base_vec.x);
		vec_set(my.pan,base_ang.pan);
		wait(1);
	}
}




Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: converting to lite c [Re: 3run] #348187
11/23/10 17:00
11/23/10 17:00
Joined: Jan 2010
Posts: 145
Doc_Savage Offline OP
Member
Doc_Savage  Offline OP
Member

Joined: Jan 2010
Posts: 145
wow you guys are good. i wish i could convert this whole script real quick, any tool for doing that? some things i need to change i REALLY dont know what to change them to. its real annoying.

also, is gameplay gonna be different? like will things still work the same as it did in cscript?

Last edited by Doc_Savage; 11/23/10 17:42.

Do not concern yourself with my race, personality or origin. find my record in the pits, and then make your wager.
Re: converting to lite c [Re: Doc_Savage] #348205
11/23/10 21:59
11/23/10 21:59
Joined: May 2009
Posts: 5,377
Caucasus
3run Offline
Senior Expert
3run  Offline
Senior Expert

Joined: May 2009
Posts: 5,377
Caucasus
Everything will work as it use to work with old C-SCRIPT, even faster.
There is no tool for converting, its really easy if you'll get it yourself, use manual for that and start converting by little pieces.


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung
Re: converting to lite c [Re: 3run] #348332
11/25/10 05:00
11/25/10 05:00
Joined: Jan 2010
Posts: 145
Doc_Savage Offline OP
Member
Doc_Savage  Offline OP
Member

Joined: Jan 2010
Posts: 145
ill do just that. can i pm you if i hit a snag? i dont want to clutter up these boards with my whining lool. and thank you.


Do not concern yourself with my race, personality or origin. find my record in the pits, and then make your wager.
Re: converting to lite c [Re: Doc_Savage] #348335
11/25/10 05:41
11/25/10 05:41
Joined: May 2009
Posts: 5,377
Caucasus
3run Offline
Senior Expert
3run  Offline
Senior Expert

Joined: May 2009
Posts: 5,377
Caucasus
Sure, I'll be happy to help you laugh


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung

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