-Miku Miku Online 0.2.7
+Miku Miku Online 0.3.2
// ******************************** 警告 *********************************** //
// ***
=== 動作環境
- Windows Vista, 7
+ Windows XP, Vista, 7
2GB RAM
DirectX 9
シェーダーモデル 2.0 以上
SetModel(loading_model_handle_);
loading_model_handle_ = ModelHandle();
}
+
+ // 落ちた時に強制復帰
+ if (prev_stat_.pos.y < stage_->min_height()) {
+ RescuePosition();
+ }
/*
if (key_checker_.Check() == -1)
{
Stage::Stage(const tstring& model_name) :
map_handle_(ResourceManager::LoadModelFromName(model_name)),
- map_scale_(map_handle_.property().get<float>("scale", 20.0))
+ map_scale_(map_handle_.property().get<float>("scale", 20.0)),
+ min_height_(map_handle_.property().get<float>("min_height", -200.0))
{
MV1SetScale(map_handle_.handle(), VGet(map_scale_, map_scale_, map_scale_));
MV1SetupCollInfo(map_handle_.handle(), -1, 256, 256, 256);
{
MMO_PROFILE_FUNCTION;
- auto coll_info = MV1CollCheck_Line(map_handle_.handle(), -1, point, GetCameraPosition());
+ const auto& camera = GetCameraPosition();
+
+ auto distance = (point.x - camera.x) * (point.x - camera.x) +
+ (point.y - camera.y) * (point.y - camera.y) +
+ (point.z - camera.z) * (point.z - camera.z);
+
auto screen_pos = ConvWorldPosToScreenPos(point);
- return (!coll_info.HitFlag && screen_pos.z > 0.0f && screen_pos.z < 1.0f);
+ return (distance < 500000 && screen_pos.z > 0.0f && screen_pos.z < 1.0f);
}
void Stage::UpdateSkymapPosition(const VECTOR& pos)
{
return map_scale_;
}
+
+float Stage::min_height() const
+{
+ return min_height_;
+}
\ No newline at end of file
const ModelHandle& map_handle() const;
float map_scale() const;
+ float min_height() const;
const std::vector<VECTOR>& start_points() const;
private:
ModelHandle map_handle_;
float map_scale_;
+ float min_height_;
ModelHandle skymap_handle_;
std::vector<VECTOR> start_points_;
}
auto camera_pos_delta = VScale(camera_pos - GetCameraPosition(),(float)0.3);
- if (VSize(camera_pos_delta) > 10) {
- camera_pos_delta = VNorm(camera_pos_delta) * 10;
- }
+ // if (VSize(camera_pos_delta) > 10) {
+ // camera_pos_delta = VNorm(camera_pos_delta) * 10;
+ //}
SetCameraPositionAndTarget_UpVecY(
GetCameraPosition() + camera_pos_delta, target_pos);
#define MMO_VERSION_MAJOR 0
#define MMO_VERSION_MINOR 3
-#define MMO_VERSION_REVISION 1
+#define MMO_VERSION_REVISION 2
#ifdef MMO_VERSION_BUILD
#define MMO_VERSION_BUILD_TEXT " Build " MMO_VERSION_TOSTRING(MMO_VERSION_BUILD)
#ifdef _WIN32
-std::string sjis2utf8(std::string);
-std::string utf82sjis(std::string);
+std::string sjis2utf8(const std::string&);
+std::string utf82sjis(const std::string&);
std::string ToString(const std::wstring& s);
std::wstring ToWString(const std::string& s);