Skip to content

Commit

Permalink
Merge branch 'main' into mobile
Browse files Browse the repository at this point in the history
  • Loading branch information
mcagabe19 committed Dec 22, 2024
2 parents d906260 + a9c95bc commit 879600f
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 45 deletions.
30 changes: 0 additions & 30 deletions .github/workflows/label-issue.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,36 +7,6 @@ on:
- edited

jobs:
# When an issue is opened, perform a similarity check for potential duplicates.
# If some are found, add a label and comment listing the potential duplicate issues.
potential-duplicate:
name: Detect potential duplicate issues
runs-on: ubuntu-latest
steps:
- uses: wow-actions/potential-duplicates@v1
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Issue title filter work with anymatch https://www.npmjs.com/package/anymatch.
# Any matched issue will stop detection immediately.
# You can specify multi filters in each line.
filter: ''
# Exclude keywords in title before detecting.
exclude: ''
# Label to set, when potential duplicates are detected.
label: 'potential duplicate'
# Get issues with state to compare. Supported state: 'all', 'closed', 'open'.
state: all
# If similarity is higher than this threshold([0,1]), issue will be marked as duplicate.
# Turn this up if the detection is too sensitive
threshold: 0.6
# Reactions to be add to comment when potential duplicates are detected.
# Available reactions: "-1", "+1", "confused", "laugh", "heart", "hooray", "rocket", "eyes"
# reactions: '-1'
# Comment to post when potential duplicates are detected.
comment: >
Potential duplicates: {{#issues}}
- [#{{ number }}] {{ title }} ({{ accuracy }}%)
{{/issues}}
# When an issue is opened, detect if it has an empty body or incomplete issue form.
# If it does, close the issue immediately.
empty-issues:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ THIS NOT THE JS ENGINE BASE REPO. THIS BRANCH MADE BY [mcagabe19](https://github
<br>
<b>JS Engine Mobile</b>
<br>
<i>(JordanSantiago engine)</i>
<i>(Jordan Santiago Engine)</i>
<br>
</h1>

Expand Down
29 changes: 15 additions & 14 deletions source/editors/CharacterEditorState.hx
Original file line number Diff line number Diff line change
Expand Up @@ -115,11 +115,9 @@ class CharacterEditorState extends MusicBeatState
ghostLayer = new FlxTypedGroup<FlxSprite>();
add(ghostLayer);

var pointer:FlxGraphic = FlxGraphic.fromClass(GraphicCursorCross);
cameraFollowPointer = new FlxSprite().loadGraphic(pointer);
cameraFollowPointer = new FlxSprite().loadGraphic(FlxGraphic.fromClass(GraphicCursorCross));
cameraFollowPointer.setGraphicSize(40, 40);
cameraFollowPointer.updateHitbox();
cameraFollowPointer.color = FlxColor.WHITE;
add(cameraFollowPointer);

changeBGbutton = new FlxButton(FlxG.width - 360, 25, "", function()
Expand Down Expand Up @@ -1200,18 +1198,21 @@ class CharacterEditorState extends MusicBeatState
}

function updatePointerPos() {
var x:Float = char.getMidpoint().x;
var y:Float = char.getMidpoint().y;
if(!char.isPlayer) {
x += 150 + char.cameraPosition[0];
} else {
x -= 100 + char.cameraPosition[0];
}
y -= 100 - char.cameraPosition[1];
if(char == null || cameraFollowPointer == null) return;

x -= cameraFollowPointer.width / 2;
y -= cameraFollowPointer.height / 2;
cameraFollowPointer.setPosition(x, y);
var offX:Float = 0;
var offY:Float = 0;
if(!char.isPlayer)
{
offX = char.getMidpoint().x + 150 + char.cameraPosition[0];
offY = char.getMidpoint().y - 100 + char.cameraPosition[1];
}
else
{
offX = char.getMidpoint().x - 100 - char.cameraPosition[0];
offY = char.getMidpoint().y - 100 + char.cameraPosition[1];
}
cameraFollowPointer.setPosition(offX, offY);
}

function findAnimationByName(name:String):AnimArray {
Expand Down

0 comments on commit 879600f

Please sign in to comment.