bool CEnterExitMiniLift::MouseButtonDownMsg(CMouseButtonDownMsg *msg) {
	if (compareRoomNameTo("SgtLobby")) {
		_statics->_destView = getRoomNodeName() + ".S";
		_statics->_destRoom = "SgtLobby";
		changeView("SGTLittleLift.Node 1.E");

		CPetControl *pet = getPetControl();
		if (pet)
			pet->setRoomsRoomNum(_destRoomNum);
	} else if (compareRoomNameTo("SGTLittleLift")) {
		if (_statics->_changeViewFlag) {
			changeView(_statics->_destView);
		}
	}

	return true;
}
bool CEnterExitSecClassMiniLift::MouseButtonDownMsg(CMouseButtonDownMsg *msg) {
	if (compareRoomNameTo("2ndClassLobby")) {
		_statics->_viewName = getRoomNodeName() + ".W";
		changeView("SecClassLittleLift.Node 1.E");
		_statics->_state = 1;

		CPetControl *pet = getPetControl();
		if (pet) {
			pet->setRoomsRoomNum(_roomNum);
			pet->setRoomsSublevel(1);
		}
	} else if (compareRoomNameTo("SecClassLittleLift")) {
		if (_statics->_state == 1) {
			changeView(_statics->_viewName);
		}
	}

	return true;
}
Beispiel #3
0
bool CPETMonitor::EnterRoomMsg(CEnterRoomMsg *msg) {
    bool flag = true;
    if (msg->_newRoom && msg->_oldRoom) {
        CString oldRoomName = msg->_oldRoom->getName();
        CString newRoomName = msg->_newRoom->getName();

        if (newRoomName == "SgtLobby" && oldRoomName == "SGTState")
            flag = false;
    }

    if (flag) {
        CPetControl *pet = getPetControl();
        if (pet) {
            pet->setRoomsRoomNum(0);
            pet->resetRoomsHighlight();
        }
    }

    return true;
}