Misc fixes.

This commit is contained in:
genxium
2023-01-05 10:20:01 +08:00
parent 2d04363d69
commit e2191f9d13
15 changed files with 387 additions and 6758 deletions

File diff suppressed because one or more lines are too long

View File

@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<map version="1.2" tiledversion="1.2.3" orientation="orthogonal" renderorder="right-down" width="128" height="128" tilewidth="16" tileheight="16" infinite="0" nextlayerid="4" nextobjectid="104">
<map version="1.2" tiledversion="1.2.3" orientation="orthogonal" renderorder="right-down" width="128" height="128" tilewidth="16" tileheight="16" infinite="0" nextlayerid="4" nextobjectid="107">
<tileset firstgid="1" source="tiles0.tsx"/>
<tileset firstgid="65" source="tiles1.tsx"/>
<tileset firstgid="129" source="tiles2.tsx"/>
<layer id="2" name="Ground" width="128" height="128">
<data encoding="base64" compression="zlib">
eJzt3MFq1EAcwOFli5ceikUU9NyD4Et47qle9OapLyB60ZMgvoIH776nWUggxkySnZ1kksx3+KC0S2jn9082E5ZeHQ6HKwAAAAAAAAAAAAAAAAAAiHBdy/17sJzHlqb/Y4Fyd8jZ/1hr+n+s3Accd0j/f/uH6L8/7f73I/2vV9BK//n699F/305/+/Na39p0rwm5W+m/bP8S6K9/7g45+z+LkLuZ/nn772kG9Nc/d4ct9l8T/cvs7/wvu3+KGdB/u5z/+utfbv8UM6B/+rVtnin+uNDc577++uu/jf4va/qX07/du/21/vrrn6//0xEp+7fpn7f/WPe+/r8q78/U9Hf/t57+U9s/HNz/b8XU/lPbH/XflLH+fY3fVG4C7bv9ux7OpH++/n3tb1q63efo/6Jyp/9q+g9d99v9U9N/vf1j7hHPpf/y/afMQHctU/Ydk7L/cQUt1tg/1RoPiWmv/376nzMjcxxb/23MwFz0L3sG9Ne/5P651z+30vd/udc/N/3Lpn/Z9C+b/mXTv2z6l03/sulfNv3Lpn/Z9C+b/mXTv2z6l03/9boL0H8d/ef6nFCo+xxzoP96+t+OeBKg/z7656B/fG/9t23t93/6769/6L29+fm7hNrHDF2ffP573Ida93r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YufgZRPX//BZAJ8DrTtf9z62r9V/3v6x9v3fxPY/+NSE+3/pve7Q8ndL/+n9yd8BAAAAAAAAAAAAAAAAWN5f3AoF6w==
</data>
</layer>
<objectgroup id="1" name="PlayerStartingPos">
<object id="135" x="943" y="1605">
<object id="135" x="1040.33" y="1081">
<point/>
</object>
<object id="137" x="1000" y="1591">
<object id="137" x="1134.67" y="1081.67">
<point/>
</object>
</objectgroup>
@@ -200,5 +200,20 @@
<property name="boundary_type" value="barrier"/>
</properties>
</object>
<object id="104" x="928" y="1088" width="304" height="16">
<properties>
<property name="boundary_type" value="barrier"/>
</properties>
</object>
<object id="105" x="928" y="1008" width="16" height="96">
<properties>
<property name="boundary_type" value="barrier"/>
</properties>
</object>
<object id="106" x="1216" y="1008" width="16" height="96">
<properties>
<property name="boundary_type" value="barrier"/>
</properties>
</object>
</objectgroup>
</map>

View File

@@ -28,7 +28,6 @@ message PlayerDownsync {
int32 activeSkillId = 21;
int32 activeSkillHit = 22;
int32 framesInvinsible = 23;
int32 framesSelfLockVel = 24;
string name = 997;
string displayName = 998;
@@ -105,14 +104,13 @@ message MeleeBullet {
int32 selfLockVelX = 12;
int32 selfLockVelY = 13;
int32 framesSelfLockVel = 14;
int32 hitboxOffsetX = 15;
int32 hitboxOffsetY = 16;
int32 hitboxSizeX = 17;
int32 hitboxSizeY = 18;
int32 hitboxOffsetX = 14;
int32 hitboxOffsetY = 15;
int32 hitboxSizeX = 16;
int32 hitboxSizeY = 17;
bool blowUp = 19;
bool blowUp = 18;
}
message BattleColliderInfo {

View File

@@ -440,7 +440,7 @@
"array": [
0,
0,
216.79917701871616,
217.36724690689908,
0,
0,
0,

View File

@@ -461,7 +461,7 @@
"array": [
0,
0,
216.50635094610968,
217.36724690689908,
0,
0,
0,

View File

@@ -578,13 +578,13 @@ cc.Class({
const jsPlayersArr = new Array().fill(null);
for (let k in pbRdf.playersArr) {
const pbPlayer = pbRdf.playersArr[k];
const jsPlayer = gopkgs.NewPlayerDownsyncJs(pbPlayer.id, pbPlayer.virtualGridX, pbPlayer.virtualGridY, pbPlayer.dirX, pbPlayer.dirY, pbPlayer.velX, pbPlayer.velY, pbPlayer.framesToRecover, pbPlayer.framesInChState, pbPlayer.activeSkillId, pbPlayer.activeSkillHit, pbPlayer.framesInvinsible, pbPlayer.framesSelfLockVel, pbPlayer.speed, pbPlayer.battleState, pbPlayer.characterState, pbPlayer.joinIndex, pbPlayer.hp, pbPlayer.maxHp, pbPlayer.colliderRadius, pbPlayer.inAir);
const jsPlayer = gopkgs.NewPlayerDownsyncJs(pbPlayer.id, pbPlayer.virtualGridX, pbPlayer.virtualGridY, pbPlayer.dirX, pbPlayer.dirY, pbPlayer.velX, pbPlayer.velY, pbPlayer.framesToRecover, pbPlayer.framesInChState, pbPlayer.activeSkillId, pbPlayer.activeSkillHit, pbPlayer.framesInvinsible, pbPlayer.speed, pbPlayer.battleState, pbPlayer.characterState, pbPlayer.joinIndex, pbPlayer.hp, pbPlayer.maxHp, pbPlayer.colliderRadius, pbPlayer.inAir);
jsPlayersArr[k] = jsPlayer;
}
const jsMeleeBulletsArr = [];
for (let k in pbRdf.meleeBullets) {
const pbBullet = pbRdf.meleeBullets[k];
const jsBullet = gopkgs.NewMeleeBulletJs(pbBullet.originatedRenderFrameId, pbBullet.offenderJoinIndex, pbBullet.startupFrames, pbBullet.cancellableStFrame, pbBullet.cancellableEdFrame, pbBullet.activeFrames, pbBullet.hitStunFrames, pbBullet.blockStunFrames, pbBullet.pushbackVelX, pbBullet.pushbackVelY, pbBullet.damage, pbBullet.selfLockVelX, pbBullet.selfLockVelY, pbBullet.framesSelfLockVel, pbBullet.hitboxOffsetX, pbBullet.hitboxOffsetY, pbBullet.hitboxSizeX, pbBullet.hitboxSizeY, pbBullet.blowUp);
const jsBullet = gopkgs.NewMeleeBulletJs(pbBullet.originatedRenderFrameId, pbBullet.offenderJoinIndex, pbBullet.startupFrames, pbBullet.cancellableStFrame, pbBullet.cancellableEdFrame, pbBullet.activeFrames, pbBullet.hitStunFrames, pbBullet.blockStunFrames, pbBullet.pushbackVelX, pbBullet.pushbackVelY, pbBullet.damage, pbBullet.selfLockVelX, pbBullet.selfLockVelY, pbBullet.hitboxOffsetX, pbBullet.hitboxOffsetY, pbBullet.hitboxSizeX, pbBullet.hitboxSizeY, pbBullet.blowUp);
jsMeleeBulletsArr.push(jsBullet);
}
@@ -1082,6 +1082,14 @@ othersForcedDownsyncRenderFrame=${JSON.stringify(othersForcedDownsyncRenderFrame
}
const nextRdf = gopkgs.ApplyInputFrameDownsyncDynamicsOnSingleRenderFrameJs(self.recentInputCache, currRdf, collisionSys, collisionSysMap, self.spaceOffsetX, self.spaceOffsetY, self.chConfigsOrderedByJoinIndex);
if (3 == nextRdf.PlayersArr[0].ActiveSkillId && 3 != currRdf.PlayersArr[0].ActiveSkillId) {
console.log(`Started skill 3 at rdf.Id=${nextRdf.Id}`);
self.lastSkill3Started = nextRdf.Id;
}
if (3 != nextRdf.PlayersArr[0].ActiveSkillId && 3 == currRdf.PlayersArr[0].ActiveSkillId) {
console.log(`Stopped skill 3 at rdf.Id=${nextRdf.Id}, duration = ${nextRdf.Id-self.lastSkill3Started}`);
}
if (true == isChasing) {
// [WARNING] Move the cursor "self.chaserRenderFrameId" when "true == isChasing", keep in mind that "self.chaserRenderFrameId" is not monotonic!
self.chaserRenderFrameId = nextRdf.Id;

View File

@@ -13,7 +13,7 @@ cc.Class({
onLoad() {
const self = this;
window.mapIns = self;
self.showCriticalCoordinateLabels = true;
self.showCriticalCoordinateLabels = false;
const mapNode = self.node;
const canvasNode = mapNode.parent;
@@ -129,7 +129,7 @@ cc.Class({
inAir: true,
}),
],
speciesIdList: [0, 1],
speciesIdList: [1, 0],
});
self.selfPlayerInfo = {

View File

@@ -1214,7 +1214,6 @@ $root.protos = (function() {
* @property {number|null} [activeSkillId] PlayerDownsync activeSkillId
* @property {number|null} [activeSkillHit] PlayerDownsync activeSkillHit
* @property {number|null} [framesInvinsible] PlayerDownsync framesInvinsible
* @property {number|null} [framesSelfLockVel] PlayerDownsync framesSelfLockVel
* @property {string|null} [name] PlayerDownsync name
* @property {string|null} [displayName] PlayerDownsync displayName
* @property {string|null} [avatar] PlayerDownsync avatar
@@ -1419,14 +1418,6 @@ $root.protos = (function() {
*/
PlayerDownsync.prototype.framesInvinsible = 0;
/**
* PlayerDownsync framesSelfLockVel.
* @member {number} framesSelfLockVel
* @memberof protos.PlayerDownsync
* @instance
*/
PlayerDownsync.prototype.framesSelfLockVel = 0;
/**
* PlayerDownsync name.
* @member {string} name
@@ -1521,8 +1512,6 @@ $root.protos = (function() {
writer.uint32(/* id 22, wireType 0 =*/176).int32(message.activeSkillHit);
if (message.framesInvinsible != null && Object.hasOwnProperty.call(message, "framesInvinsible"))
writer.uint32(/* id 23, wireType 0 =*/184).int32(message.framesInvinsible);
if (message.framesSelfLockVel != null && Object.hasOwnProperty.call(message, "framesSelfLockVel"))
writer.uint32(/* id 24, wireType 0 =*/192).int32(message.framesSelfLockVel);
if (message.name != null && Object.hasOwnProperty.call(message, "name"))
writer.uint32(/* id 997, wireType 2 =*/7978).string(message.name);
if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName"))
@@ -1655,10 +1644,6 @@ $root.protos = (function() {
message.framesInvinsible = reader.int32();
break;
}
case 24: {
message.framesSelfLockVel = reader.int32();
break;
}
case 997: {
message.name = reader.string();
break;
@@ -1775,9 +1760,6 @@ $root.protos = (function() {
if (message.framesInvinsible != null && message.hasOwnProperty("framesInvinsible"))
if (!$util.isInteger(message.framesInvinsible))
return "framesInvinsible: integer expected";
if (message.framesSelfLockVel != null && message.hasOwnProperty("framesSelfLockVel"))
if (!$util.isInteger(message.framesSelfLockVel))
return "framesSelfLockVel: integer expected";
if (message.name != null && message.hasOwnProperty("name"))
if (!$util.isString(message.name))
return "name: string expected";
@@ -1848,8 +1830,6 @@ $root.protos = (function() {
message.activeSkillHit = object.activeSkillHit | 0;
if (object.framesInvinsible != null)
message.framesInvinsible = object.framesInvinsible | 0;
if (object.framesSelfLockVel != null)
message.framesSelfLockVel = object.framesSelfLockVel | 0;
if (object.name != null)
message.name = String(object.name);
if (object.displayName != null)
@@ -1896,7 +1876,6 @@ $root.protos = (function() {
object.activeSkillId = 0;
object.activeSkillHit = 0;
object.framesInvinsible = 0;
object.framesSelfLockVel = 0;
object.name = "";
object.displayName = "";
object.avatar = "";
@@ -1947,8 +1926,6 @@ $root.protos = (function() {
object.activeSkillHit = message.activeSkillHit;
if (message.framesInvinsible != null && message.hasOwnProperty("framesInvinsible"))
object.framesInvinsible = message.framesInvinsible;
if (message.framesSelfLockVel != null && message.hasOwnProperty("framesSelfLockVel"))
object.framesSelfLockVel = message.framesSelfLockVel;
if (message.name != null && message.hasOwnProperty("name"))
object.name = message.name;
if (message.displayName != null && message.hasOwnProperty("displayName"))
@@ -4088,7 +4065,6 @@ $root.protos = (function() {
* @property {number|null} [damage] MeleeBullet damage
* @property {number|null} [selfLockVelX] MeleeBullet selfLockVelX
* @property {number|null} [selfLockVelY] MeleeBullet selfLockVelY
* @property {number|null} [framesSelfLockVel] MeleeBullet framesSelfLockVel
* @property {number|null} [hitboxOffsetX] MeleeBullet hitboxOffsetX
* @property {number|null} [hitboxOffsetY] MeleeBullet hitboxOffsetY
* @property {number|null} [hitboxSizeX] MeleeBullet hitboxSizeX
@@ -4215,14 +4191,6 @@ $root.protos = (function() {
*/
MeleeBullet.prototype.selfLockVelY = 0;
/**
* MeleeBullet framesSelfLockVel.
* @member {number} framesSelfLockVel
* @memberof protos.MeleeBullet
* @instance
*/
MeleeBullet.prototype.framesSelfLockVel = 0;
/**
* MeleeBullet hitboxOffsetX.
* @member {number} hitboxOffsetX
@@ -4313,18 +4281,16 @@ $root.protos = (function() {
writer.uint32(/* id 12, wireType 0 =*/96).int32(message.selfLockVelX);
if (message.selfLockVelY != null && Object.hasOwnProperty.call(message, "selfLockVelY"))
writer.uint32(/* id 13, wireType 0 =*/104).int32(message.selfLockVelY);
if (message.framesSelfLockVel != null && Object.hasOwnProperty.call(message, "framesSelfLockVel"))
writer.uint32(/* id 14, wireType 0 =*/112).int32(message.framesSelfLockVel);
if (message.hitboxOffsetX != null && Object.hasOwnProperty.call(message, "hitboxOffsetX"))
writer.uint32(/* id 15, wireType 0 =*/120).int32(message.hitboxOffsetX);
writer.uint32(/* id 14, wireType 0 =*/112).int32(message.hitboxOffsetX);
if (message.hitboxOffsetY != null && Object.hasOwnProperty.call(message, "hitboxOffsetY"))
writer.uint32(/* id 16, wireType 0 =*/128).int32(message.hitboxOffsetY);
writer.uint32(/* id 15, wireType 0 =*/120).int32(message.hitboxOffsetY);
if (message.hitboxSizeX != null && Object.hasOwnProperty.call(message, "hitboxSizeX"))
writer.uint32(/* id 17, wireType 0 =*/136).int32(message.hitboxSizeX);
writer.uint32(/* id 16, wireType 0 =*/128).int32(message.hitboxSizeX);
if (message.hitboxSizeY != null && Object.hasOwnProperty.call(message, "hitboxSizeY"))
writer.uint32(/* id 18, wireType 0 =*/144).int32(message.hitboxSizeY);
writer.uint32(/* id 17, wireType 0 =*/136).int32(message.hitboxSizeY);
if (message.blowUp != null && Object.hasOwnProperty.call(message, "blowUp"))
writer.uint32(/* id 19, wireType 0 =*/152).bool(message.blowUp);
writer.uint32(/* id 18, wireType 0 =*/144).bool(message.blowUp);
return writer;
};
@@ -4412,26 +4378,22 @@ $root.protos = (function() {
break;
}
case 14: {
message.framesSelfLockVel = reader.int32();
break;
}
case 15: {
message.hitboxOffsetX = reader.int32();
break;
}
case 16: {
case 15: {
message.hitboxOffsetY = reader.int32();
break;
}
case 17: {
case 16: {
message.hitboxSizeX = reader.int32();
break;
}
case 18: {
case 17: {
message.hitboxSizeY = reader.int32();
break;
}
case 19: {
case 18: {
message.blowUp = reader.bool();
break;
}
@@ -4509,9 +4471,6 @@ $root.protos = (function() {
if (message.selfLockVelY != null && message.hasOwnProperty("selfLockVelY"))
if (!$util.isInteger(message.selfLockVelY))
return "selfLockVelY: integer expected";
if (message.framesSelfLockVel != null && message.hasOwnProperty("framesSelfLockVel"))
if (!$util.isInteger(message.framesSelfLockVel))
return "framesSelfLockVel: integer expected";
if (message.hitboxOffsetX != null && message.hasOwnProperty("hitboxOffsetX"))
if (!$util.isInteger(message.hitboxOffsetX))
return "hitboxOffsetX: integer expected";
@@ -4568,8 +4527,6 @@ $root.protos = (function() {
message.selfLockVelX = object.selfLockVelX | 0;
if (object.selfLockVelY != null)
message.selfLockVelY = object.selfLockVelY | 0;
if (object.framesSelfLockVel != null)
message.framesSelfLockVel = object.framesSelfLockVel | 0;
if (object.hitboxOffsetX != null)
message.hitboxOffsetX = object.hitboxOffsetX | 0;
if (object.hitboxOffsetY != null)
@@ -4610,7 +4567,6 @@ $root.protos = (function() {
object.damage = 0;
object.selfLockVelX = 0;
object.selfLockVelY = 0;
object.framesSelfLockVel = 0;
object.hitboxOffsetX = 0;
object.hitboxOffsetY = 0;
object.hitboxSizeX = 0;
@@ -4643,8 +4599,6 @@ $root.protos = (function() {
object.selfLockVelX = message.selfLockVelX;
if (message.selfLockVelY != null && message.hasOwnProperty("selfLockVelY"))
object.selfLockVelY = message.selfLockVelY;
if (message.framesSelfLockVel != null && message.hasOwnProperty("framesSelfLockVel"))
object.framesSelfLockVel = message.framesSelfLockVel;
if (message.hitboxOffsetX != null && message.hasOwnProperty("hitboxOffsetX"))
object.hitboxOffsetX = message.hitboxOffsetX;
if (message.hitboxOffsetY != null && message.hasOwnProperty("hitboxOffsetY"))