Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 10-09-2005, 12:14 AM
raiden0899 raiden0899 is offline
Registered User
raiden0899's Avatar
Join Date: Oct 2004
Posts: 192
raiden0899 is on a distinguished road
Question worldx(x,y) and worldy(x,y) ?

Can someone please explain what worldx(x,y) and worldy(x,y) do and how they are used?

EDIT:
Thanks Velox Cruentus, I get it now.

Last edited by raiden0899; 10-09-2005 at 03:35 AM..
Reply With Quote
  #2  
Old 10-09-2005, 12:21 AM
ChibiChibiLuc ChibiChibiLuc is offline
Cookie Monster. :3
Join Date: Jan 2005
Location: Nova Scotia, Canada
Posts: 111
ChibiChibiLuc is on a distinguished road
Send a message via AIM to ChibiChibiLuc Send a message via MSN to ChibiChibiLuc
It converts screen coordinates to level coordinates.
Like screenx(x,y) and screeny(x,y), but opposite.
Reply With Quote
  #3  
Old 10-09-2005, 01:14 AM
Velox Cruentus Velox Cruentus is offline
Registered User
Velox Cruentus's Avatar
Join Date: Dec 2004
Location: Quebec, Canada
Posts: 465
Velox Cruentus is on a distinguished road
Send a message via ICQ to Velox Cruentus Send a message via AIM to Velox Cruentus
Alright...

screenx( mousex, mousey );

Basically, You have your screen width/height, and the level width height.
The function changes the level location to the same point on your screen. It's like... If you're trying to go from layer 3 to layer 4. Layer 4 is using screen location, and Layer 3 is using level location.
__________________
In a world of change... Who'll you believe?
Reply With Quote
  #4  
Old 10-09-2005, 01:19 AM
Velox Cruentus Velox Cruentus is offline
Registered User
Velox Cruentus's Avatar
Join Date: Dec 2004
Location: Quebec, Canada
Posts: 465
Velox Cruentus is on a distinguished road
Send a message via ICQ to Velox Cruentus Send a message via AIM to Velox Cruentus
Raiden (Owner) (Sat Oct 8 19:17:35 2005):
ok. kool. what about worldx(x,y)?
Velox Cruentus (Sat Oct 8 19:18:14 2005):
It does the opposite. It converts screen to level.
Raiden (Owner) (Sat Oct 8 19:18:29 2005):
ok. thanks
Velox Cruentus (Sat Oct 8 19:18:42 2005):
That explains everything?
Raiden (Owner) (Sat Oct 8 19:18:59 2005):
ya. i think i get it now

( For those who want to go on with this... )
__________________
In a world of change... Who'll you believe?
Reply With Quote
  #5  
Old 10-14-2005, 08:43 PM
ApothiX ApothiX is offline
Okiesmokie
Join Date: May 2004
Posts: 1,447
ApothiX is on a distinguished road
Quote:
Originally Posted by Velox Cruentus
Raiden (Owner) (Sat Oct 8 19:17:35 2005):
ok. kool. what about worldx(x,y)?
Velox Cruentus (Sat Oct 8 19:18:14 2005):
It does the opposite. It converts screen to level.
Raiden (Owner) (Sat Oct 8 19:18:29 2005):
ok. thanks
Velox Cruentus (Sat Oct 8 19:18:42 2005):
That explains everything?
Raiden (Owner) (Sat Oct 8 19:18:59 2005):
ya. i think i get it now

( For those who want to go on with this... )
Why exactly did you post this, when someone already said:

Quote:
Originally Posted by ChibiChibiLuc
It converts screen coordinates to level coordinates.
Like screenx(x,y) and screeny(x,y), but opposite.
?
__________________


[06:24:19] * Parts: Skyld (i=silent@unaffiliated/skyld) ("Perhaps Okiesmokie did not realise that I like the boys. ")
Reply With Quote
  #6  
Old 10-15-2005, 02:56 AM
Velox Cruentus Velox Cruentus is offline
Registered User
Velox Cruentus's Avatar
Join Date: Dec 2004
Location: Quebec, Canada
Posts: 465
Velox Cruentus is on a distinguished road
Send a message via ICQ to Velox Cruentus Send a message via AIM to Velox Cruentus
He had not understood it beforehand. Thus, to clarify, I showed that he did understand, rather then just let other people explain. The two functions are pretty similar; if he didn't know one, the likelihood he didn't know the other is higher.
__________________
In a world of change... Who'll you believe?
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 01:04 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.