
@rataime: you said that you need that we remind you.hanmac;209135 said:cann you make it so: with a value at the mirror part change left and right.
this where a good effect at horror games^^
SHADOWS_DIRECTION_ARRAY = Array.new
SHADOWS_DIRECTION_ARRAY[2] = [ -3, 4, -2, 1 ]
SHADOWS_DIRECTION_ARRAY[4] = [ 4, -2, 1, -3 ]
SHADOWS_DIRECTION_ARRAY[6] = [ 1, -3, 4, -2 ]
SHADOWS_DIRECTION_ARRAY[8] = [ -2, 1, -3, 4 ]
#EDITED TO WORK PROPERLY WITH PIXEL MOVE
SHADOWS_DIRECTION_ARRAY = Array.new
if (SDK.state('Pixelmovement') == true)
SHADOWS_DIRECTION_ARRAY[1] = [ -3, 4, -2, 1 ] #EDIT
end
SHADOWS_DIRECTION_ARRAY[2] = [ -3, 4, -2, 1 ]
if (SDK.state('Pixelmovement') == true)
SHADOWS_DIRECTION_ARRAY[3] = [ -3, 4, -2, 1 ] #EDIT
end
SHADOWS_DIRECTION_ARRAY[4] = [ 4, -2, 1, -3 ]
if (SDK.state('Pixelmovement') == true)
SHADOWS_DIRECTION_ARRAY[5] = [ 4, -2, 1, -3 ] #EDIT
end
SHADOWS_DIRECTION_ARRAY[6] = [ 1, -3, 4, -2 ]
if (SDK.state('Pixelmovement') == true)
SHADOWS_DIRECTION_ARRAY[7] = [ 1, -3, 4, -2 ] #EDIT
end
SHADOWS_DIRECTION_ARRAY[8] = [ -2, 1, -3, 4 ]
if (SDK.state('Pixelmovement') == true)
SHADOWS_DIRECTION_ARRAY[9] = [ -2, 1, -3, 4 ] #EDIT
end
rataime;216398 said:This is why you need to remind me things I have to do. Will look into that verysoonnow.
SDK.log('MobileLightSource', 'Trebor777', 1.00, '09.11.2007')
if SDK.enabled?('Shadows') and SDK.enabled?('MobileLightSource')
class Sprite_Shadow
alias treb_mobile_source_update update
def update
if @old_amin.nil? and @old_amax.nil? and @old_dir.nil?
@old_amin= @anglemin
@old_amax= @anglemax
@old_dir = @source.character.direction
end
case @source.character.direction
when 2
@anglemin= @old_amin+270
@anglemax= @old_amax+270
when 4
@anglemin= @old_amin+180
@anglemax= @old_amax+180
when 8
@anglemin= @old_amin+90
@anglemax= @old_amax+90
when 6
@anglemin= @old_amin
@anglemax= @old_amax
end
if @old_dir!=@source.character.direction
@old_dir = @source.character.direction
end
@anglemin%=360 ;@anglemax%=360
treb_mobile_source_update
end
end
end
shadowball;316411 said:well I have a map and it includes about 10 or 15 fake streetlights... The only thing is that the main character is able to move far away from any of those and his shadows are still visible... That kind thing looked pretty weird to me. I know I could create another streetlight to disguise these script behaviour a little bit, but...