I've just finished the first version of my new collision plugin called IAC (Image All Collision
) and it doesn't cost anything except a place in the credits
It's a source file which you can include in your project to use the player movement and collision functions and not have to do any work for yourself
Function List:
SetUpFreeWorld(Filename$,Transparent,TransparentValue)
Filename$ - the file you want to open as your world
Transparent - 0=No Transparency, 1=Yes Transparency
TransparentValue - Integer, 1-4. Same as
SET OBJECT TRANSPARENCY
SetUpFreePlayerObject(Load,Filename$,Primative$,Size#,XPos#,YPos#,ZPos#)
Load - 0=Don't load anything, 1=Yes load something
Filename$ - If you're loading something, this is the file
Primative$ - if you're not loading something, this is the object you make
Size# - This is the size of the primative
XPos# - Define the new Player object's X coord
YPos# - Define the new Player object's Y coord
ZPos# - Define the new Player object's Z coord
ControlPlayerObject(PlayerObject,Forward,Backward,Left,Right,Speed#,TurnLeft,TurnRight,Mouse)
PlayerObject - Object number of the player
Forward - Scancode of the key you press to move player forward
Backward - Another movement control key scancode
Left - Scancode of key pressed to strafe left
Right - Scancode of key pressed to strafe right
Speed# - How fast the player moves
TurnLeft - Scancode of key to turn left
TurnRight - Scancode of key to turn right
Mouse - 0=Just use the keys, 1=Use the mouse to turn instead
ControlPlayerCamera(Camera,Forward,Backward,Left,Right,Speed#,TurnLeft,TurnRight,Mouse)
Camera - Camera number of the player
Forward - Forward key scancode
Backward - Backward key scancode
Left - Strafe Left key scancode
Right - Strafe Right key scancode
Speed# - Overall speed of the player
TurnLeft - Left Turn key scancode
TurnRight - Right Turn key scancode
Mouse - 0=Use the keyboard, 1=Use the mouse to turn
PlayerObjectCollision(Camera,Player,World,PlayerHeight#,CameraHeight#,CameraDistance#,CameraSmoothRadius,CollisionRadius#,Gravity#,Sink#)
Camera - Camera number of camera folowing Player
Player - Object number of Player
World - Object number of World
PlayerHeight# - Distance between Player's Y Coord and the ground
CameraHeight# - Distance between Camera's Y Coord and that of Player
CameraDistance# - Distance the Camera should stay away from Player
CameraSmoothRadius - How smoothly the camera folows Player
CollisionRadius# - How far away walls can get to Player and Camera
Gravity# - Speed that Player should fall
Sink# - If your player object is floating above the ground, this is how much to push it back down
PlayerCameraCollision(Camera,World,CameraHeight#,CollisionRadius#,Gravity#)
Camera - Camera number of Player
World - Object number of World
CameraHeight# - How high the camera is off the ground
CollisionRadius# - How close walls can get to the camera
Gravity# - How fast the Camera should fall
The end!
FunkyStickmen: Battle of the Races (1%)