doesnt seem like it can find any externs! I tried making a test.c file also
and it couldnt find the function there either

wierd!
----- Original Message -----
From: "Tom" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, January 01, 2002 7:24 PM
Subject: Re: [hlcoders] accessing functions not in pm code from pm code?


> thanks botman,
>
> I renamed the pm files to .cpp but it still says it cant find it! Just
still
> get the unresolvable external symbol (even though player.cpp can find it
> fine)
>
> ----- Original Message -----
> From: "botman" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, January 01, 2002 6:37 PM
> Subject: Re: [hlcoders] accessing functions not in pm code from pm code?
>
>
> > > Im having some trouble accessing functions from the pm shared code
which
> > are
> > > in cpp files. It seems that it doest like externs (well it can never
> find
> > the
> > > links).
> > >
> > > I cant really move all of the code into pm_shared because its also
used
> by
> > > triapi and on the serverside for some effects (and is also all based
on
> > > Vectors and not vec3_ts).
> > >
> > > Is it possible?
> >
> > C modules can't access C++ functions unless you've declared the C++
> > functions as 'extern "C"'.  The C code also won't be able to handle the
> > Vector class since C doesn't know classes.
> >
> > You can rename the .c files to .cpp to compile them as C++ modules
instead
> > of C modules (you might have to sort through several warnings/errors
since
> > C++ is more picky than C).
> >
> > It might be simpler just to copy the functions you need into a .c file
and
> > modify the Vector class stuff to use vec3_t arguments and functions
> instead
> > of using the class functions (i.e. use VectorAdd instead of v_src +
> v_dest).
> >
> > Jeffrey "botman" Broome
> >
> > _______________________________________________
> > To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> >
>
> _______________________________________________
> To unsubscribe, edit your list preferences, or view the list archives,
please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>

_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders

Reply via email to