Recent posts by Vara on Kongregate

Subscribe to Recent posts by Vara on Kongregate

1 hour ago
avatar for Vara Vara 898 posts

Topic: Programming / Savedata not working... (AS3.0, Flex)

You can’t save a custom class you’ve made yourself. (or at least, not as far as I know)
Try to convert it to a build-in class, like an Object or an Array.

 
20 hours ago
avatar for Vara Vara 898 posts

Topic: Battle Dawn / About spies

I have a couple of questions about the functionality of spies:

+ It says that if another unit steps on your spy, a spy battle will begin. But if I put my spy on anonther unit, will a battle begin too?
+ If the prevous question is “no”, what will happen when I put my spy on an hostile casle, building up the infiltration points, and then an enemy unit moves to that casle?
+ Can you see if a castle uses spy alertness?
+ The spy alertness says “Adds 50 ticks of spy alertness. Any spy trying to conduct an opertation with a lower infiltration than …” but it doesn’t finish the sentence. Does anybody know the complete sentence?

 
Mar 12, 2010
avatar for Vara Vara 898 posts

Topic: Battle Dawn / New statistics

Since yesterday, I can’t login at fantasy land anymore. However, I can still login at the other worlds.

The last time I checked (yesterday), I was the highest ranked player of fantasy world and I had one crystal. I did also raze one of my outpost and trained a spy. (it might be that one of those thing are causing the problems)

Every time I try to login, the loading screen appears and loads, but the loading bar never comes farther than the second-last part.

(I have already tried clearing my cache)

 
Mar 4, 2010
avatar for Vara Vara 898 posts

Topic: Programming / improving game speed

How about designing if for a lower framerate? Most games are 30-60fps.

 
Feb 28, 2010
avatar for Vara Vara 898 posts

Topic: Programming / PHP<->Flash interfacing

http://help.adobe.com/en_US/AS3LCR/Flash_10.0/flash/net/URLRequest.html
http://help.adobe.com/en_US/AS3LCR/Flash_10.0/flash/net/package.html#sendToURL()

 
Feb 27, 2010
avatar for Vara Vara 898 posts

Topic: Kongregate / Full Chat: Another boringly named greasemonkey script from SavageWolf! !UPDATED! After an agonising few minutes, this script is no longer made by SavageWolf, it seems to now have been "adopted" by Ventero, who has improved it! Also, a rant or troll post

This is just self-advertising to get your game a lot of plays.
And if you claim it isn’t, then explain why you have to play your game to activate it.
And if you claim it is because it’s too much work to make a button, you should look up GM_registerMenuCommand.

 
Feb 20, 2010
avatar for Vara Vara 898 posts

Topic: Collaborations / How do I upload a game to this website?

http://www.kongregate.com/accounts/Moly
The games (s)he has entitled “Shootorial” are tutorials for creating games.

 
Feb 20, 2010
avatar for Vara Vara 898 posts

Topic: Collaborations / How do I upload a game to this website?

1. Steal the game;
2. http://www.kongregate.com/games/new;
3. Get hated by every user on this site because the users don’t like thieves;
4. Get your game removed off this site because the admins don’t like stolen stuff;
5. Get a 2-week ban for uploading stolen games;
6. ???
7. Profit!


To be serious: you are only allowed to upload games you’ve made yourself. If you upload something which you haven’t made yourself, then it’s stolen.

 
Feb 20, 2010
avatar for Vara Vara 898 posts

Topic: Programming / Yet another obvious AS 3.0 question! (SOLVED!)

The Game() function (which checks if Global.main equals null) is getting called before the Main() (which defines the Global.main property).

Simple solution:

package {
	import flash.display.Sprite;
	import flash.events.Event; //Also, you're not using this class, so why would you import it?
	
	[SWF(width="800", height="500", backgroundColor="#000000")]
	
	public class Main extends Sprite {
		public var game:Game;
		
		public function Main():void {
			Global.main = this;
			game = new Game();
			stage.addChild(game);
		}
	}
}
 
Feb 19, 2010
avatar for Vara Vara 898 posts

Topic: Programming / AS3.0 Class problem!

Originally posted by jonathanasdf:

bitmaps can have mouse events too…

Anyways, just go with Wordblind’s first suggestion – but change the new embed() to new blank().

Wordblind is right, Bitmaps don’t recieve MouseEvents.
Scheme of class inheritance:

     Object
       |
 EventDispatcher
       |
 DisplayObject
       |
   +---+-----------+
   |               |
Bitmap     InteractiveObject
                   |
          DisplayObjectContainer
                   |
                Sprite

As you see, Bitmap is directly extended from DisplayObject, but Sprite also takes InteractiveObject and DisplayObjectContainer. InteractiveObject dispatches all the MouseEvents and KeyboardEvents.

 
Feb 19, 2010
avatar for Vara Vara 898 posts

Topic: Programming / [AS2] Problem attaching MC in Flash 6

Why are you targetting flash player 6? About 95% of all the internet users has FP10, and and about 99% of the internet users has FP9. There is no reason to target for FP6 at all.

Source: http://www.adobe.com/products/player_census/flashplayer/version_penetration.html

 
Feb 18, 2010
avatar for Vara Vara 898 posts

Topic: Programming / Actionscript Error, help!

5001: The name of package ‘uk.ac.uwe.multimedia.puzzle’ does not reflect the location of this file. Please change the package definition’s name inside this file, or move the file. C:\uk\ac\uwe\multimedia\puzzle\DragGame.as

The solution is written it the error.

 
Feb 16, 2010
avatar for Vara Vara 898 posts

Topic: Kongregate / [suggestion] Easy-Fix for Hacked Highscores

I’m pretty sure the devs can already do this, or they can already delete the highscores.

Developers can’t tell the API a max value, nor they can remove highscores.

Allowing developers to remove highscores (on their own games) would be a great improvement through.

 
Feb 15, 2010
avatar for Vara Vara 898 posts

Topic: Kongregate / [suggestion] Easy-Fix for Hacked Highscores

Hacker’s 5-step plan to success:

1. Figure out the maximum score;
2. Make sure your score is the maximum score;
3. Make sure nobody can ever beat it (even other hackers can’t) because they can’t get a score higher that yours;
4. ???
5. Profit!

 
Feb 14, 2010
avatar for Vara Vara 898 posts

Topic: Programming / addChild, DisplayObjects, and Custom Class

I think you can use the as operator to fix this:

var f:MainMenuBackground = new MainMenuBackground();
var leftBar:MenuSideBar = f.addChild(new MenuSideBar(0 + 6, 50 + 6, 50 - 6, f.height - 15 - 100)) as MenuSideBar;
leftBar.data = { rotX:0 , rotY: -90 };
 
Feb 13, 2010
avatar for Vara Vara 898 posts

Topic: Programming / AS2 Preventing cheating with the mouse?

If you use AS3, this problem gets automatically fixed.
Otherwise, use a hitTest to check if the mouse is hitting the walls.

 
Feb 12, 2010
avatar for Vara Vara 898 posts

Topic: Kongregate / Suggestions

Originally posted by SavageWolf:
Originally posted by Vara:
Originally posted by SavageWolf:



Developers can restrict what levels can play their games if they want using the API

No they can’t

They can retrieve the player’s level, but they have no reason to only let users from level 30+ play their game.

And they can’t send them flying to the main page like the RoS ones.

They can.

 
Feb 12, 2010
avatar for Vara Vara 898 posts

Topic: Kongregate / Suggestions

Originally posted by SavageWolf:

Developers can restrict what levels can play their games if they want using the API

No they can’t

They can retrieve the player’s level, but they have no reason to only let users from level 30+ play their game.

 
Feb 11, 2010
avatar for Vara Vara 898 posts

Topic: Programming / Exclusivity bonus and demo version

I’ve already learned that you are allowed to have demo versions of your flash game on other sites even though you opted for exclusivity bonus here on Kongregate.

No, you aren’t:

To qualify for an additional 15% of your game’s ad revenue, the game cannot be hosted on any website beyond Kongregate.com, with the exception of your own personal site. Games sponsored by Kongregate also qualify for this bonus when they’re uploaded elsewhere.

 
Feb 11, 2010
avatar for Vara Vara 898 posts

Topic: Kongregate / Kred Competitions

1) kreds are always worth 10 cents. No one’s going to buy 10 cents for 20 cents.

Please check out the tarives for when you buy them using zong. (also, kreds become cheaper when buying a lot at the same time)

2) We’ll give 100% of tip revenue back to the developer of your choice, without keeping a dime for ourselves

 
Feb 11, 2010
avatar for Vara Vara 898 posts

Topic: Kongregate / Kred Competitions

Originally posted by nojkimserious:

If a kred is worth $0.10, what’s to stop me buying 110 for $10 and donating them to myself, giving me $1 profit?

There are actually 2 things that block you:

+ The value of the kreds determines on the amount you’ve bought them: if you get 50 kreds for 10$, the value is $0.20, if you get them for 5$, the value is $0.10.

+ Kongregate pays you the full amount that they have recieved for the kreds, that means that you’re not getting the transaction costs back. eg. if you get 50 kreds for 5$ but kong has to pay $1 for the transaction costs, and you donate all 50 kreds, the developer only recives $9.

 
Feb 11, 2010
avatar for Vara Vara 898 posts

Topic: Programming / Is memory management needed for AS?

Flash has a “garbage collector”, which automatically deletes objects you’re not using (like java).

The garbage collection will remove the object if:

+ There are no refferences to the object.
+ The object is not visible on the display list (this has do be done using removeChild(), not by setting visible to false or moving it out of bounds)
+ There are no event listeners attached to it (weak refferenced listeners don’t count)

 
Feb 10, 2010
avatar for Vara Vara 898 posts

Topic: Programming / BitmapData.dispose still necessary?

.dispose() works faster than the gagbage collection. I’ve tried to make a new BitmapData object every frame, and then cleared the reffereces to it when the next was one created, and it ran at about 45 fps (was designed for 60), then I tried calling .dispose when I created a new one, and it ran at 57 fps.

(note that this was in flash 9)

 
Feb 10, 2010
avatar for Vara Vara 898 posts

Topic: Programming / checking vars across classes.

Originally posted by sawdusteater:

You don’t even have to do that, var penetrate defaults to the public namespace.

… If don’t define it, it defaults to internal.

See: http://help.adobe.com/en_US/ActionScript/3.0_ProgrammingAS3/WS5b3ccc516d4fbf351e63e3d118a9b90204-7f9e.html and http://help.adobe.com/en_US/ActionScript/3.0_ProgrammingAS3/WS5b3ccc516d4fbf351e63e3d118a9b90204-7f32.html

 
Feb 10, 2010
avatar for Vara Vara 898 posts

Topic: Programming / Global Variables In AS3?

You can make a variable accesable outside a function by declaring it outside a function. Example:

var a:int;
function b():void {
a = 3;
}
b();
trace(a); //traces 3

You can also make a global object (like _global in AS2) by making an external .as file:

package {
	public var global:Object = {}
}

Save this as global.as in the same map as your .fla and every class can now edit and read properties of the global object. Example:

global.something = 23;
//Somewhere else (eg. in another class)
trace(global.something)