Code: class Game_Event def check_event_trigger_touch(x, y) # If event is running if $game_system.map_interpreter.running? return end # If trigger is [touch from event] and consistent with player coordinates min = $game_player.x+ @size[0].to_i%2-1- @size[0].to_i / 2 max = $game_player.x+ @size[0].to_i / 2+ @size[0].to_i % 2-1 ny = y ny = y - @size[1] + 1 unless @size[0].nil? if @trigger == 2 and x.between?(min,max) and $game_player.y.between?(ny,y) # If starting determinant other than jumping is front event if not jumping? and not over_trigger? start end end end end class Game_Player def check_event_trigger_touch(x, y) result = false # If event is running if $game_system.map_interpreter.running? return result end # All event loops for event in $game_map.events.values # If event coordinates and triggers are consistent min = event.x+event.size[0].to_i%2-1-event.size[0].to_i / 2 max = event.x+event.size[0].to_i / 2+event.size[0].to_i % 2-1 ny = y ny = y + event.size[1]-1 unless event.size[0].nil? if x.between?(min,max) and event.y.between?(y,ny) and [1,2].include?(event.trigger) # If starting determinant is front event (other than jumping) if not event.jumping? and not event.over_trigger? event.start result = true end end end return result end #-------------------------------------------------------------------------- # * Front Envent Starting Determinant #-------------------------------------------------------------------------- def check_event_trigger_there(triggers) result = false # If event is running if $game_system.map_interpreter.running? return result end # Calculate front event coordinates new_x = @x + (@direction == 6 ? 1 : @direction == 4 ? -1 : 0) new_y = @y + (@direction == 2 ? 1 : @direction == 8 ? -1 : 0) # All event loops for event in $game_map.events.values min = event.x+event.size[0].to_i%2-1-event.size[0].to_i / 2 max = event.x+event.size[0].to_i / 2+event.size[0].to_i % 2-1 ny = new_y ny = new_y + event.size[1]-1 unless event.size[0].nil? # If event coordinates and triggers are consistent if new_x.between?(min,max) and event.y.between?(new_y,ny) and triggers.include?(event.trigger) # If starting determinant is front event (other than jumping) if not event.jumping? and not event.over_trigger? event.start result = true end end end # If fitting event is not found if result == false # If front tile is a counter if $game_map.counter?(new_x, new_y) # Calculate 1 tile inside coordinates new_x += (@direction == 6 ? 1 : @direction == 4 ? -1 : 0) new_y += (@direction == 2 ? 1 : @direction == 8 ? -1 : 0) # All event loops for event in $game_map.events.values min = event.x+event.size[0].to_i%2-1-event.size[0].to_i / 2 max = event.x+event.size[0].to_i / 2+event.size[0].to_i % 2-1 ny = new_y ny = new_y + event.size[1]-1 unless event.size[0].nil? # If event coordinates and triggers are consistent if new_x.between?(min,max) and event.y.between?(new_y,ny) and triggers.include?(event.trigger) # If starting determinant is front event (other than jumping) if not event.jumping? and not event.over_trigger? event.start result = true end end end end end return result end end das 2. script damit ersetzen. die bugs sollten nun weg sein und die anderen trigger werden nun unterstützt.
class Game_Event def check_event_trigger_touch(x, y) # If event is running if $game_system.map_interpreter.running? return end # If trigger is [touch from event] and consistent with player coordinates min = $game_player.x+ @size[0].to_i%2-1- @size[0].to_i / 2 max = $game_player.x+ @size[0].to_i / 2+ @size[0].to_i % 2-1 ny = y ny = y - @size[1] + 1 unless @size[0].nil? if @trigger == 2 and x.between?(min,max) and $game_player.y.between?(ny,y) # If starting determinant other than jumping is front event if not jumping? and not over_trigger? start end end end end class Game_Player def check_event_trigger_touch(x, y) result = false # If event is running if $game_system.map_interpreter.running? return result end # All event loops for event in $game_map.events.values # If event coordinates and triggers are consistent min = event.x+event.size[0].to_i%2-1-event.size[0].to_i / 2 max = event.x+event.size[0].to_i / 2+event.size[0].to_i % 2-1 ny = y ny = y + event.size[1]-1 unless event.size[0].nil? if x.between?(min,max) and event.y.between?(y,ny) and [1,2].include?(event.trigger) # If starting determinant is front event (other than jumping) if not event.jumping? and not event.over_trigger? event.start result = true end end end return result end #-------------------------------------------------------------------------- # * Front Envent Starting Determinant #-------------------------------------------------------------------------- def check_event_trigger_there(triggers) result = false # If event is running if $game_system.map_interpreter.running? return result end # Calculate front event coordinates new_x = @x + (@direction == 6 ? 1 : @direction == 4 ? -1 : 0) new_y = @y + (@direction == 2 ? 1 : @direction == 8 ? -1 : 0) # All event loops for event in $game_map.events.values min = event.x+event.size[0].to_i%2-1-event.size[0].to_i / 2 max = event.x+event.size[0].to_i / 2+event.size[0].to_i % 2-1 ny = new_y ny = new_y + event.size[1]-1 unless event.size[0].nil? # If event coordinates and triggers are consistent if new_x.between?(min,max) and event.y.between?(new_y,ny) and triggers.include?(event.trigger) # If starting determinant is front event (other than jumping) if not event.jumping? and not event.over_trigger? event.start result = true end end end # If fitting event is not found if result == false # If front tile is a counter if $game_map.counter?(new_x, new_y) # Calculate 1 tile inside coordinates new_x += (@direction == 6 ? 1 : @direction == 4 ? -1 : 0) new_y += (@direction == 2 ? 1 : @direction == 8 ? -1 : 0) # All event loops for event in $game_map.events.values min = event.x+event.size[0].to_i%2-1-event.size[0].to_i / 2 max = event.x+event.size[0].to_i / 2+event.size[0].to_i % 2-1 ny = new_y ny = new_y + event.size[1]-1 unless event.size[0].nil? # If event coordinates and triggers are consistent if new_x.between?(min,max) and event.y.between?(new_y,ny) and triggers.include?(event.trigger) # If starting determinant is front event (other than jumping) if not event.jumping? and not event.over_trigger? event.start result = true end end end end end return result end end
--Es ist ein magisches Liopleurodon =D
Foren-Regeln