DebateFort - Where Warriors Come To Debate
RAGECRY - Funny, Amusing, Interesting, Trending & Viral Videos and Images
GameOrc - Free Flash Games Online
Results 1 to 4 of 4
  1. #1
    Expert Member
    MPGH Member
    u.A.v.A's Avatar
    Join Date
    Feb 2012
    Gender
    male
    Posts
    563
    Reputation
    17
    Thanks
    268

    What is World To Screen?

    I am new at hacking so please explain to me what is WorldToScreen?


    Thank you
    Quote Originally Posted by Prepix View Post


    You went full retart
    Quote Originally Posted by lindi000 View Post
    You went full retard there.
    Quote Originally Posted by Raytiger3 View Post
    A 13 year old went full retard on me.

    Quote Originally Posted by FluxieFlux View Post



    Never go full retard man.
    Never go full retard.

  2. #2
    MPGH Expert
    MPGH Member
    258456's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    ghjghj
    Posts
    1,202
    Reputation
    18
    Thanks
    293
    My Mood
    Relaxed
    It is a function where it takes three dimensional coordinates and makes them two dimensional coordinates so u can work with them easier.

    For example, this is how name esp is made. You get the two dimensional coordinates of the players body position and then u just add some to the y coordinate to position their name above their head, or below if that floats ur boat
    Last edited by 258456; 05-24-2012 at 09:30 PM.

  3. The Following User Says Thank You to 258456 For This Useful Post:

    u.A.v.A (05-25-2012)

  4. #3
    MPGH Addict
    Former Staff
    Hell_Demon's Avatar
    Join Date
    Mar 2008
    Gender
    male
    Location
    I love causing havoc
    Posts
    3,590
    Reputation
    236
    Thanks
    3,784
    My Mood
    Cheeky
    Gameworlds are a 3 dimensional space, You can move up/down, left/right and forward/backwards. Your screen however is 2 dimensional, you can only go left/right and up/down.

    World to Screen basically allows you to calculate the screen coordinates for a given world coordinate using some advanced maths.
    Typically you'll need the following:
    * Camera position
    * Camera rotation
    * Camera field of view(fov)
    * Screen resolution
    * A point in the world that you want to know the screen coordinates of.

    If you have all of those you can calculate the screen position with some fancy maths. There's different approaches, the only one I've worked with is roughly the following:
    Calculate the angles to aim at the point you want to convert.
    is within our field of view(thus the difference is between -0.5*fov and 0.5*fov)?
    If not: it's not on our screen
    If it is: do the following(hard to explain in only words so here's a little drawing)


    So, lets say we've done the maths(you should be able to figure out what to do based on the information below)
    We've found that the length of the plane is 100 units(from -50 to 50 to make it easier to follow), and our enemy is at -20.
    Our screen is 1920 in width.
    Now we can calculate that every full unit is 1920/100 = 19.2 pixels.
    We'll work from the middle of our screen, -20 * 19.2 + 960 = 576, so our enemy is at X = 576 on our screen.

    The same stuff applies to the height on the screen, except you won't use 90 as FOV. you'll have to divide it by your aspect ratio to get the horizontal fov.
    Ah we-a blaze the fyah, make it bun dem!

  5. The Following 2 Users Say Thank You to Hell_Demon For This Useful Post:

    intervention61 (06-28-2012), u.A.v.A (05-25-2012)

  6. #4
    Threadstarter
    Expert Member
    MPGH Member
    u.A.v.A's Avatar
    Join Date
    Feb 2012
    Gender
    male
    Posts
    563
    Reputation
    17
    Thanks
    268
    I just figure it out yesterday but @Hell_Demon thanks for the extra information
    Quote Originally Posted by Prepix View Post


    You went full retart
    Quote Originally Posted by lindi000 View Post
    You went full retard there.
    Quote Originally Posted by Raytiger3 View Post
    A 13 year old went full retard on me.

    Quote Originally Posted by FluxieFlux View Post



    Never go full retard man.
    Never go full retard.

Similar Threads

  1. This is what the world is coming to..
    By Donnuh in forum General
    Replies: 15
    Last Post: 04-10-2012, 09:58 PM
  2. What is the best screen recorder!
    By ii bandos ii in forum Suggestions, Requests & Help
    Replies: 3
    Last Post: 11-16-2011, 11:22 AM
  3. [Help Request] What is the best screen recorder
    By MIRV in forum Alliance of Valiant Arms (AVA) Help
    Replies: 4
    Last Post: 09-30-2011, 11:47 AM
  4. World 2 Screen?
    By Xlilzoosk8rX in forum Combat Arms Coding Help & Discussion
    Replies: 30
    Last Post: 10-01-2010, 12:06 PM
  5. ~what is the best screen recorder~
    By ~Tabuzo013~ in forum CrossFire Help
    Replies: 4
    Last Post: 05-08-2010, 03:44 AM