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 (), 18,561 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
trouble converting from c-script #212318
06/21/08 15:20
06/21/08 15:20
Joined: Aug 2005
Posts: 199
houston
S
seneca Offline OP
Member
seneca  Offline OP
Member
S

Joined: Aug 2005
Posts: 199
houston
trying to convert to lite-c, but i got an issue. I was holding off on converting because i know i would have trouble.

the problem is i keep getting compile errors that state a certain object is no longer a member of a certain class.

i.e. "v: is not a member of ENTITY"

the code is is simply:

Code:
action conveyer()
{
   while (1)
   {
      my.v += conveyer_speed * time_step;
      wait (1);
   }
}
 


i had problems with other members that used to work as well before the conversion. I did search the forums but i didn't find what i was looking for. I'm hoping i don't have to overload the ENTITY class to get it to work. I figured that the manual would have said so, but according to them, what is written above is the right way to code it.

Any help is appreciated.


a8 commercial
Re: trouble converting from c-script [Re: seneca] #212327
06/21/08 15:45
06/21/08 15:45
Joined: Oct 2006
Posts: 873
S
Shadow969 Offline
User
Shadow969  Offline
User
S

Joined: Oct 2006
Posts: 873
the above code works fine for me. check if the 'my' pointer is valid...

Re: trouble converting from c-script [Re: Shadow969] #212351
06/21/08 18:29
06/21/08 18:29

F
Fear411
Unregistered
Fear411
Unregistered
F



you can only use my.x,my.y,my.z not my.v
you habe to define it before you use my.v in a class or struct

Re: trouble converting from c-script [Re: ] #212401
06/22/08 09:20
06/22/08 09:20
Joined: Jan 2003
Posts: 4,615
Cambridge
Joey Offline
Expert
Joey  Offline
Expert

Joined: Jan 2003
Posts: 4,615
Cambridge
v was the texture coordinate offset in relative x direction. i think you have to use one of the predefined materials now.

Re: trouble converting from c-script [Re: Joey] #212415
06/22/08 11:14
06/22/08 11:14
Joined: Oct 2004
Posts: 4,134
Netherlands
Joozey Offline
Expert
Joozey  Offline
Expert

Joined: Oct 2004
Posts: 4,134
Netherlands
u is x direction and v is y direction. I have it working on my game. But you need to use my->v if my is an ENTITY* rather than an ENTITY. It's probably not solving the problem but you never know...


Click and join the 3dgs irc community!
Room: #3dgs
Re: trouble converting from c-script [Re: Joozey] #212419
06/22/08 11:20
06/22/08 11:20
Joined: Jan 2003
Posts: 4,615
Cambridge
Joey Offline
Expert
Joey  Offline
Expert

Joined: Jan 2003
Posts: 4,615
Cambridge
you're right, i swapped the coordinates, sorry.

Quote:
The undocumented texture shifting by u,v parameters and by material scale parameters was discontinued for models (it still works for sprites). For texture shifting apply the fx_uvspeed action from the mtlFX template, which is faster and easier to use than u,v parameters. The uv shifting effect also works with the Standard and Extra editions.


Re: trouble converting from c-script [Re: Joey] #212436
06/22/08 12:49
06/22/08 12:49
Joined: Aug 2005
Posts: 199
houston
S
seneca Offline OP
Member
seneca  Offline OP
Member
S

Joined: Aug 2005
Posts: 199
houston
Thanks you very much for the input i will try that immediately


a8 commercial
Re: trouble converting from c-script [Re: seneca] #212448
06/22/08 14:03
06/22/08 14:03
Joined: Jul 2007
Posts: 959
nl
F
flits Offline
User
flits  Offline
User
F

Joined: Jul 2007
Posts: 959
nl
i never tryed it but maby you can use it vec_for_uv, vec_to_uv


"empty"
Re: trouble converting from c-script [Re: flits] #212633
06/23/08 14:29
06/23/08 14:29
Joined: Jan 2003
Posts: 4,615
Cambridge
Joey Offline
Expert
Joey  Offline
Expert

Joined: Jan 2003
Posts: 4,615
Cambridge
no, that's for something different.


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