viewmodel fps fix, audio fix, docs
All checks were successful
studiorailgun/Renderer/pipeline/head This commit looks good
All checks were successful
studiorailgun/Renderer/pipeline/head This commit looks good
This commit is contained in:
parent
d15ba2445a
commit
37db40dc22
Binary file not shown.
Binary file not shown.
Binary file not shown.
3
docs/src/blender/BlenderSceneSetup.md
Normal file
3
docs/src/blender/BlenderSceneSetup.md
Normal file
@ -0,0 +1,3 @@
|
||||
@page blenderscenesetup Blender Scene Setp
|
||||
|
||||
Need to set the framerate of the scene to be 60fps
|
||||
@ -1,5 +1,6 @@
|
||||
@page blenderindex Blender
|
||||
|
||||
[TOC]
|
||||
- @subpage blenderscenesetup
|
||||
- @subpage WeavingMeshes
|
||||
- @subpage BasicClothingGuide
|
||||
@ -19,5 +19,5 @@
|
||||
|
||||
+ bug fixes
|
||||
Fix grass rendering distance
|
||||
Fix hitbox audio not playing spatially
|
||||
Fix audio freakout when attack while jumping/falling (should block regular attack while aerial)
|
||||
Fix audio freakout when attack while jumping/falling (should block regular attack while aerial)
|
||||
Fix server ground movement tree playing animation over falling animation
|
||||
@ -582,6 +582,7 @@ Better creature damage sfx
|
||||
Audio debugging
|
||||
Play animations offset by network delay
|
||||
- Attack animation
|
||||
Fix viewmodel animation framerate
|
||||
|
||||
|
||||
# TODO
|
||||
@ -603,6 +604,7 @@ Bug Fixes
|
||||
- Fix hitbox placement does not scale with entity scale on server
|
||||
- Fix not all grass tiles update when updating a nearby voxel (ie it doesn't go into negative coordinates to scan for foliage updates)
|
||||
- Fix typescript load error
|
||||
- Calculate bounding sphere for meshes by deforming vertices with bone default pose instead of no bone deform
|
||||
|
||||
Startup Performance
|
||||
- Cache loaded typescript
|
||||
|
||||
@ -94,6 +94,15 @@ public class ClientSceneWrapper {
|
||||
return serverToClientIdMap.containsKey(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the client->server map contains a given id
|
||||
* @param id The client id
|
||||
* @return true if there's a corresponding server id, false otherwise
|
||||
*/
|
||||
public boolean clientToServerMapContainsId(int id){
|
||||
return clientToServerIdMap.containsKey(id);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Gets the entity provided a server-provided id
|
||||
|
||||
@ -11,6 +11,8 @@ import electrosphere.entity.btree.StateTransitionUtil.StateTransitionUtilItem;
|
||||
import electrosphere.entity.state.collidable.Impulse;
|
||||
import electrosphere.entity.state.equip.ClientEquipState;
|
||||
import electrosphere.entity.state.hitbox.HitboxCollectionState;
|
||||
import electrosphere.entity.state.movement.FallTree;
|
||||
import electrosphere.entity.state.movement.jump.ClientJumpTree;
|
||||
import electrosphere.entity.state.rotator.RotatorTree;
|
||||
import electrosphere.entity.types.attach.AttachUtils;
|
||||
import electrosphere.entity.types.collision.CollisionObjUtils;
|
||||
@ -207,7 +209,6 @@ public class ClientAttackTree implements BehaviorTree {
|
||||
false
|
||||
),
|
||||
});
|
||||
this.stateTransitionUtil.setAccountForSync(true);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -424,44 +425,45 @@ public class ClientAttackTree implements BehaviorTree {
|
||||
return rVal;
|
||||
}
|
||||
|
||||
boolean canAttack(String attackType){
|
||||
boolean rVal = true;
|
||||
/**
|
||||
* Checks if the tree can perform the specified attack
|
||||
* @param attackType The attack type
|
||||
* @return true if can attack, false otherwise
|
||||
*/
|
||||
private boolean canAttack(String attackType){
|
||||
if(attackType == null){
|
||||
return false;
|
||||
} else if(state != AttackTreeState.IDLE){
|
||||
}
|
||||
if(state != AttackTreeState.IDLE){
|
||||
//checks if we have a next move and if we're in the specified range of frames when we're allowed to chain into it
|
||||
if(
|
||||
currentMove != null &&
|
||||
currentMove.getNextMoveId() != null &&
|
||||
!currentMove.getNextMoveId().equals("") &&
|
||||
frameCurrent >= currentMove.getMoveChainWindowStart() && frameCurrent <= currentMove.getMoveChainWindowEnd()
|
||||
currentMove == null ||
|
||||
currentMove.getNextMoveId() == null ||
|
||||
currentMove.getNextMoveId().equals("") ||
|
||||
frameCurrent < currentMove.getMoveChainWindowStart() ||
|
||||
frameCurrent > currentMove.getMoveChainWindowEnd()
|
||||
){
|
||||
rVal = true;
|
||||
}
|
||||
} else {
|
||||
if(ClientEquipState.hasEquipState(parent)){
|
||||
// ClientEquipState equipState = ClientEquipState.getEquipState(parent);
|
||||
// if(equipState.hasEquipPrimary()){
|
||||
// switch(attackType){
|
||||
// case EntityDataStrings.ATTACK_MOVE_TYPE_MELEE_SWING_ONE_HAND:
|
||||
// break;
|
||||
// default:
|
||||
// rVal = false;
|
||||
// break;
|
||||
// }
|
||||
// } else {
|
||||
// switch(attackType){
|
||||
// case EntityDataStrings.ATTACK_MOVE_TYPE_MELEE_SWING_ONE_HAND:
|
||||
// rVal = false;
|
||||
// break;
|
||||
// default:
|
||||
// rVal = false;
|
||||
// break;
|
||||
// }
|
||||
// }
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return rVal;
|
||||
if(state == AttackTreeState.IDLE){
|
||||
if(!ClientEquipState.hasEquipState(parent)){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if(ClientJumpTree.getClientJumpTree(parent) != null){
|
||||
ClientJumpTree clientJumpTree = ClientJumpTree.getClientJumpTree(parent);
|
||||
if(clientJumpTree.isJumping()){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if(FallTree.getFallTree(parent) != null){
|
||||
FallTree fallTree = FallTree.getFallTree(parent);
|
||||
if(fallTree.isFalling()){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -17,6 +17,8 @@ import electrosphere.entity.state.attack.ClientAttackTree.AttackTreeState;
|
||||
import electrosphere.entity.state.collidable.Impulse;
|
||||
import electrosphere.entity.state.equip.ServerEquipState;
|
||||
import electrosphere.entity.state.hitbox.HitboxCollectionState;
|
||||
import electrosphere.entity.state.movement.ServerFallTree;
|
||||
import electrosphere.entity.state.movement.jump.ServerJumpTree;
|
||||
import electrosphere.entity.state.rotator.ServerRotatorTree;
|
||||
import electrosphere.entity.types.attach.AttachUtils;
|
||||
import electrosphere.entity.types.collision.CollisionObjUtils;
|
||||
@ -469,47 +471,44 @@ public class ServerAttackTree implements BehaviorTree {
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks whether the entity can attack or not
|
||||
* @param attackType The type of attack to perform
|
||||
* @return true if it can attack, false otherwise
|
||||
* Checks if the tree can perform the specified attack
|
||||
* @param attackType The attack type
|
||||
* @return true if can attack, false otherwise
|
||||
*/
|
||||
private boolean canAttack(String attackType){
|
||||
boolean rVal = true;
|
||||
if(attackType == null){
|
||||
return false;
|
||||
} else if(state != AttackTreeState.IDLE){
|
||||
}
|
||||
if(state != AttackTreeState.IDLE){
|
||||
//checks if we have a next move and if we're in the specified range of frames when we're allowed to chain into it
|
||||
if(
|
||||
currentMove.getNextMoveId() != null &&
|
||||
!currentMove.getNextMoveId().equals("") &&
|
||||
frameCurrent >= currentMove.getMoveChainWindowStart() && frameCurrent <= currentMove.getMoveChainWindowEnd()
|
||||
currentMove == null ||
|
||||
currentMove.getNextMoveId() == null ||
|
||||
currentMove.getNextMoveId().equals("") ||
|
||||
frameCurrent < currentMove.getMoveChainWindowStart() ||
|
||||
frameCurrent > currentMove.getMoveChainWindowEnd()
|
||||
){
|
||||
rVal = true;
|
||||
}
|
||||
} else {
|
||||
if(ServerEquipState.hasEquipState(parent)){
|
||||
// ServerEquipState equipState = ServerEquipState.getEquipState(parent);
|
||||
// if(equipState.hasEquipPrimary()){
|
||||
// switch(attackType){
|
||||
// case EntityDataStrings.ATTACK_MOVE_TYPE_MELEE_SWING_ONE_HAND:
|
||||
// break;
|
||||
// default:
|
||||
// rVal = false;
|
||||
// break;
|
||||
// }
|
||||
// } else {
|
||||
// switch(attackType){
|
||||
// case EntityDataStrings.ATTACK_MOVE_TYPE_MELEE_SWING_ONE_HAND:
|
||||
// rVal = false;
|
||||
// break;
|
||||
// default:
|
||||
// rVal = false;
|
||||
// break;
|
||||
// }
|
||||
// }
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return rVal;
|
||||
if(state == AttackTreeState.IDLE){
|
||||
if(!ServerEquipState.hasEquipState(parent)){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if(ServerJumpTree.getServerJumpTree(parent) != null){
|
||||
ServerJumpTree serverJumpTree = ServerJumpTree.getServerJumpTree(parent);
|
||||
if(serverJumpTree.isJumping()){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if(ServerFallTree.getFallTree(parent) != null){
|
||||
ServerFallTree serverFallTree = ServerFallTree.getFallTree(parent);
|
||||
if(serverFallTree.isFalling()){
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -489,7 +489,7 @@ public class ImGuiEntityMacros {
|
||||
}
|
||||
}
|
||||
}
|
||||
if(Globals.clientSceneWrapper.getScene().getEntityFromId(detailViewEntity.getId()) != null){
|
||||
if(Globals.clientSceneWrapper.clientToServerMapContainsId(detailViewEntity.getId())){
|
||||
//detailViewEntity is a client entity
|
||||
//get server entity
|
||||
int serverIdForClientEntity = Globals.clientSceneWrapper.mapClientToServerId(detailViewEntity.getId());
|
||||
|
||||
Loading…
Reference in New Issue
Block a user