Search Results

Search found 2184 results on 88 pages for 'sprite kit'.

Page 13/88 | < Previous Page | 9 10 11 12 13 14 15 16 17 18 19 20  | Next Page >

  • Alt text vs CSS sprites (SEO vs speed)

    - by leeoniya
    I'm reworking our site to reduce HTTP requests and blocking requests by concatenating JS, css, gzipping, loading all JS via LABjs and using CSS sprites for images that were loaded individually via <img> tags before. Progress has been great so far - 5x page load performance improvement. However, we're in the top 5 organic search ranking in google for many targeted keywords and phrases. I'm afraid eliminating so many img tags with alt attributes can hurt our SEO. Does anyone have any experience with alt tag manip/removal and effects on SEO positions? Is previous rank "sticky"?

    Read the article

  • Switching my collision detection to array lists caused it to stop working

    - by Charlton Santana
    I have made a collision detection system which worked when I did not use array list and block generation. It is weird why it's not working but here's the code, and if anyone could help I would be very grateful :) The first code if the block generation. private static final List<Block> BLOCKS = new ArrayList<Block>(); Random rnd = new Random(System.currentTimeMillis()); int randomx = 400; int randomy = 400; int blocknum = 100; String Title = "blocktitle" + blocknum; private Block block; public void generateBlocks(){ if(blocknum > 0){ int offset = rnd.nextInt(250) + 100; //500 is the maximum offset, this is a constant randomx += offset;//ofset will be between 100 and 400 int randomyoff = rnd.nextInt(80); //500 is the maximum offset, this is a constant randomy = platformheighttwo - 6 - randomyoff;//ofset will be between 100 and 400 block = new Block(BitmapFactory.decodeResource(getResources(), R.drawable.block2), randomx, randomy); BLOCKS.add(block); blocknum -= 1; } The second is where the collision detection takes place note: the block.draw(canvas); works perfectly. It's the blocks that don't work. for(Block block : BLOCKS) { block.draw(canvas); if (sprite.bottomrx < block.bottomrx && sprite.bottomrx > block.bottomlx && sprite.bottomry < block.bottommy && sprite.bottomry > block.topry ){ Log.d(TAG, "Collided!!!!!!!!!!!!1"); } // bottom left touching block? if (sprite.bottomlx < block.bottomrx && sprite.bottomlx > block.bottomlx && sprite.bottomly < block.bottommy && sprite.bottomly > block.topry ){ Log.d(TAG, "Collided!!!!!!!!!!!!1"); } // top right touching block? if (sprite.toprx < block.bottomrx && sprite.toprx > block.bottomlx && sprite.topry < block.bottommy && sprite.topry > block.topry ){ Log.d(TAG, "Collided!!!!!!!!!!!!1"); } //top left touching block? if (sprite.toprx < block.bottomrx && sprite.toprx > block.bottomlx && sprite.topry < block.bottommy && sprite.topry > block.topry ){ Log.d(TAG, "Collided!!!!!!!!!!!!1"); } } The values eg bottomrx are in the block.java file..

    Read the article

  • CCSprite with actions crossing the screen boundaries (copy sprite problem)

    - by iostriz
    Let's say we have a CCSprite object that has an actions tied to it: -(void) moveJack { CCSpriteSheet *sheet = (CCSpriteSheet*)[self getChildByTag:kSheet]; CCSprite *jack = (CCSprite*)[sheet getChildByTag:kJack]; ... CCSequence *seq = [CCSequence actions: jump1, [jump1 reverse], jump2, nil]; [jack runAction:seq]; } If the sprite crosses over the screen boundary, I would like to display it at opposite side. So, original sprite is half displayed on the right side (for example), and half on the left side, because it has not fully crossed yet. Obviously (or is it), I need 2 sprites to achieve this. One on the right side (original), and one on the left side (a copy). The problem is - I don't know how to create exact copy of the original sprite, because tied actions have scaling and blending transformations (sprite is a bit distorted). I would like to have something like: CCSprite *copy = [[jack copy] autorelease]; so that I can add a copy to display it on the correct side (and kill it after transition is over). It should have all the actions tied to it... Any ideas?

    Read the article

  • How do you make a static sprite be a child of another sprite in cocos2D while using SpaceManager

    - by JJBigThoughts
    I have two static (STATIC_MASS) SpaceManager sprites. One is a child of the other - by which I mean that one sort of builds up the other one, but although the child's images shows up in the right place, the child doesn't seem to exists in the chipmunk physics engine, like I would expect. In my case, I have a backboard (rectangular sprite) and a hoop (a circular sprite). Since I might want to move the backboard, I'd like to attach the hoop to backboard so that the hoop automatically moves right along with the backboard. Here, we see a rotating backboard with attached hoop. It looks OK on the screen, but other objects only bounce off the backboard but pass right through the hoop (in a bad sense of the term). What doesn't my child sprite seem to exist in the physics engine? // Add Backboard cpShape *shapeRect = [smgr addRectAt:cpvWinCenter mass:STATIC_MASS width:200 height:10 rotation:0.0f ];// We're upgrading this cpCCSprite * cccrsRect = [cpCCSprite spriteWithShape:shapeRect file:@"rect_200x10.png"]; [self addChild:cccrsRect]; // Spin the static backboard: http://stackoverflow.com/questions/2691589/how-do-you-make-a-sprite-rotate-in-cocos2d-while-using-spacemanager // Make static object update moves in chipmunk // Since Backboard is static, and since we're going to move it, it needs to know about spacemanager so its position gets updated inside chipmunk. // Setting this would make the smgr recalculate all static shapes positions every step // cccrsRect.integrationDt = smgr.constantDt; // cccrsRect.spaceManager = smgr; // Alternative method: smgr.rehashStaticEveryStep = YES; smgr.rehashStaticEveryStep = YES; // Spin the backboard [cccrsRect runAction:[CCRepeatForever actionWithAction: [CCSequence actions: [CCRotateTo actionWithDuration:2 angle:180], [CCRotateTo actionWithDuration:2 angle:360], nil] ]]; // Add the hoop cpShape *shapeHoop = [smgr addCircleAt:ccp(100,-45) mass:STATIC_MASS radius: 50 ]; cpCCSprite * cccrsHoop = [cpCCSprite spriteWithShape:shapeHoop file:@"hoop_100x100.png"]; [cccrsRect addChild:cccrsHoop]; This is only half working for me. Note: SpaceManager is a toolkit for working with cocos2D-iphone

    Read the article

  • Image sprite not lining up in firefox

    - by Saif Bechan
    I am working with an image sprite to create my buttons. They work right in every browser except firefox. Lets say i have 2 spans next to eachother: <span class="spanleft"></span><span class="spanright"></span> and give them some styling(this is the actual code i use for the sprite) .spanleft{ background:url('/templates/default/img/auction/btn-toolbar.png') no-repeat 0 0; display:block; float:left; height:100px; width:13px; } .spanright{ background:url('/templates/default/img/auction/btn-toolbar.png') no-repeat 0 -104px; display:block; float:left; height:100px; width:30px; margin-left:0px; } Now this works in every browser i tested, the images line up great. But in firefox I get a small offset. Now i fiddled with the pixels a lot. Its not an offset of 1px, the offset is about 0.5 of a px. yeah. Ive made a screenshot of what i mean, and i'm going to put in the sprite for the buttons, they make lovely buttons, upstate,downstate,hover,disabled. You can use them in your projects. Here are the shots: This is the problem: Here is the image sprite: I hop this problem can be solved, i am working with FF 3.6. thanks guys!

    Read the article

  • How to recognize the touch of a non regular sprite image ?

    - by srikanth rongali
    I have a sprite and if it is touched the touch should be recognized. I used the coordinates to do so. I took the coordinates (min x, min y, max x , max y)of the sprite image. But The sprite image is not a rectangular shape. So, even if I touch the coordinates outside the sprite and inside the rectangular bounds the sprite is recognized. But for my application I need only the sprite to be recognized. So, I have to take only the coordinates of the sprite, but it is not regular shape. I am using CCSprite in my program. So, what can I do to for only the sprite to be selected ? Which classes should use for this? Thank You.

    Read the article

  • Sprite movement

    - by Lemmons
    Hi everyone. I'm ripping my hair out over this one. For some odd reason I cannot find out / think of how to move a sprite in SFML and or SDL. The tutorials I've looked at for both libraries state nothing about this; so I assume that it's more of a C++ thing than a library thing. So I was wondering; how do you move a sprite? (When I say move, I mean have the sprite "glide" across the window at a set speed)

    Read the article

  • Print a bitmap without printing a sprite?

    - by Carlos Barbosa
    Following up from: http://stackoverflow.com/questions/3021557/as3-printing-problem-blanks-swf-after-print-or-cancel I am trying to comeup with a function to print without creating a sprite, because that's what it seems to be causing my problem: public function printScreen():void { var pJob:PrintJob = new PrintJob(); var options:PrintJobOptions = new PrintJobOptions(); options.printAsBitmap = true; var bitmapData:BitmapData = new BitmapData(root.width, root.height); bitmapData.draw(root); var printThis:Bitmap = new Bitmap(bitmapData); try { pJob.start(); pJob.addPage(printThis, null, options); pJob.send(); } catch(e:Error) { trace("Error Printing") } } This is coming up with an: Error: Description Implicit coercion of a value of type flash.display:Bitmap to an unrelated type flash.display:Sprite. So how do you print a bitmap without creating a Sprite?

    Read the article

  • Unreal Development Kit Hardware requirements?

    - by gojira666
    I am very interested in trying out the Unreal Development Kit for my own small to medium-sized hobby projects. I am wondering about the minimum hardware requirements. I have a Vaio Z laptop with dual-core 2.4 GHZ CPU and 2 GB RAM, and graphics chip is GeForce 9300M GS. Is it even practicable to run UDK on this hardware? Or do I need a "real" desktop PC?

    Read the article

  • How to position a sprite in a 2D animation skeleton?

    - by Paul Manta
    Given two joints that define a bone, I would like to know how to decide where, between those two joints, I should draw the sprite. This should be a fairly simple thing to solve, but there is one thing that I am not sure about. After I've determined the rotation of the sprite (which is the absolute angle the joints form with the x-axis), I also need to determine the origin point from where I need to start drawing the transformed image. So how should I position the sprite between the two joints? Should I make the center of the image be the midpoint between the two joints, or should I make one the of the joints be the origin? Do these things matter that much (could the wrong positioning make the sprite move oddly during the animation)?

    Read the article

  • how to broadcast a PXE server like Trinity Rescue Kit

    - by Larry G. Wapnitsky
    I would like to set up a portable PXE server for diagnostic purposes. The issue is that I won't always have access to the DHCP server, or the router itself (sometimes a home router) doesn't have an easily accessible place to set the servername/file for broadcast. I know that Trinity Rescue Kit is able to broadcast its PXE server without its own DHCP server. Can anyone point me in the direction to set this up on my own (without Trinity)? Thanks.

    Read the article

  • Looking for a good computer repair kit

    - by johnny
    I'm afraid I'll get ripped if I get the generic kit from Tigerdirect or whatever. For clarity this is not software I am after but physical tools. It should include something for occassional soldering of electronics, crimper, other things I cannot remember. Hoping for ideas or product links (yes I am searching also). Thank you.

    Read the article

  • Cocos2d: Move a Sprite along a path/bezier ?

    - by eemceebee
    Hi I need to move a sprite from one CGPoint to another using Cocos2d for the Iphone. The problem is that the animation should be along a bezier. Basically I would use this : id move = [CCMoveTo actionWithDuration:.5f position:ccp(100,200)]; [sprite runAction:move]; Now how can I do this in a non linear path ? Thx

    Read the article

  • iPhone memory leaks with store kit

    - by Nareshkumar
    Hello, I am trying to develop an application which uses storekit api. The document (Store Kit guide) suggests that the api will not work on a simulator. I found out that memory leaks will not be able to work on a device. I was wondering if any one can tell me how to check for memory leaks while using a store kit api on a project? How is it possible?

    Read the article

  • css sprite button is jumping around

    - by Richard
    Hello everyone, Does anyone know what is causing the sprite rollover to jump around It is I think more likely a photoshop question, but I am not completely sure. I hope to get an answer here anyway, since I think most webdesigners/programmers problably worked with photoshop also. This is what I want the rollover to do example 1 and this is my testpage (see the play button) I made the sprite with spriteme.com thanks, Richard

    Read the article

  • Sprite to Line Collision

    - by Alu
    If I have a sprite, how would I check collision between two points? For example, in a game I am making, I would like to draw multiple lines that my sprite collides against. I'm thinking that this is more flexible than other collision systems if I had a lot of platforms.

    Read the article

  • How to setup Hessian Kit in iPhone existing projects

    - by Shikhar
    Hello Can any one help me to find out, how I can setup Hessian Kit on existing iPhone project. What are the steps required to run a simple hello world program. I have Hessian Kit (http://sourceforge.net/projects/hessiankit/) but don't know how I can include this in my existing project. Please help Thanks SD

    Read the article

  • Sprite not moving when using a function from another class SFML c++

    - by user2892932
    I have a Game.cpp, and I am calling a update function in my Player class. In my player update Function I have it to check for keyboard input, and it seems to work, but whenever I try to call the .move() function, it seems to not work. I get no errors either. I am new to sfml, and decent with c++. Help is appreciated! #include "Player.h" Player::Player(void): vel(0), maxvel(100) { Load("Assets/sss.png",true); } void Player::Update(sf::Sprite& p) { if (sf::Keyboard::isKeyPressed(sf::Keyboard::A)) { moveObject(-3,0, p); } if(sf::Keyboard::isKeyPressed(sf::Keyboard::D)) { moveObject(-3,0, p); } } Player::~Player(void) { } This is the GameObject cpp #include "GameObject.h" #include <iostream> GameObject::GameObject(void) { isLoaded = false; } void GameObject::Load(std::string flname, bool isPlayer) { if(!tex.loadFromFile(flname)) { EXIT_FAILURE; } else { if(isPlayer) { if(!tex.loadFromFile(flname, sf::IntRect(0,0,33,33))) { EXIT_FAILURE; } else { std::cout << "Loading image" << "\n"; filename = flname; spr.setTexture(tex); isLoaded = true; } } else { std::cout << "Loading image" << "\n"; filename = flname; spr.setTexture(tex); isLoaded = true; } } } void GameObject::Draw(sf::RenderWindow & window) { if(isLoaded) { window.draw(spr); window.display(); std::cout << "Sprite drew" << "\n"; } } void GameObject::setPos(float x, float y) { if(isLoaded) { spr.setPosition(x,y); } } sf::Vector2f GameObject::GetObjPos() { return spr.getPosition(); } sf::Sprite& GameObject::getSprite() { return spr; } void GameObject::moveObject(float x, float y, sf::Sprite& sp) { sp.move(x, y); } GameObject::~GameObject(void) { }

    Read the article

  • How do I test if a property exists on a object before reading its value?

    - by Jeremy Rudd
    I'm attempting to read a property on a series of Sprites. This property may or may not be present on these objects, and may not even be declared, worse than being null. My code is: if (child["readable"] == true){ // this Sprite is activated for reading } And so Flash shows me: Error #1069: Property selectable not found on flash.display.Sprite and there is no default value. Is there a way to test if a property exists before reading its value? Something like: if (child.isProperty("readable") && child["readable"] == true){ // this Sprite is activated for reading }

    Read the article

  • OSX pdf-kit vs Linux poppler or pdf/x

    - by Tahnoon Pasha
    I keep reading and hearing that the reason that there is no good pdf editing software for Linux is that the libraries are not as well developed. That is why there is no equivalent for Skim or Preview in Linux. I had a look a the pdf-kit documentation and the poppler documentation and they looked very similar to my admittedly non-technical view. Could someone explain to me why the OSX libraries (eg) are so much easier to write projects like Skim in than the linux ones. I'm not sure if the same applies to OSX projects to NVAlt, but it seems to be a common theme - I'd just like to understand what is behind the thesis that OSX is easier to code these projects in, and what would be involved in changing it. (I'm not disputing the value of Okular or Evince and the like, just noting that they don't have the richness of functionality of Skim, Preview or even things like Goodreader on the Ipad).

    Read the article

  • What's the point of Netgear's WNHDB3004 "3DHD WIRELESS HOME THEATER NETWORKING KIT"

    - by badp
    Here's a crude representation of what I've got at home: floor 2 INTERNETS ---- MODEM/ROUTER ---- MY COMPUTER | floor 1 WIFI REPEATER ---- stuff | floor 0 more stuff TELEVISION Now, as part of our sat tv subscription we can get an additional service if we connect our decoder (located by TELEVISION obviously) to the internet. What they suggest is buying a Netgear 3DHD WIRELESS HOME THEATER NETWORKING KIT holy shit isn't my bullshit-o-meter flying high right now from the general buzzwordyness of this thing. What does this thing actually do that our existing wireless-enabled routers don't do? What's the point of having a third wifi router in the same house, this time only for one television? If I do decide to plunge €99 for this, should I connect it to the wifi repeater (which does not provide AAA quality internet, at least for all gaming purposes) or to my modem/router (risking issues with low signal?).

    Read the article

  • Ember-App-Kit: How to execute code only in release mode?

    - by Dominik Schmidt
    I have created an error handler as described here: http://emberjs.com/guides/understanding-ember/debugging/#toc_implement-a-code-ember-onerror-code-hook-to-log-all-errors-in-production But this code is not only executed in production mode but also in normal debug builds which floods my server logs. I know that Ember.debug() calls and alike are being filtered out for production builds, but I couldn't find out where/how that is implemented and if that same mechanism could be used to make my code only fire in production code.

    Read the article

  • use a sprite png in li-class and display in div

    - by bonny
    hello i have some problem with displaying a sprite in a div that is in a li-class. so the structure is: <li id="aa"> <div><a href="#">one</a></div> </li> and the css: li{ width: 120px; height: 18px; margin-top: 5px; } li div{ width: 20px; height: 10px; background-image:url(../images/sprite.png) background-repeat: no-repeat; margin-left: 0px; font-weight:bolder; border: 1px solid #fff; } when i use this i can see the sprite even outside the div. so i tried adding to li background-image: none; that makes the image in the div not visible too. so if there is someone who know about that i really would appreciate. thanks alot.

    Read the article

< Previous Page | 9 10 11 12 13 14 15 16 17 18 19 20  | Next Page >