animated texture?

hi everyone, im new here n.n.
please forgive me, my english is not good.

im having problems with animated textures, i make a low poly tank and i want make static tracks and add only texture movement, but when i animated with offset texture, in bge don’t work but in animation yes.

here i leave a image of my tank n.n, if anyone can give me a hand, i really apreciate, i start using blender like 2 weeks past.


thanks for read!.

r113

You have the logic bricks connected to the ipo curve animation?

yes… i put, keyboard: w letter —> and —> f-curve play frame 1 -> 100 and too shape action and select MaterialAction frame 1 -> 100 and nothing happens u.u…

Well through a search on the forum I was able to find this topic. See if it works for you

Link

thanks, i read that today and test and dont help me, because tiled animation dont use ipo curve or something like that and i can’t change speed of animation or make a slow down, or if im wrong say me, im going continue searching n.n.

Ok good luck and sorry I couldn’t be more of help

Search for the UV-Scroll script. I think that will help you.

Here is a link to a UV-Scroll script. http://blenderartists.org/forum/showthread.php?t=146155&highlight=bullethole+parrent

thanks, monster, i going to take a look at that script n.n, i see a video and i think is what i need.

oh lol, thanks i dont see your reply, thanks a lot, you just saved me a little time searching n.n, thanks guys.

Here’s my tank

you put a image?, or i dont know why i cant see your tank… u.u.

sorry, can’t upload, here’s the link: http://www.matter.x10.mx/tanks.blend

omg, really nice! i like it n.n, i want something like that, but i dont know how do some things in blender, but im learning slowly haha.

how you make the turret dont turn all ?, i mean dont make a complete 360º, with ipo property?, hehe i take a look to your logics, i can use your script?, only if you permit me n.n, nice tank!

i leave my script, i get a error when i run bge, “NameError: name ‘speed’ is not defined” but the texture move nice n.n only i want to know what is that error.

########### UV SCROLL SCRIPT ##################33
##### -[Killer]- #########



#get all the mesh info
cont = GameLogic.getCurrentController() 
own = cont.getOwner() 
mesh = own.getMesh() 
array = mesh.getVertexArrayLength(0)
#...

# Variables

speedLeft = cont.sensors["Left"]
speedRight = cont.sensors["Right"]

if speedLeft.positive == True:
        
    speed = own.speed
    
elif speedRight.positive == True:
        
    speed = -own.speed

axis = own.axis
#...

# find what axis to move on
if axis == "x":
    axis = 0
if axis == "y":
    axis = 1
#...
    
    
# Now let's move the UV
for v in range(0,array):
    vertex = mesh.getVertex(0,v)
    UV = vertex.getUV()
    UV[axis] = UV[axis]+speed
    vertex.setUV(UV)
#...

i have one idea, but i need a little help n.n, can i make the texture move at speed of rotation of something?, i mean like speed of texture move = (the rotation speed o move speed or something like that of other object), can this make with a command in the script?

thanks for read n.n.

r113

not really…
1)can you explain about ipo?
2)maybe the owner hasn’t got a speed property.

im now modeling the tracks (really easy-simple model haha) and apply texture and normal map, and testing stuff n.n, looks nice, but i want make the movement have the same speed of the wheels, a little hard hehe…
1)yep, i see your tank settings, in logic you have "keyboard —> and —> property (sorry is no ipo, im wrong n.n), is this for make the turret don’t make a 360º rotation?..
2)im going to start adding values to repair that error haha, i don’t know much of python n.n.

sorry if you dont understand what i write, my english is pretty bad u.u.

No, its fine. For the tank, I animate it so that I have 180 upon frames. The upon actuator uses a property for the frame number, so using left it right adds it subtracts from the property, hence moving the turret 1 degree left or right. In terms of wheel speed, find out the ratio between wheel and track speee,then use that.

thanks for response, im going to test that, im seraching right now how i can move the texture speed at the wheel speed rotation.

i want find how to do that, and make a suspension for the wheels n.n,
here i leave my track with a texture made by me, dont look fine but works.

Attachments

track_texture.blend (346 KB)