Questions tagged [sprite]

A sprite is a two-dimensional image or animation that is integrated into a larger scene.

Sprite

A sprite is a two-dimensional image or animation that is integrated into a larger scene.

Spriting

The term is also used when taking subsections of a larger image file containing icons for display. This allows browsers to load only one image file and reuse it to display many icons by using offsets. This is known as spriting.

FAQs

Resources

4792 questions
1
vote
2 answers

Swift 3: Consistent player movement along Joystick || Spritekit

My question is how can i incorporate my sprite to have a continuous movement along with the joystick? I want the player to be moving at a certain speed the whole time, and then whenever the user moves the joystick a certain angle then the player…
1
vote
0 answers

Dynamic sprite batching

i have implemented a simple 2d renderer which works but not with textures or dynamic objects. First to say is that i have 4 classes that i think are the most important ones. Renderer, Scene,Sprite, SpriteBatch. To explain what i am doing i will…
greedsin
  • 1,252
  • 1
  • 24
  • 49
1
vote
0 answers

handle sprite that leaves screen area in SpriteKit

I'm building a platformer, and I'm trying too learn about being efficient with memory and cpu cycles. Is there an efficient way to handle sprites that are off screen? I guess the idea is, only handle the sprites on screen or close to it, all other…
Discoveringmypath
  • 1,049
  • 9
  • 23
1
vote
1 answer

Crafty.js not recognizing collision with other entities

I'm trying to learn crafty by coding a simplistic pacman game but I have had trouble ever since I changed the main player from a square to a sprite. I have the code below and I get a chomping pacman that I can move around the screen that changes…
1
vote
1 answer

SKPhysicsBody(bodies: collisionBitMask does not work

I have situation where I need to create two SKPhysicsBody for a single texture because the collision response need to be different let leftBigBox = SKPhysicsBody(rectangleOf :CGSize(width: 490, height: 90) , center:bCenterPoint ) …
merloin
  • 31
  • 3
1
vote
1 answer

Issues with batch drawing with atlas files and SpriteKit

So I ran into a problem with lag on a platformer game I'm building. So I'm researching how to improve performance. I'm trying to do batch drawing, so that there is less draw calls. I'm having issues though. So with a brand new project: I have 4 hero…
Discoveringmypath
  • 1,049
  • 9
  • 23
1
vote
0 answers

Css Sprite of SVG files

I am developing a template with html5, css3, js and jQuery. I have some SVG photos and I was wondering if is it possible to make a sprite with all of them. I have rad on the internet a couple of articles on this topic but I didn't quite understand.…
John Doe
  • 571
  • 1
  • 9
  • 26
1
vote
1 answer

Nearest Neighbour interpolation for Direct3D sprites?

I'm working on a 2D game using Direct3D 10's ID3DX10Sprite interface. It works pretty well except for that the textures are filtered using a linear algorithm (I think?), which makes them look pretty ugly when you scale them. Original texture (32 x…
Visual Vincent
  • 18,045
  • 5
  • 28
  • 75
1
vote
1 answer

How to use an id to load sprite sheets and img files in Corona SDK?

The title sounds confusing, but what I am looking for is something like this: https://www.youtube.com/watch?v=GhI98-HJk6o Just watch the first minute, notice when the player taps the bottom squares the appropriate unit is spawned. I am trying to…
alexjr
  • 25
  • 5
1
vote
2 answers

Update one surface in Pygame

I have a game with a background made of tiles, some are static (grass, mud), but i want water to be flowing. i have created a surface called water, then i have a loop that iterates through a series of 10 pngs for the frames of the water flowing. i…
lavelle
  • 1,446
  • 1
  • 17
  • 30
1
vote
2 answers

Processing: How can I make a game board with an array?

I need to make a game board - using an array - for a Bomberman game remake in Processing. This means the game board / array (which is rather large [9x9] and has 3 values [a,b,c] throughout), has to be able to: Define the color/sprite of the…
Unarmed
  • 11
  • 3
1
vote
1 answer

Swift SpriteKit Add timer to GameScene

I have looked around at many articles, but none of them seem to make sense or are relevant to my issue. I want to give the user a set time to press a node. If they succeed in pressing the node within the set time the timer should reset, if they fail…
raeman23
  • 51
  • 1
1
vote
0 answers

Webpack without output option

I'm using webpack for generating sprite files(.png, .less). And the plugin I'm using is generated files itself, so there is no need to use output (also entry). The trouble is that this option is required in webpack. Any ideas how to solve this ?
1
vote
1 answer

Why does my Java key input work only sometimes?

I've been trying to add some key input to my code for a while now, but for some reason it won't work in one class but in another it works just fine and I don't know why. An Example Here Is the one that DOES work. import…
1
vote
1 answer

How to ensure sprites face the correct direction at all times in a 2D top down game. (logic)

I am making a multiplayer top down 2D game with 3d elements. All my movement, healthbars and basic functionality is working flawlessly even while hosted and playing on a server, node.js socket.io. However In this game it is possible to move the…
SteenPetersen
  • 188
  • 2
  • 17
1 2 3
99
100