Re: [hlcoders] gpGlobals->curtime inaccessable from animationlayer.h
-- [ Picked text/plain from multipart/alternative ] Thanks that worked out! ~M It's because one of the header files that BaseAnimatingOverlay.cpp > includes goes back and defines that class. You need to include the > header file that defines it by adding: > > #include "globalvars_base.h" -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders
Re: [hlcoders] gpGlobals->curtime inaccessable from animationlayer.h
It's because one of the header files that BaseAnimatingOverlay.cpp includes goes back and defines that class. You need to include the header file that defines it by adding: #include "globalvars_base.h" Michael Chang wrote: -- [ Picked text/plain from multipart/alternative ] Hello once again guys. I'm trying to implement clientside SetAnimation() so it required me to much around in animationlayer.h One of the required functions that I needed to duplicate was Init() from BaseAnimatingOverlays. Inside Init, there's a call to gpGlobals->curtime to store last time stamp a frame was accessed (I think). However in implementing the same function on animationlayer.h, my compiler tells me Error1error C2027: use of undefined type 'CGlobalVarsBase' c:\bb\src\cl_dll\animationlayer.h102 How come BaseAnimatingOverlays has access to CGlobalVarsBase but not animationlayer? Is it because animationlayer is a header, and won't have scope of that variable? If that's the case, should I create some form of animationlayers.cpp in order to obtain such scope? Thanks guys. I'm a bit rusty with my C++ so bear with me. ~M -- ___ 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
[hlcoders] gpGlobals->curtime inaccessable from animationlayer.h
-- [ Picked text/plain from multipart/alternative ] Hello once again guys. I'm trying to implement clientside SetAnimation() so it required me to much around in animationlayer.h One of the required functions that I needed to duplicate was Init() from BaseAnimatingOverlays. Inside Init, there's a call to gpGlobals->curtime to store last time stamp a frame was accessed (I think). However in implementing the same function on animationlayer.h, my compiler tells me Error1error C2027: use of undefined type 'CGlobalVarsBase' c:\bb\src\cl_dll\animationlayer.h102 How come BaseAnimatingOverlays has access to CGlobalVarsBase but not animationlayer? Is it because animationlayer is a header, and won't have scope of that variable? If that's the case, should I create some form of animationlayers.cpp in order to obtain such scope? Thanks guys. I'm a bit rusty with my C++ so bear with me. ~M -- ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlcoders