Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test #18

Closed
wants to merge 2 commits into from
Closed

test #18

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions categories/14707.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
parentID=14707
numObjects=3
14705
14706
14703
49 changes: 49 additions & 0 deletions objects/14707.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
id=14707
@ Testing
containable=0
containSize=1.000000,vertSlotRot=0.000000
permanent=0,minPickupAge=3
noFlip=0
sideAccess=0
heldInHand=0
blocksWalking=0,leftBlockingRadius=0,rightBlockingRadius=0,drawBehindPlayer=0
mapChance=0.000000#biomes_0
heatValue=0
rValue=0.000000
person=0,noSpawn=0
male=0
deathMarker=0
homeMarker=0
floor=0
floorHugging=0
foodValue=0
speedMult=1.000000
heldOffset=0.000000,0.000000
clothing=n
clothingOffset=0.000000,0.000000
deadlyDistance=0
useDistance=1
sounds=-1:0.0,-1:0.0,-1:0.0,-1:0.0
creationSoundInitialOnly=0
creationSoundForce=0
numSlots=0#timeStretch=1.000000
slotSize=1.000000
slotsLocked=0
numSprites=1
spriteID=711
pos=0.000000,0.000000
rot=0.000000
hFlip=0
color=1.000000,1.000000,1.000000
ageRange=-1.000000,-1.000000
parent=-1
invisHolding=0,invisWorn=0,behindSlots=0
invisCont=0
headIndex=-1
bodyIndex=-1
backFootIndex=-1
frontFootIndex=-1
numUses=0,0.000000
useVanishIndex=-1
useAppearIndex=-1
pixHeight=25
2 changes: 1 addition & 1 deletion objects/nextObjectNumber.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
14707
14708
29 changes: 16 additions & 13 deletions readableAssets.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,23 +169,26 @@ def read_category_as_object_list(content):
if inAction:

if 'categories/' in changed_file:
category_before_output = run_command(f"git show {COMMIT_A}:{changed_file}")
category_after_output = run_command(f"git show {COMMIT_B}:{changed_file}")

if category_before_output != "" and category_after_output != "":
category_before, category_after = [], []

if changed_file not in changes_added:
category_before_output = run_command(f"git show {COMMIT_A}:{changed_file}")
category_before = read_category_as_object_list(category_before_output)
if changed_file not in changes_deleted:
category_after_output = run_command(f"git show {COMMIT_B}:{changed_file}")
category_after = read_category_as_object_list(category_after_output)

added = list(set(category_after) - set(category_before))
removed = list(set(category_before) - set(category_after))
category_details = ""
if len(added) > 0:
category_details += "\n".join( [ f"+ {e} {get_object_name_by_id(e)}" for e in added] )
if len(removed) > 0:
category_details += "\n".join( [ f"- {e} {get_object_name_by_id(e)}" for e in removed] )
line = f"""
added = list(set(category_after) - set(category_before))
removed = list(set(category_before) - set(category_after))

category_details = ""
if len(added) > 0:
category_details += "\n".join( [ f"+ {e} {get_object_name_by_id(e)}" for e in added] )
if len(removed) > 0:
category_details += "\n".join( [ f"- {e} {get_object_name_by_id(e)}" for e in removed] )

line = f"""
{sign} [{object_id}](https://github.com/{REPO}/pull/{PR_NUM}/files#diff-{file_hash}) {object_name}
<details>
<summary>Details</summary>
Expand Down