« first day (2365 days earlier)      last day (2645 days later) » 

 
2 hours later…
2:36 AM
@Ali.S bool is a bit of a "magic" type. You have to be careful with it

int i=2;
if(i) printf("true"); else printf("false"); // true
if(i == true) if(i) printf("true"); else printf("false"); // false
if(!i) printf("true"); else printf("false"); // false
if(!i == false) printf("true"); else printf("false"); // true
@Ali.S any value that is non-zero evaluates to true when cast to bool, but any value that is non-zero is not necessarily equal to true as true translates to 1 numerically.
if((bool)i == true) if(i) printf("true"); else printf("false"); // true
 
 
3 hours later…
5:55 AM
0
Q: I need to do the following in monogame

EminemI need to do the following using monogame. Image link I know how to move the sprite up and down but I'm a bit lost on how to do the trailing part. If someone could point me in the right direction I would really appreciate it

 
6:07 AM
0
Q: Sphere UV mapping. Texture Streched

Martin KuhnI am trying to write a sphere mesh algorithm. Unfortunately, is the texture stretched vertically at the very end of the image. This should be near U 0.99~. Below is the code used for the sphere creation. In the Image below that you can see a sphere created by Maya with the correct textures appli...

 
6:20 AM
0
Q: Second Animation is not working after Collision?

user44356I want to show an accident of Character with car. so I wrote this code and in update function I wrote this... if (Once) { Criminal.GetComponent<Animation> ().Play ("Running"); // after collision This animation will work Criminal.GetComponent<B...

 
7:13 AM
0
Q: Circular lighting mask stretches to ellipse in Monogame using Pixel Shader

RagnoroctI am trying to implement a very simple pixel shader for some basic lighting using this tutorial http://www.xnahub.com/simple-2d-lighting-system-in-c-and-monogame/ My problem is that when the effect is applied the circular gradient ends up looking like an ellipse(left) instead of its circular sha...

 
 
1 hour later…
8:31 AM
0
Q: How to Refresh Dependencies after Adding FreeType Extension in Android Project

JAlmazanI'm planning to use FreeType fonts in my game (LibGDX and Android Studio) and I already added the freetype dependencies in my project. How can I refresh the dependencies after adding them? I have found few similar questions regarding this topic but didn't offer much help. Here is an image of the ...

 
@JoshPetrie so all in all what yahoo wanted to do was a terrible idea =p
 
 
1 hour later…
9:58 AM
0
Q: Game Over script

hassanhello i need a script in c# for game over when timer==0 timer script: using UnityEngine; using System.Collections; using UnityEngine.UI; public class Timer : MonoBehaviour { public int timeLeft = 5; public Text countdownText; // Use this for initialization void Start() { StartCoro...

0
Q: How to get objects using layre name?

Darshan SoniI Create Game FPS Shooter in local multiplayer. which one player create the hot-spot and other one connect that WiFi network and Play the Game.My Question is i want to get all players objects in network who has same layer name and store into array when the player spawn in network that object is a...

 
10:10 AM
0
Q: Camera type for puzzle game like tetris

Gaëtan BrochardI can't find what is the name of the camera type. Sided camera view seems logical but not correct thought

 
 
1 hour later…
user92578
11:36 AM
fml I need to make a phone call :(
 
DH.
And why it's bad?
 
user92578
I hate calling places, it makes me suuuper anxious
 
DH.
lol I was like that too, when I was younger
 
user92578
I also have this with emails but luckily that's not as bad
 
I was like that too, until I realized that they did not know it, and that they ultimately would not remember me at the end of their shift. Plus the added carelessness that if they'really not happy, fuck them, their problem!
 
user92578
11:48 AM
Yeah that's a good point
 
if they are not*
I noticed that self confidence is a thing that built up, I was not born with it... and I'm still working on it :p
 
user92578
self confidence isn't definitely my strength and the whole impostor syndrome thing going on in game dev definitely isn't helping :)
 
12:22 PM
@Tyyppi_77 Ah, yeah, that thing :P Yeah, gotta work to get rid of it, but it's doable :)
 
user92578
the system is fucking idiotic
 
user92578
I went for a physical for draftings in the autumn
 
user92578
Now I'm applying to a special force and apparently I need to go get another physical which is exactly the same form
 
@Tyyppi_77 phonecalls are the worst :(
 
user92578
the dude was like "it obviously says this on the form"
 
user92578
12:32 PM
no it doesn't
 
Nice bureaucracy...
 
user92578
yup
 
user92578
This is partly my fault; had I started filling the form out earlier I could've gotten a time from the school doctor and she could've written me one
 
DH.
You need to fill those forms to avoid being enlisted?
 
user92578
No I'm applying for an electrical warfare group
 
user92578
12:44 PM
(which doesn't have an email address btw)
 
Is that the one with the car batteries and the leads? =p
 
user92578
lol I don't think so (it's pretty secret stuff I believe) I think it's more like blocking radio signals or something
 
user92578
maybe even some kind of hacking
 
user92578
they want academic people and interests in electronics, computers or foreign languages are plusses
 
DH.
You better finish GunHero before going there >:c
 
user92578
12:46 PM
yup, that's the idea
 
1:07 PM
for i in *.html; do pandoc -s -r html $i -t dokuwiki> $i.txt; done
for i in *.html.txt; do VAR=`cat $i | grep -m 1 ====== | tr -d -c "[:alnum:] " | tr [:upper:] [:lower:] | tr " " "_"`; mv $i ${i/_+([0123456789]).html.txt/}${VAR//__/}.txt; done
so yeah, that's how you convert Confluence wiki to dokuwiki
had to use two hours to figure that out
well, the conversion part is the first line, the second one is getting the file name right and readable for the dokuwiki
that actually could be made into oneliner but why bother
 
Goddamn power out for 13 houts
I'm. Bored.
 
user92578
wow that's a long time
 
The hell peiple used to do back in the day
 
@jgallant play fart games
 
Beat up their wives and get drunk
 
1:15 PM
Yeah, flip the order, though, get drunk first, then beat up their wives..
 
Never get sober.
 
1:59 PM
0
Q: How to modify a property after animating it?

Ziya JafarovI animate localPosition. The animation works well, but then I can't change its value in editor or code. I use Animator with AnimationClipPlayable. The animation animates a property from one position to another. I don't stop the animation. Let me know, if you need a code example or video presen...

 
2:30 PM
0
Q: How can I learn to program UE4 to recognize set shapes?

DeygusI'm currently developing an indie game using Unreal Engine 4 and I've stopped developing it within the last week because I have hit a massive roadblock.. What I am attempting to do is create a grid-based block system that can recognize set shapes within a specified crafting area which is a 5x5x5...

0
Q: Unity projects and building

Joza100I've made my first game in Unity! I want to put it on MediaFire, but I'm not sure do i upload a whole project, which is 300 MBs or just a certain part that is enough for someone to open it!

 
3:29 PM
0
Q: Unity- Place buildings on a terrain

user6918687What I have: 1- A terrain made using unity's terrain tool ( it is flat ) 2- 3d models ( my buildings ) What I want to achieve: The only thing I want is someone to help me how to place/snap my buildings to the terrain and check whether the location is valid (green color if valid) or not (red c...

 
3:41 PM
0
Q: Cocosdenshion and Android not working

Victor Jose Banquez MedranoI'm trying to play sounds and music with cocos2d. When I run on iPhone and .caf files the audio is perfect, but on Android it is not playing the background music and is only playing 2 sounds of 10 files. I don't know what I'm doing wrong. #include <SimpleAudioEngine.h> bool HelloWorld::init() { ...

0
Q: Multiplayer architecture of shooter games

Andrea CataniaI've a doubt about synchronization on multiplayer games. In the case of the architecture of a game is like this: Client tells to the server is shooting at this position, then the server simulates the same movement then tells to client if the enemy was hit or not. I think in this type of archite...

 
4:21 PM
Phone power critical
They need to turn the power back on soon or I'm gonna die
 
Go to a coffee place and charge it? =p
 
4:49 PM
@KevinvanderVelden this is right ? also do i want to write each byte or store into array and then write whole array i mean write calls might be expensive ?
void Write(std::vector<bool>& map)
{
	std::ofstream fout("test.bin", std::ios::binary);
	for (size_t i = 0; i < map.size()/8; i++)
	{
		char byte = 0;
		for (int id = 0; id < 8; id++)
		{
			byte << id;
			byte = map[i + id] ? 1 : 0;
		}
		fout.write((char*)byte, sizeof(byte));
	}
	//fout.write(buffer, map.size());
	fout.close();
}
 
user4704
Writes to disk are expensive, but the stream usually buffers. And the OS also buffers. And the disk controller.
 
user4704
So you will rarely actually write a single byte at a time
 
user4704
byte << id; does nothing
 
u mean its a buffer untill i close it right ?
 
user4704
Usually, yes
 
user4704
4:53 PM
Did you mean byte <<= id; ?
 
user4704
(That actually doesn't make sense either since you just assign byte below)
 
hmm how to do this then ?
 
user4704
I'm not sure what you are trying to do.
 
user4704
"(char*)byte" is also wrong
 
user4704
write wants the address of the data to write; you should pass fout.write(&byte, sizeof(byte));
 
4:54 PM
i am strying to bitshit std::vector<bool> into unsigned chars and write to binary fil
 
hahah great typo
 
user4704
So you have an array of bools and you want to write them to a file?
 
yes
i have vector of bools
map is std::vector<bool>
 
user4704
One byte per bool?
 
hmm one guy was say this is the safest way to do , but its expensive in memory
 
user4704
4:56 PM
I mean in the file.
 
user4704
Do you want the file to contain one byte per boolean value?
 
user4704
Or do you want to try to pack the boolean values into bytes, eight booleans per byte?
 
1 byte 8 bools to contain
second option
1:1 is easy
 
Will you have a lot of bools?
 
700*800
 
user4704
4:57 PM
Well you have the right general idea but that inner loop is very wrong.
 
56k i think
 
user4704
That inner loop is basically making you write every 8th bit as a byte, ignoring all the others.
 
if i do 1:1 i got 560kb
 
That's a lot of bools, that's worth packing them 8 per byte!
 
user4704
You should probably review your bitwise math and operators.
 
4:59 PM
Josh first loop takes map.size() /8 so i add i + id witch is good ?
or no maybe not i messed up
 
@yahoo5000 Nice use of the fixed font feature, by the way :)
 
thank you :D
@JoshPetrie this gives me error fout.write(&byte, sizeof(byte)); unsigned char* doesnt mach with const char*
 
5:14 PM
@JoshPetrie tell me that i am right this time and everything awesome
void Write(std::vector<bool>& map)
{
	std::ofstream fout("test.bin", std::ios::binary);
	char byte = 0;
	int byte_index = 0;
	for (size_t i = 0; i < map.size(); i++)
	{

		byte = (map[i] << byte_index);
		if (byte_index > 8)
		{
			byte_index = 0;
			fout.write(&byte, sizeof(byte));
		}
		byte_index++;
	}
	//fout.write(buffer, map.size());
	fout.close();
}
 
@JoshPetrie Would this question be reopened if it were formulated more as "Assuming I have a game, what would be the steps to get it published/sold on the xbox one market", removing the concepts of costs?
 
user4704
5:36 PM
@yahoo5000 No.
 
user4704
Better, but not correct.
 
user4704
@AlexandreVaillancourt Probably.
 
@yahoo5000 Do you try your code?
 
I hear a harddrive crying somewhere
 
user4704
@AlexandreVaillancourt I mean I, for one, have no idea what he's originally trying to ask.
 
user4704
5:43 PM
And I feel like without heavy editing that question is doomed.
 
user4704
So go for it.
 
user4704
@yahoo5000 How many bits in a C++ byte?
 
I feel like he's trying to find out how much he'll need to spend to have his game sold on the XBOX One market... And I don't think asking for a price will ever make a good question here because prices change all the time..
 
user4704
Yes.
 
user4704
And it's not like the price of getting, say, an Apple developer account ($99/year).
 
user4704
5:46 PM
It's not a fixed cost, you don't just buy your way into to publishing on the Xbox.
 
user4704
shrug
 
user4704
(even if it was, I question the on-topic'ness of assembling a set of questions about "what's this cost")
 
0
Q: 2D HUD overlay drawing based on 3D coordinates and camera azimuth and elevation

Christian IvicevicAssume you have the 3d coordinates of the player and another unit N as well as the azimuth and elevation of a camera always looking at the player. In the following illustration the sun would be the camera of course: Let's say one wants to draw something on a different transparent window (not u...

 
6:02 PM
@JoshPetrie thats dump question 1 byte 8 bits i changed edited that btw :D
 
That guy has the same avatar as Nicol Bolas...
 
@JoshPetrie probably thats why i got negative rate on all my questions on stackoverflow :D
 
0
Q: Add object to a Terrain?

user43474It's possible to add object made by blender to unity terrain ? this object will become a part of it. I can add grass and trees on it.

0
Q: Error suddenly when compiling Desktop on Android Studio - all projects - nothing changed - LibGDX

Super MegaBroBroI have just gone into Android Studio to open a project. It will run in Android but not my Desktop configuration. Nothing of the code has been changed and I have now tried 3 projects, also a brand new project straight from the LibGDX Project Generator .jar file. The error I get in Studio is: Exc...

0
Q: Browsergaming is a bygone era or a good browser game should live today?

FeralheartI thought about creating a turn based rpg, like what Greendragon was. Or a "you have 10 action points right now, what you can use for this and this and you fill up one action point per hour". Or a simulation game like Hattrick. (I don't want to copy these games. I only wanted to show a similar ga...

0
Q: Is my quaternion-based free camera correct?

ajcI'm going to be learning skeletal animation soon and thought it'd be easier to learn quaternions by modifying my camera class as the results can be seen quickly. There is a ton of information out there for quaternion-based cameras, but a lot of it is lacking or missing the point (ie. using Euler ...

 
That should work for sure right :D
void Write(std::vector<bool>& map)
{
	std::ofstream fout("test.bin", std::ios::binary);
	char byte = 0;
	int byte_index = 0;
	for (size_t i = 0; i < map.size(); i++)
	{
		if (map[i])
		{
			byte |= (1 << byte_index);
		}
		byte_index++;
		if (byte_index > 7)
		{
			byte_index = 0;
			fout.write(&byte, sizeof(byte));
		}
	}
	fout.close();
}
but thats actually are wrong i mean i writing them opposite direction [<- ][<-] all bytes should go -> direction right ?
cuz now its like [7,6,5,4,3,2,1,0][15,14,13,12,11,10,9,8]
i mean index
 
user4704
6:24 PM
@yahoo5000 No.
 
user4704
There are CHAR_BIT bits.
 
user4704
@yahoo5000 The lowest-order bit is on the right.
 
user4704
Not the left.
 
user4704
So the 7th bit will be written into the highest-order bit of your first byte.
 
user4704
(with the code you provided)
 
user4704
6:28 PM
You can make it go the other way if you want, but that would be unusual.
 
6:40 PM
And this is my first post here..I didn't ask that question yesterday — user6918687 21 mins ago
I'm not sure he knows how the site works.. ;P
 
6:51 PM
0
Q: How to link a camera to an object and have it rotate along?

ByrkI have an object that I would like to rotate along with the camera, however, it lays flat and does a weird roll along the y-axis. I set an object's (entity) orientation as follows: void Orient(glm::vec3 const& vec, glm::vec3 const& up) { m_TransformRotation = glm::orientation(vec, up); } ...

 
Unity 5.5.1 came out.
 
yes but example std::vector<bool> = 12345678; and if i push them into char it would be 87654321
and if my vector would have like 1234567812345678 then it would be
87654321 87654321
and if i read again back to vector it will be std::vector<bool> = 8765432187654321
so its opposite
 
7:08 PM
0
Q: Character animation with Directx11/12 Book

Pino I don't know if I can ask this question here but I don't know where else to ask. Can you suggest me a book for the character animation using DirectX11/12? Thank you

 
user4704
@yahoo5000 No.
 
user4704
You can't read them back directly into the vector.
 
user4704
You have to read each byte, extract the bits from the bytes in a loop, and push those into the vector.
 
user4704
If you do that they end up back in the vector in "12345678" order.
 
even with insert ?
 
user4704
7:11 PM
You should not use insert() here.
 
so the same shit with reading write ? cuz i have just tested and writing is ok
 
user4704
Yes.
 
okay tnx a low Josh
 
user4704
And writing the bits in that order that you're already doing is easier, and more clear.
 
user4704
So don't try to "reverse" them; it will not go well and it's pointless.
 
7:13 PM
i havent yet and wont because i will still need to read them same way so everything should by fine
 
@yahoo5000 You can always implement your own bitset that allows for adding bytes
 
i thats hard ? isnt it ?
 
Not really
Hardest would probably be relocating the memory in an effecient way, but it seems you know how much space you need
 
7:30 PM
i will stick with this basic for now cuz want to go more into game development
 
This is why I never finish a game
@yahoo5000 What kind of game are you making?
 
Online Strategy
i probably wont finish it cuz there is so many thing i want to do :D
 
I have a list of projects I want to do sometime. The list is getting fairly large actually while I finish the game I've been working on for a year.
 
i have everything in my head and once doing something get more and more ideas , but now trying to minimize them and make basic game witch i by able to improve later
 
7:38 PM
I helped clear my mind by putting them on a Trello board, along with a few key points about them.
Every now and then I'll add/tweak a point, but...
 
Pip
o/
 
Pip
sup Hjor
long time no see
 
Indeed
Been busy, not much time for gamedev :D
 
std::vector<bool> Read()
{
	std::vector<bool> map;
	std::ifstream fin("test.bin", std::ios::binary);
	int size = 8 / 8.0f;
	map.resize(size);
	char * buffer = new char[size];
	fin.read(buffer, size);
	fin.close();
	int byte_index = 0;
	int vecIndex = 0;
	bool val = false;
	for (int i = 0; i < size; i++)
	{
		for (int id = 0; id < 8; id++)
		{
			val = (buffer[i] << id) ? 1 : 0;
			map[i * 8 + id] = val;// iterator not dereferencable
		}
	}
	delete[] buffer;
	return map;
}
why iterator not dereferencable ?
 
Pip
7:43 PM
yeah, same here. I haven't been popping in much recently
ayy I'm still on the frequently in room list though
after Jon and Almo
 
so i have to emplace_back ?
 
push_back is fine as well
 
map.emplace_back((buffer[i] << id) ? 1 : 0)
 
Sure
 
7:52 PM
still fucked up something
atleast i know that write works 100%
 
0
Q: Input handling LibGDX - why doesnt a combined class exist?

Super MegaBroBroI was just reading this question: LibGDX: Is it necessary to set a stage as an input processor when creating a touchpad? It got me wondering why there isnt a class in LibGDX already created, lets say called CombinedInputProcessor, which would extend both InputProcessor and GestureListener and C...

 
@yahoo5000 You have opened the file with a binary editor?
(hex editor?)
 
yea
its ok
first mistake is here map.resize(size); it should be map.resize(size*8);
that changes nothing anyway
 
My coder just turned in our first AI build last night. Not so smart, but still quite fun to play against.
Looks like we're actually going to have a decent product out in the next month or so!
 
ok i dont even need resize cuz i am using emplace_back
anyway read data is wrong
i get 11111
read data is ok hmm...
 
8:01 PM
How are you printing the data?
 
for (unsigned int i = 0; i < map.size(); i++)
	{
		std::cout << map[i] << " ";
	}
 
If anyone wants to get on the beta list, let me know. (It's a simple, turn-based strategy game about territory control.) "Minutes to learn, a lifetime to master."
 
@yahoo5000 try to cast map[i] to bool
 
when cout or when emplace_back ?
 
8:05 PM
cout
 
same
 
Okay
 
i mean cout method doesn't matter cuz i have checked in debugger and whole vector true
could it be something with char* ?
i tried to dereference but cant do that
 
0
Q: SDL: Trouble targetting window from inside of another class

user96855I'm a beginner to SDL and also pretty new to C++ in general, so please go easy on me. Below is a very basic game loop I've been working. I have no errors when compiling, however my grass texture in menustate.h is not rendering (the window is white), I believe this is because my renderer is strug...

 
8:27 PM
0
Q: Does my conditional statement contain a syntax error? C++

RobbyI am not entirely new to coding, but I am new to C++. I receive the error below often, but find that it comes due to some sort of syntax error (using a minus sign instead of an equal sign, or misspelling a variable name I've already declared elsewhere), but I can't seem to find what's wrong with ...

 
Could one of the mathy guys from you check my answer for errors?
0
A: Slime Volleyball Physics Implementation

BálintBasically, you want to implement circle-cirle collision detection and response. I consider your character a static object and the ball a dynamic object. I do this because it makes everything a lot easier, and the character doesn't move too much anyways. First, your ball should have a velocity ve...

 
i can only vote up :D
 
0
Q: How many programmers do I need for a 2D game?

Daniel EngelI am asking this question just for reaserch. Lets say I have a good plot and a already drawed in my mind how its going to look like (2D), what is the most minimum number of programmers I need to create this game? (sorry if the question is not detailed enough)

 
@Bálint IS IT GOOD QUESTION ?
 
The I should be uppercase
 
8:42 PM
yea but content :D
 
The content part is good
 
do i need to add something more ?
 
Does this go to SO?
 
SO ?
yea
if u mean StackOverflow
 
No, that explains everything, if you want to be really fancy, put an ideone link
 
8:44 PM
i dont want to by fancy i just want write question that i wont get down voted :D
 
That shouldn't get downvoted
Maybe if it's a trivial error, but I'm no C++ expert, so I can't check that for you
 
np tnx
i have stackoverflow :D
 
0
Q: CapsuleCollider

Matt BaechSo i have a problem checking if my character is grounded, and it is tied to the position of the capsule collider, I just started unity so I'm not sure what I did wrong. The problem is that the spherecast returns false, like it didn't hit anything. Here are some images of my character/capsuleColl...

 
 
1 hour later…
10:17 PM
0
Q: Problem calculating screen point for a point in a 3D world with view matrix and projection matrix

Steffen BremI am trying to calculate the 2D screen point of a 3D world position. For this I use the multiplication ViewMatrix * ProjectionMatrix. But I am not getting good results and I think I am messing up my calculations or my ViewMatrix itself is wrong (I think the latter). This is a snapshot of how my ...

 
 
1 hour later…
11:39 PM
0
Q: Does anyone know how to add JSON object into your whitestorm world?

AryehI am loading the object from my json file. var loader = new THREE.ObjectLoader(); loader.load("blue-car.json", function ( car ) { car.position.set(2, 0, 0); car.addTo(world); } ); How can I add the object to my world? In regular three.js it works when I load the json file, but how do I ...

 

« first day (2365 days earlier)      last day (2645 days later) »