Different inherited class objects in same list?

Started by
11 comments, last by kzar 18 years, 4 months ago
You need to use
(*current_entity)->update();
Advertisement
Quote:Original post by kzar
I have roughly coded most of the stuff I was thinking of now but I am getting an odd error.

"entity.cpp:33: error: request for member `update' in `*(&current_entity)->std::_List_iterator<_Tp>::operator-> [with _Tp = cEntity*]()', which is of non-class type `cEntity*'"

(line 33 is the current_entity->update(); line neer the bottom here)

*** Source Snippet Removed ***

Any ideas? Thanks


try:

(*current_entity)->update();
Thanks for the help guys, I have pretty much got it working now. :)

This topic is closed to new replies.

Advertisement