CodeBase - PickObject() function for DBC

Return to the CodeBase listing

Category: Miscellaneous

Version: 1.0

0
0

Information

Uploaded: 27th Jan 2006 11:06

Modified: 1st Jan 1970 01:00

Author:  Relativity

Summary

This function uses Sparky's .DLL to pick an object from a 2D point, such as the mouse position.

Full Description

This program will allow the user to see if a vector extending from a 2D point on the screen into 3D space will pass through an object. It incorporates Sparky's .DLL with my PickScreen() function.<br /> <br /> Sparky's .DLL has been uploaded; check the bottom of the Code page to download it.<br /> <br /> Syntax: PickObject(XPoint,YPoint,Distance#)<br /> XPoint - 2D X-Coordinate on the screen<br /> YPoint - 2D Y-Coordinate on the screen<br /> Distance# - Maximum distance to check for objects<br /> <br /> IMPORTANT:<br /> -This code requires Sparky's .DLL to run.<br /> -Enhanced version of DarkBASIC is required to run this function<br /> <br /> WARNING:<br /> -The Box Collision in Sparky's .DLL is bugged; do not use it unless the object you are using it on will never be behind another object when using this function<br /> <br /> INSTRUCTIONS:<br /> -Declare all objects you want to be detected by the function as Sparky's .DLL requires (see the Command List)<br /> -Whenever an object is moved or rotated use Sparky's updateObjectDBC() function<br /> -Make sure you paste all the function required for Sparky's .DLL to the bottom of your program.<br /> <br /> The PickObject() function is the first of the functions listed. Sparky's .DLL has been uploaded; check the bottom of the Code page to download it.

Comments

No comments yet.