Code Monkey home page Code Monkey logo

thpages's Issues

Which (sprite-based) render types support gradients?

Dai asked a question on Discord about color modes 2 and 3 not working in STD. They had this ANM script:

type(8);
sprite(spr_fire0);
blendMode(1);
scrollY(0.001f);
rotate(rad(90f), 0.0f, 0.0f);
colorMode(3);
alpha(224);
alpha2(0);
stop();

(and they also tried with color/color2)

I took a quick peek at DDC in binary ninja and..... it seems very well possible that mode 8 does not, in fact, support gradients.

Did I never test this? Some day I should take proper notes on which sprite-based render types actually do support gradients. (and this includes the modes for texCircle and friends)

Dai did a test on the 3D render types in WBaWC:

  • 8 and 15: no gradients. (said they both look identical)
  • "also 5 fills the entire screen with the sprite and supports gradients, and 7 does the same thing but without gradients. 7 also blends with background fog" (these probably aren't meant to be used in 3D but just happen to be visible)
  • 4 and 6 billboarding DOES support gradient.

info from zero on IN stage 6 select MSG stuff

text_top_line and text_bottom_line (19/20) merely set the top/bottom lines of text and don't have any selection box specific code. They could totally be used for dialogue.

selection_box (21) triggers the selection box menu and writes your choice to a field in the MsgVM

msg_read_selected (22) copies the choice field from the MsgVM to a bitfield in the game manager and then uses it as an index to start a different msg script.
Since that game manager bitfield isn't read anywhere else unless you're ending stage 5, the selection box could totally be used elsewhere to have arbitrary interactive dialogue.
Also, that bitfield is actually two bits for some reason. It only writes a 0 or 1 to it though, since there're two choices.

React adoption checklist

Here I keep a list of things I need to come back to during the React refactor.

  • Make tips work again.
  • Use refractor to highlight
  • Replace globalNames with React state.
  • Completely exorcise data-name, data-link, NameResolver and LinkResolver.
  • Think about data-tip. Maybe we still need this?
  • Convert markdown extensions to components
  • Do we need to be more careful with reading window.location.hash?
  • delete postprocessConvertedMarkdown
  • Fix the copypasta at the bottom of the various tables.js
  • table-footnotes
  • look at remark-footnotes who cares
  • fix all tipshow/tiphide
  • render links
  • change all anchored headings to use {#id}
  • make sure there's no automatic header ids (probably an option somewhere)
  • why does the ins table have borders
  • Disabling of nested tooltips inside tooltip bodies needs to be reimplemented as a remark plugin (part of the :::is-tip logic)
  • fix highlighting of current page in navbar again
  • perform a check at runtime for any bad directives
    // find a custom element beginning with "exp-"
    let result = document.evaluate( "//*[starts-with(name(),'exp-')]", document, null, XPathResult.ANY_TYPE, null ).iterateNext();
    
  • change preventOverzealousTextDirectives into a plugin that operates only on text nodes changed the syntax to :ref{r=...} instead
  • how to reset scroll on new page?
  • scrolling to anchor
  • <div class="gear">
  • stats
  • layer viewer
  • couldn't parse ref :ref{r=anm:resampleMode tip=0}
  • 404 on bad page
  • "See the table entry for more details" was lost from tips

Things from the second rewrite:

  • Update the other tables besides STD
  • toolips are weirdly positioned due to async content...
  • settings page
  • markdown pages
  • truth maps
  • redirect to new HashRouter urls
  • fix old links in MD not using HashRouter urls
  • "Show more" has the wrong cursor again
  • HTML in MD not working

Things to double check at the end:

  • Check appearance of everything:
    • headless-table
    • table-footnotes
    • title
    • c
    • ref in inline-code: see resampleMode
    • tip with newlines in body: see furiTip
    • stats table
    • 404 on bad page
    • more...
    • embedded video
  • scroll positions:
    • follow link to instruction
    • follow link to instruction, hit back button (should go back to original scroll) (this was already broken)
    • with an anchor in the current url, scroll away from anchor, go to another page and hit back (should not return to anchor) (this was already broken)
    • with an anchor in current url, scroll away from anchor, and hit refresh (should not return to anchor) (this was already broken)
    • scroll down, navigate to other page: should reset scroll to top
    • follow a link to an instruction in the same table but another game (e.g. randMode)

More semantic HTML

  • Use nav
  • Use figure and figcaption (I've long intended to do this...)
  • Use main
  • Microdata for instruction tables would be cool but I don't think it'd be useful without server-side rendering? Bleh.

struct viewer tracking list

  • Expanding
    • Indent offsets with expanded fields
    • Expand arrays
    • Expand things behind pointers
    • Save expanded set per struct name
    • Easy way to collapse all
  • Filters
    • Filtered name/version combos should still be allowed in the autocompletes as long as they are valid. (i.e. you should be able to follow a link to a struct that is currently filtered out)
  • Reduce amount of loading
    • Keep DB around while navigating

Tests

  • number of lines of text in OVERLAPPED
  • Expanding typedef
  • Enter key should work in Autocomplete

Issues with current database:

  • Duplication of Direct3D types (should make a type library)
  • Bug with types like DWORD having 0 size in some common modules
  • Some types have bad size for alignment

info from zero on UM ANM

Zero posted this on discord about ANM in UM

ins_432 anm_flag_slowdown_immune(bool enable)
Forces gamespeed to 1.0 while this script is executing.

ins_433 __move_velocity_interp(int t, int mode, float angle, float magnitude)
Name is just speculation based on similarities to ECL instructions. Though considering that this calls one of the many duplicate FSINCOS functions, I'm unsure how this ever looked like a 2D posTime. :P

ins_507
This flag apparently controls more behaviors than just parent/child jank. Right at the start of the parser it enables some sort of gamespeed/slowdown thing, which doesn't rely on a parent being present.

ins_615
Uh... it exists? It's definitely yet another rectangle variant. No idea what it does though.

STD ins_14 in UFO through TD is wrong (probably)

According to my website, ins_14 in STD gains a third argument in UFO, which holds the layer.

STD_BY_OPCODE.set('12', {
  ...STD_BY_OPCODE.get('11'),
  14: {ref: 'std:sprite-3arg'}, // signature change!
  18: {ref: 'std:up-time'},
});

Yet, trustd's core mapfiles have been decompiling this using a signature of SS without issue:

$ for x in ~/thcrap/decomp/bleh12/*.std; do TRUTH_MAP_PATH= target/release/trustd d --game 12 $x | grep ins_14; done
warning: /home/exp/thcrap/decomp/bleh12/stage02.std: object at index 2: object has non-sequential id (expected 2, got 1)

    ins_14(0, 4);
    ins_14(1, 5);
    ins_14(2, 6);
    ins_14(3, 7);
warning: /home/exp/thcrap/decomp/bleh12/stage07.std: object at index 2: object has non-sequential id (expected 2, got 1)

truth would warn if there were leftover bytes in the instruction, so clearly SS is correct. Where did SSS come from? Is this what it changes to in th14 maybe?

"YOU ARE HERE" isn't showing

image

You're not supposed to be able to see a detailed tip for something inside its own entry because it's confusing if you forget which entry you're in.

This is the whole entire purpose of CurrentReferenceTableRowContext, and I believe it was working fine when Material UI Tooltips were used. Probably the issue is that Material UI rendered its tooltips somehow inside the context of the element with the tip, but now we have that element placed inside a <Popper> that lives outside of everything else.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.