Jump to content

VenrobMisc.zh [2.55]

Overview
Creator: venrob Updated: 22 Jul 2019 Tags: 2.55, Library, Misc Downloads: 10
Rating[?]: No rating
Download Script
(5.42 KB)
Information

Description Setup Reviews Comments

Functions:

V1.0 (24-May-2019):
RunNPCScript (and variants) - spawns an NPC, and sets it to have a given script/args (ala RunFFCScript style)
Direction manipulations - get only the vertical/horizontal component, or spin in increments of 45°
CanWalkM - A variation of CanWalk, that uses a mapdata pointer. This can handle solidity checks for any arbitrary screen, not just the current one.
CurMapData() - returns a mapdata pointer to the current screen
MooshDrawTile() - Credit Moosh - better rotated drawing

V1.1 (23-Jun-2019):
Inverse versions of VectorX/VectorY, which take an angle and a change in x/y, and give you the diagonal length (instead of taking the angle and length to give the change in x/y)
Triangle-Rectangle, Triangle-Point, and Line-Rectangle collision functions.
`ffcSolid(ffc f)`, a function which fakes FFC Solidity
Scroll checking functions, which can be used to check if the player is about to start scrolling, and if scrolling in a particular direction works
My own versions of InFrontX and InFrontY, which work better
`haltFFC`, which removes all movement from an ffc (i.e. it removes the Vx/Vy/Ax/Ay)

V1.2 (03-Jul-2019)
Renamed `InFrontX` and `InFrontY` to `InFrontCenteredX` and `InFrontCenteredY`, to remove std.zh conflict when `using namespace Venrob;`, and to better describe what they do.

V1.3 (22-Jul-2019)
Modified the `CanWalkM` functions; removed some unneeded overloads, and added a full extra set `CanWalkMFull` for full collision (instead of just "ahead of you" collision)
Added `DrawStrings()` and `DrawStringsBitmap()`, which function as `Screen->DrawString()` and `bitmap->DrawString()` respectively, except that they can draw multiple lines, constrained to a specific width (similar to Tango textboxes, but, without needing Tango)
(The drawstrings functions require ZC 2.55 A28+)