diff --git a/Projects/Android/jni/QzDoom/QzDoom_SurfaceView.c b/Projects/Android/jni/QzDoom/QzDoom_SurfaceView.c index 79b9063..6ecf2de 100644 --- a/Projects/Android/jni/QzDoom/QzDoom_SurfaceView.c +++ b/Projects/Android/jni/QzDoom/QzDoom_SurfaceView.c @@ -864,11 +864,6 @@ void setHMDPosition( float x, float y, float z, float yaw ) } } -bool isMultiplayer() -{ - return false;//Cvar_VariableValue("maxclients") > 1; -} - /* ======================== diff --git a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/g_statusbar/sbar_mugshot.cpp b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/g_statusbar/sbar_mugshot.cpp index 1662fdf..2e17cf5 100644 --- a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/g_statusbar/sbar_mugshot.cpp +++ b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/g_statusbar/sbar_mugshot.cpp @@ -337,6 +337,8 @@ bool FMugShot::SetState(const char *state_name, bool wait_till_done, bool reset) // //=========================================================================== +extern "C" void QzDoom_Vibrate(float duration, int channel, float intensity ); + CVAR(Bool,st_oldouch,false,CVAR_ARCHIVE) int FMugShot::UpdateState(player_t *player, StateFlags stateflags) { @@ -348,6 +350,10 @@ int FMugShot::UpdateState(player_t *player, StateFlags stateflags) { if (player->bonuscount) { + //Short haptic blip on pickup + QzDoom_Vibrate(80, 0, 1.0); // left + QzDoom_Vibrate(80, 1, 1.0); // right + SetState("grin", false); return 0; } diff --git a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/gl/stereo3d/gl_stereo_cvars.cpp b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/gl/stereo3d/gl_stereo_cvars.cpp index 2607804..bce29b0 100644 --- a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/gl/stereo3d/gl_stereo_cvars.cpp +++ b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/gl/stereo3d/gl_stereo_cvars.cpp @@ -56,7 +56,7 @@ CVAR(Float, vr_ipd, 0.064f, CVAR_ARCHIVE|CVAR_GLOBALCONFIG) // METERS CVAR(Float, vr_screendist, 0.80f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) // METERS // default conversion between (vertical) DOOM units and meters -CVAR(Float, vr_vunits_per_meter, 38.0f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) // METERS +CVAR(Float, vr_vunits_per_meter, 34.0f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) // METERS CVAR(Float, vr_height_adjust, 0.0f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) // METERS CVAR(Int, vr_control_scheme, 0, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) CVAR(Bool, vr_move_use_offhand, true, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) @@ -68,8 +68,8 @@ CVAR(Int, vr_move_speed, 24, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) CVAR(Float, vr_run_multiplier, 1.6, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) //HUD control -CVAR(Float, vr_hud_scale, 0.5f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) -CVAR(Float, vr_hud_stereo, 1.0f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) +CVAR(Float, vr_hud_scale, 0.3f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) +CVAR(Float, vr_hud_stereo, 1.8f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) CVAR(Float, vr_hud_rotate, 35.f, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) CVAR(Bool, vr_hud_fixed_pitch, true, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) CVAR(Bool, vr_hud_fixed_roll, true, CVAR_ARCHIVE | CVAR_GLOBALCONFIG) diff --git a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/p_mobj.cpp b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/p_mobj.cpp index 3ac894c..ca897b8 100644 --- a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/p_mobj.cpp +++ b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/p_mobj.cpp @@ -6771,22 +6771,25 @@ AActor *P_SpawnPlayerMissile (AActor *source, double x, double y, double z, MissileActor->Vel3DFromAngle(pitch, MissileActor->Speed); } - - //Haptics - long rightHanded = vr_control_scheme < 10; - QzDoom_Vibrate(150, rightHanded ? 1 : 0, 0.8); - if (weaponStabilised) - { - QzDoom_Vibrate(150, rightHanded ? 0 : 1, 0.6); - } - - if (MissileActor->flags4 & MF4_SPECTRAL) { MissileActor->SetFriendPlayer(source->player); } + if (P_CheckMissileSpawn (MissileActor, source->radius)) { + //Could be the Brutal Doom flashlight! + if (MissileActor->DamageType.GetIndex() != 0) + { + //Haptics + long rightHanded = vr_control_scheme < 10; + QzDoom_Vibrate(150, rightHanded ? 1 : 0, 0.8); + if (weaponStabilised) + { + QzDoom_Vibrate(150, rightHanded ? 0 : 1, 0.6); + } + } + return MissileActor; } return NULL; diff --git a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/v_blend.cpp b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/v_blend.cpp index 41a02c2..a12bd75 100644 --- a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/v_blend.cpp +++ b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/src/v_blend.cpp @@ -99,6 +99,8 @@ void V_AddBlend (float r, float g, float b, float a, float v_blend[4]) // //--------------------------------------------------------------------------- +extern "C" void QzDoom_Vibrate(float duration, int channel, float intensity ); + void V_AddPlayerBlend (player_t *CPlayer, float blend[4], float maxinvalpha, int maxpainblend) { int cnt; @@ -126,6 +128,10 @@ void V_AddPlayerBlend (player_t *CPlayer, float blend[4], float maxinvalpha, int { cnt = CPlayer->bonuscount << 3; + //Super short haptic blip on pickup + QzDoom_Vibrate(50, 0, 0.7); // left + QzDoom_Vibrate(50, 1, 0.7); // right + // [SP] Allow player to tone down intensity of pickup flash. cnt = (int)( cnt * pickup_fade_scalar ); diff --git a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/wadsrc/static/menudef.txt b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/wadsrc/static/menudef.txt index 02511d9..a881525 100644 --- a/Projects/Android/jni/gzdoom-g3.3mgw_mobile/wadsrc/static/menudef.txt +++ b/Projects/Android/jni/gzdoom-g3.3mgw_mobile/wadsrc/static/menudef.txt @@ -2304,8 +2304,8 @@ OptionMenu VROptionsMenu protected StaticText " " Slider "VR HUD Scale", "vr_hud_scale", 0.05, 1.0, 0.05, 2 - Slider "VR HUD Stereo", "vr_hud_stereo", 0.05, 2.0, 0.05, 2 - Slider "VR HUD Pitch Rotate", "vr_hud_rotate", 0.0, 50.0, 2.0, 2 + Slider "VR HUD Stereo", "vr_hud_stereo", 0.0, 3.0, 0.1, 2 + Slider "VR HUD Pitch Rotate", "vr_hud_rotate", 0.0, 50.0, 1.0, 2 Option "VR HUD Fix Pitch", "vr_hud_fixed_pitch", "OnOff" Option "VR HUD Fix Roll", "vr_hud_fixed_roll", "OnOff" } diff --git a/assets/res/lzdoom.pk3 b/assets/res/lzdoom.pk3 index c458416..abd53ca 100644 Binary files a/assets/res/lzdoom.pk3 and b/assets/res/lzdoom.pk3 differ