Jump to content
New account registrations are disabed. This website is now an archive. Read more here.

dutchy

Member
  • Content Count

    7
  • Joined

  • Last visited

Everything posted by dutchy

  1. Thanks for the support, I'm trying to get my hed around it all my self... sometimes i get lucky sometimes i can't get anything right... :(
  2. Correct... I just want the character to jump to the closest option. In example... ---Example 1---- (start) x x x o o x o o (max jump length*) *8 tiles *x = can't pass *o = passable ground. (*each represent a tile) If the Example 1 The player is jumping to the right, because the 4th tile is available to land on then it should land there instead of the 8th tile because that's the max jump length. The only time a player should jump 8 tiles is when a situation like this comes up as shown in Example 2. ---Example 2---- (start) x x x x x x x o (finish) If also possible can it be defined within that code that the minimum jump length is 2 tiles? So that the character isn't jumping one tile at a time?
  3. No, sorry. I'll try and explain it like this... Say if a player needs to jump 4 Tiles and the Jump_Distance = 8 Instead of jumping all 8 Tiles He should only Jump 4 because that's where the closest land place is.
  4. dutchy

    [FIXED] Moving Event

    It was due to an anti-lag script... When the event walked outside the Buffer Area it would stop to save resources
  5. Not sure why you posted that
  6. Hello all, Below is a code for a jumping script. It works great however I just want to be able to change one little thing... If a player can Jump the distance (In my example 6 tiles) but can do it 4 or 3 because that's where the closes landing point is, then I'd like my character to be able to do that, instead of jumping the full 6 squares. I've looked though a number of Jumping Scripts and did a pretty wide google search and found nothing... Any support would mean the world to me #:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= # Simple Jump System by Nathmatt # Version: 1.03 # Type: Custom Movement System #:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= # # This work is protected by the following license: # #---------------------------------------------------------------------------- # # # # Creative Commons - Attribution-NonCommercial-ShareAlike 3.0 Unported # # ( http://creativecommons.org/licenses/by-nc-sa/3.0/ ) # # # # You are free: # # # # to Share - to copy, distribute and transmit the work # # to Remix - to adapt the work # # # # Under the following conditions: # # # # Attribution. You must attribute the work in the manner specified by the # # author or licensor (but not in any way that suggests that they endorse you # # or your use of the work). # # # # Noncommercial. You may not use this work for commercial purposes. # # # # Share alike. If you alter, transform, or build upon this work, you may # # distribute the resulting work only under the same or similar license to # # this one. # # # # - For any reuse or distribution, you must make clear to others the license # # terms of this work. The best way to do this is with a link to this web # # page. # # # # - Any of the above conditions can be waived if you get permission from the # # copyright holder. # # # # - Nothing in this license impairs or restricts the author's moral rights. # # # #---------------------------------------------------------------------------- # #:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= # # This is the config: # # (Jump_Distance) is how far you want to jump. # # (Cant_Jump) is the terrain tag that you cant jump on. # # (Off_Switch_id) is the swith id used to turn off the jump. # # (Jump_key) is the key used to jump if using tons ads custom controls. # # (Jump_Animation) is if you want a speacial graphic for jumping # add _jmp so 001-Fighter01 would be 001-Fighter01_jmp. # #------------------------------------------------------------------------------- module Nathmatt_Config Jump_Distance = 2 Jump_Animation = false Off_Switch_id = 50 Jump_Key = 'Space' # Terrain_Tags Cant_Jump = 1 end #:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= # # This is the update method: # #------------------------------------------------------------------------------- class Game_Player < Game_Character alias nathmatt_update update def update nathmatt_update actor = $game_party.actors[0] unless actor == $game_party.actors[0] if $tons_version != nil && $tons_version >= 5.40 && TONS_OF_ADDONS::CUSTOM_CONTROLS if Input.trigger?(Input::Key[Nathmatt_Config::Jump_Key]) unless jumping? || $game_switches [Nathmatt_Config::Off_Switch_id] c = Nathmatt_Config::Cant_Jump d = Nathmatt_Config::Jump_Distance case direction when 2 then jump(0,d) unless check_terrain(0,d,c) when 4 then jump(-d,0) unless check_terrain(-d,0,c) when 6 then jump(d,0) unless check_terrain(d,0,c) when 8 then jump(0,-d) unless check_terrain(0,-d,c) end end end else if Input.trigger?(Input::A) unless jumping? || $game_switches [Nathmatt_Config::Off_Switch_id] c = Nathmatt_Config::Cant_Jump d = Nathmatt_Config::Jump_Distance case direction when 2 then jump(0,d) unless check_terrain(0,d,c) when 4 then jump(-d,0) unless check_terrain(-d,0,c) when 6 then jump(d,0) unless check_terrain(d,0,c) when 8 then jump(0,-d) unless check_terrain(0,-d,c) end end end end if jumping? && Nathmatt_Config::Jump_Animation @character_name_org = actor.character_name @character_name = @character_name_org+'_jmp' end if @character_name != actor.character_name @character_name = actor.character_name unless jumping? end end def check_terrain(x,y,condition) px = $game_player.x + x py = $game_player.y + y if $game_map.terrain_tag(px,py) == condition return true else return false end end end
  7. dutchy

    [FIXED] Moving Event

    I'm having an annoying issue that I am sure comes with a simple answer. Why is it that when I set an event to walk to somewhere off screen it will wait until i can see it before it goes further? I'm trying to set up a race with an event but as soon as the event goes off screen it stops moving... Please Help!
×
×
  • Create New...