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 04-02-2007, 12:12 PM
Twinny Twinny is offline
My empire of dirt
Twinny's Avatar
Join Date: Mar 2006
Location: Australia
Posts: 2,422
Twinny is just really niceTwinny is just really nice
Send a message via AIM to Twinny
Black areas with custom movement

Part of my custom movement system involves moving around without using keys. When doing this though, i often reach black areas of the map. For example, the leaping part uses
PHP Code:
player.-= cos(ang)*1.6;
player.+= sin(ang)*1.6
If a player just leaps using mouse without touching the keyboard, the tiles eventually go black but you can still see NPCs. The movement is done clientside but so are most movement systems. How can I fix this?
Reply With Quote
  #2  
Old 04-02-2007, 12:16 PM
Chompy Chompy is offline
¯\(º_o)/¯
Chompy's Avatar
Join Date: Sep 2006
Location: Norway
Posts: 2,815
Chompy is just really niceChompy is just really niceChompy is just really nice
Send a message via MSN to Chompy
try a sleep() before altering the x and y (0.05 for example)

I've seen this problem in an other thread, let me see if I find it..
__________________
Reply With Quote
  #3  
Old 04-02-2007, 12:20 PM
Twinny Twinny is offline
My empire of dirt
Twinny's Avatar
Join Date: Mar 2006
Location: Australia
Posts: 2,422
Twinny is just really niceTwinny is just really nice
Send a message via AIM to Twinny
Quote:
Originally Posted by Chompy View Post
try a sleep() before altering the x and y (0.05 for example)
Made it choppy but i still see black

It doesn't go black if you are holding down a movement key but since it itself can be custom scripted, do you just need to have one of the 4 directional keys down for it to load the map?
Reply With Quote
  #4  
Old 04-02-2007, 12:31 PM
Chompy Chompy is offline
¯\(º_o)/¯
Chompy's Avatar
Join Date: Sep 2006
Location: Norway
Posts: 2,815
Chompy is just really niceChompy is just really niceChompy is just really nice
Send a message via MSN to Chompy
Quote:
Originally Posted by Twinny View Post
Made it choppy but i still see black

It doesn't go black if you are holding down a movement key but since it itself can be custom scripted, do you just need to have one of the 4 directional keys down for it to load the map?
I found the thread, but that was for a draisine tho..

but try put freezeplayer(0.1); before altering the x and y


thread:
http://forums.graalonline.com/forums...ad.php?t=65190
__________________
Reply With Quote
  #5  
Old 04-02-2007, 01:01 PM
Twinny Twinny is offline
My empire of dirt
Twinny's Avatar
Join Date: Mar 2006
Location: Australia
Posts: 2,422
Twinny is just really niceTwinny is just really nice
Send a message via AIM to Twinny
freezeplayer() didn't work. I tried the disabledefmovement and it worked for a bit then the map updates when you enter new map area and it buggers up again. I tried doing playerenters() tests and such with no luck.
Reply With Quote
  #6  
Old 04-02-2007, 01:28 PM
JkWhoSaysNi JkWhoSaysNi is offline
Ruler of the graalaxy
Join Date: Feb 2005
Location: Great Britain
Posts: 488
JkWhoSaysNi is on a distinguished road
Send a message via ICQ to JkWhoSaysNi
I've only seen this happen on GMaps. I don't know how to fix it but it happens when you move between levels without triggering the level link.

edit: At a guess i'd say that calling setlevel2(player.level,player.x,player.y) after the move would fix it.
__________________

Coming soon (Hopefully:P)
Reply With Quote
  #7  
Old 04-02-2007, 01:48 PM
Chompy Chompy is offline
¯\(º_o)/¯
Chompy's Avatar
Join Date: Sep 2006
Location: Norway
Posts: 2,815
Chompy is just really niceChompy is just really niceChompy is just really nice
Send a message via MSN to Chompy
Quote:
Originally Posted by JkWhoSaysNi View Post
setlevel2(player.level,player.x,player.y)

That's serverside :[
__________________
Reply With Quote
  #8  
Old 04-02-2007, 01:53 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Quote:
Originally Posted by Chompy View Post
That's serverside :[
Not only is it serverside, but it's setlevel2(levelname, x, y);.
__________________
Skyld
Reply With Quote
  #9  
Old 04-02-2007, 02:04 PM
Twinny Twinny is offline
My empire of dirt
Twinny's Avatar
Join Date: Mar 2006
Location: Australia
Posts: 2,422
Twinny is just really niceTwinny is just really nice
Send a message via AIM to Twinny
Any suggestions, Master Skyld?
Reply With Quote
  #10  
Old 04-03-2007, 12:48 AM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
Run to store and buy a copy of Windows Accelerat0r and run back to your computer, then jump up and down for a while then install the software. Now run your script! Everythings fixed! No more script! Graal won't start anymore! Problem solved!
__________________
Reply With Quote
  #11  
Old 04-03-2007, 01:00 AM
napo_p2p napo_p2p is offline
oh snaps
napo_p2p's Avatar
Join Date: Sep 2003
Location: Pismo Beach, California
Posts: 2,118
napo_p2p has a spectacular aura aboutnapo_p2p has a spectacular aura about
Send a message via AIM to napo_p2p Send a message via MSN to napo_p2p
disabledefmovement always solved this problem for me before...
__________________
Scito hoc super omnia.
Haec vita est tua una sola.
Dum vita superest, utere maxime quoque puncto, momento, et hora quae habes.
Tempus neminem non manet.
Noli manere tempus.
Carpe Diem

Seize the Day.
Reply With Quote
  #12  
Old 04-03-2007, 01:23 AM
Crow Crow is offline
ǝɔɐɹq ʎןɹnɔ
Crow's Avatar
Join Date: Dec 2006
Location: Germany
Posts: 5,153
Crow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond repute
Quote:
Originally Posted by napo_p2p View Post
disabledefmovement always solved this problem for me before...
I guess Zone is also using an own movement system, so they would also have to use disabledefmovement. But its also happening there ;o
Reply With Quote
  #13  
Old 04-03-2007, 03:09 AM
Kristi Kristi is offline
Bowie's Deciple
Kristi's Avatar
Join Date: Dec 2003
Location: Boston, MA
Posts: 748
Kristi has a spectacular aura aboutKristi has a spectacular aura about
Send a message via AIM to Kristi Send a message via MSN to Kristi
Quote:
Originally Posted by napo_p2p View Post
disabledefmovement always solved this problem for me before...
Classic doesnt have this problem and we also use disabledefmovement at all times so this might do it...
__________________
Reply With Quote
  #14  
Old 04-03-2007, 03:17 AM
Gambet Gambet is offline
Registered User
Join Date: Oct 2003
Posts: 2,712
Gambet is on a distinguished road
Quote:
Originally Posted by Kristi View Post
Classic doesnt have this problem and we also use disabledefmovement at all times so this might do it...

Custom health system and a custom movement system.



We have been deceived, they are not really classic!



REBEL! REBEL! REEEEBBBEEEELLLLLLL!!!!!
Reply With Quote
  #15  
Old 04-03-2007, 04:18 AM
Rapidwolve Rapidwolve is offline
Registered User
Join Date: Jul 2006
Posts: 1,241
Rapidwolve is an unknown quantity at this point
Quote:
Originally Posted by Gambet View Post
Custom health system and a custom movement system.



We have been deceived, they are not really classic!



REBEL! REBEL! REEEEBBBEEEELLLLLLL!!!!!
This is true
Reply With Quote
  #16  
Old 04-03-2007, 10:26 PM
Angel_Light Angel_Light is offline
Varia Developer
Angel_Light's Avatar
Join Date: Nov 2005
Location: Knoxville, TN
Posts: 1,684
Angel_Light is on a distinguished road
Send a message via AIM to Angel_Light Send a message via MSN to Angel_Light
disabledefmovement(); is what Niromia had to use. We have to keep it in a timeout oddly enough or else the disabledef doesnt work for long. :/
__________________
Deep into the Darkness peering...
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 12:24 PM.


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