Join us on Discord!
You can help CodeWalrus stay online by donating here.
Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - Scipi

#1
Gaming / Re: Two (obscure) games I like
December 07, 2018, 02:43:03 PM
Quote from: TruDev on December 07, 2018, 03:56:28 AM
Shoutouts to @Scipi for having the protagonist as his avatar

Can confirm, OneShot is a great game :3
#2
Personally, I use GIMP. Though you have to fidget around a little with settings and whatnot. There's also aseprite which you can even get on steam now. That one is purely for pixel art and sprites and has useful tools like layers and animation playback. I've also seen Spriter suggested a lot, but I haven't used it
#3
Other / Re: Politics? Where's your dot? :)
March 22, 2017, 09:42:41 PM
I expected my self to be a bit more authoritative, but I'm not surprised with being left

#4
I once played a game called Aurora and it had a really odd text bug where text was disappearing in tree lists in the GUI. The cause was a VB5 bug with touchscreen drivers that my drawing tablet had triggered.

We had a classic one at work recently. A library we developed was causing some really strange behavior. The application it was developed for would launch and run the library code fine, but would segfault sometime afterwards. We couldn't figure out what it was until one of us noticed we forgot a semicolon after a struct definition and the compiler thought its definition kept going. We didn't even get a warning about it, let alone a compile-time error. <_<
#5
Quote from: PT_ on February 01, 2017, 08:03:02 PM
My intention was that I have no problems with clickbaits (well, not 100% true), but the staff shouldn't make such topics, they are an example for the others
But this is just my opinion, don't mind me if you disagree.

Not everything need be distilled and serious all the time. ;) The core trait that makes CW (and Omnimaga, for that matter) successful is that we're inherently fun-loving and not very rigid. ^_^
#6
There are quite a few hurdles you are going to run into if you want to port scratch programs in this manner. For one, your scratch exe will be in a different type of assembly (x86-64) than what the TI-83/84+ uses (Z80). You will have to end up learning both assembly languages and manually translating between the two, which is not an easy task. Additionally, a lot of the time tools like Scratch will link in their own runtimes into the exe. You will have to either port this stuff over as well, which would require deep knowledge of the calculator's hardware to do. You might as well make a scratch interpreter at that point. Moreover, if there's any optimization or obfuscation, it could become very difficult to understand the code you are trying to port (I speak from direct experience with this, this kind of stuff is my job ;)). It's much easier and much, much more worthwhile to learn Axe, Z80, or C and rewrite the programs with those. I cannot recommend this enough.

If you want to know of some tools to do this kind of stuff anyways to learn or play around with, there are a few really useful tools that I can point you to. Free ones that I know of are:
Ollydbg
x64dbg

These primarily debug a running program so you can reverse via dynamic analysis.

If you have funds, an excellent tool I use for work is IDA Pro. This also comes with the Hexrays decompiler.

There is also Medusa, which is like a free version of IDA. Not sure how good it is, however. These are static analysis tools, though. They don't require the binary to be executing.
#7
PC, Mac & Vintage Computers / Re: C++Builder
November 14, 2016, 08:36:22 PM
Quote from: kotu on November 14, 2016, 05:31:40 PM
Re. potentially non-technical devs, is this what you mean? --->


//---------------------------------------------------------------------------
void TTachGame::ProcessLeftClick(int PlayerID, int SqrX, int SqrY)
{
bool movedOrAttacked = false;
bool didNinjaMove = false;

int enemyID;
if (PlayerID == 0) enemyID = 1;
else enemyID = 0;

if (GetSelectedUnit())  // assume we are trying to move a piece
{
for (DWORD i = 0; i < GetSelectedUnit()->GetNumAvailableMoves(); i++)
{
TTachMove move = GetSelectedUnit()->GetMove(i);

if ((move.ToPosX == SqrX) && (move.ToPosY == SqrY))
{
if (move.MoveType == TMT_STANDARD)
{
// this could be a move or an attack!!

if (move.Attack || FormMain->Cursor == crCross)
{

// we are attacking another piece!! YES!!!

bool queenTeleportAttack = false;

if ((GetSelectedUnit()->GetType() == TUT_QUEEN) && (FormMain->Cursor != crCross))
{
int dx = SqrX - GetSelectedUnit()->GetPosX();
int dy = SqrY - GetSelectedUnit()->GetPosY();
if ((dx <= 1) && (dy <= 1)) {
queenTeleportAttack = false;
}
else {
queenTeleportAttack = true;
}
}

TTachUnit* enemyUnit = m_Players[enemyID].GetUnit(SqrX, SqrY);  //

// check for queen wish attack
if (FormMain->Cursor == crCross)
{
if (enemyUnit) enemyUnit->GetQueenWishAttacked(*GetSelectedUnit(), 2.5f);

TTachUnit* u = m_Players[enemyID].GetUnit(SqrX-1, SqrY);
if (u) u->GetQueenWishAttacked(*GetSelectedUnit(), 2.0f);
u = m_Players[enemyID].GetUnit(SqrX+1, SqrY);
if (u) u->GetQueenWishAttacked(*GetSelectedUnit(), 2.0f);
u = m_Players[enemyID].GetUnit(SqrX, SqrY-1);
if (u) u->GetQueenWishAttacked(*GetSelectedUnit(), 2.0f);
u = m_Players[enemyID].GetUnit(SqrX, SqrY+1);
if (u) u->GetQueenWishAttacked(*GetSelectedUnit(), 2.0f);
u = m_Players[enemyID].GetUnit(SqrX-1, SqrY-1);
if (u) u->GetQueenWishAttacked(*GetSelectedUnit(), 1.0f);
u = m_Players[enemyID].GetUnit(SqrX-1, SqrY+1);
if (u) u->GetQueenWishAttacked(*GetSelectedUnit(), 1.0f);
u = m_Players[enemyID].GetUnit(SqrX+1, SqrY-1);
if (u) u->GetQueenWishAttacked(*GetSelectedUnit(), 1.0f);
u = m_Players[enemyID].GetUnit(SqrX+1, SqrY+1);
if (u) u->GetQueenWishAttacked(*GetSelectedUnit(), 1.0f);
FormMain->Cursor = crDefault;

m_Players[0].PurgeDeadUnits();
m_Players[1].PurgeDeadUnits();
movedOrAttacked = true;
break;
}

if (enemyUnit)
{
if ((enemyUnit->GetType() == TUT_KING) && (GetSelectedUnit()->GetType() == TUT_PAWN))     // check for single move checkmate
{                                                                                         //  ] END OF GAME [
FormMain->DeclareEndOfGame(false, GetCurrentPlayer()->GetName());
movedOrAttacked = true;
break;
}
else if (queenTeleportAttack) {                      // check for queen teleport attack
enemyUnit->GetTeleportAttacked(*GetSelectedUnit());
}
else {                                              // check for all other TMT_STANDARD attacks
enemyUnit->GetAttacked(*GetSelectedUnit());   // this is where most of the attacks happen
}

if (m_NumNinjaMoves > 0) {
m_NumNinjaMoves--;
didNinjaMove = true;
}

m_Players[0].PurgeDeadUnits();
m_Players[1].PurgeDeadUnits();
movedOrAttacked = true;
break;
}
}
else
{
/// this is just a move.

GetSelectedUnit()->MoveToPos(SqrX, SqrY, this);
if (m_NumNinjaMoves > 0) {
m_NumNinjaMoves--;
didNinjaMove = true;
}
movedOrAttacked = true;
break;
}
}
else if (move.MoveType == TMT_BOMB)
{
// bomb the square
//...

TTachUnit* enemyUnit = m_Players[enemyID].GetUnit(SqrX, SqrY);

if (enemyUnit)
{
enemyUnit->GetBombed();
m_Players[enemyID].PurgeDeadUnits();
}
FormMain->BombNoise();
movedOrAttacked = true;
break;
}
}
}
}

if (movedOrAttacked == false)  // assume we are trying to select something else
{
if (m_NumNinjaMoves == 0) {
SelectUnit(SqrX, SqrY);
}
}

//-----------------------------------------------------

// CHECK FOR THE OTHER END OF GAME STATES  (THERE IS ONE ABOVE) //

// check for dead king

if (m_Players[enemyID].KingIsDead()) {
FormMain->DeclareEndOfGame(false, GetCurrentPlayer()->GetName());
}

// check for K vs K draw

if (m_Players[0].OnlyKingIsLeft() && m_Players[1].OnlyKingIsLeft()) {
FormMain->DeclareEndOfGame(true, "");
}

// check for KQ vs K win

if (m_Players[0].OnlyKingIsLeft() && m_Players[1].OnlyKingAndQueenAreLeft()) {
FormMain->DeclareEndOfGame(false, m_Players[1].GetName());
}
else if (m_Players[1].OnlyKingIsLeft() && m_Players[0].OnlyKingAndQueenAreLeft()) {
FormMain->DeclareEndOfGame(false, m_Players[0].GetName());
}

//-----------------------------------------------------
// hand control to next player
if (movedOrAttacked)
{
if (didNinjaMove && m_NumNinjaMoves > 0)
{
if (FormMain->Menu_BlackBoxEnabled->Checked) {
FormMain->SaveBlackboxData();
}
}

// SEND GAME TO OTHER PC (NETWORK) HERE

RandomlyAddPowerup();
IncrementNumMoves();
FormMain->SendMove();


//----
if (m_NumNinjaMoves == 0)
{
HandControlToNextPlayer();
//FormMain->SendNextPlayer();
}
}
}
//---------------------------------------------------------------------------


(don't)

That looks more the code of a naive or inexperienced dev rather than a nontechnical one. ;)

A nontechnical dev would be more along the lines of someone who has little to no knowledge of hardware and memory. They aren't able to do things like specify struct alignments, custom allocators, inline asm, specifying calling conventions, and all the other things C/C++ gives you control over. They're more along the lines of artists where they know in manipulating control flow and tweaking values to get things to look and feel the way they want.
#8
PC, Mac & Vintage Computers / Re: C++Builder
November 14, 2016, 08:19:25 PM
Quote from: kotu on November 14, 2016, 05:31:40 PM
Quote from: Scipi on November 14, 2016, 04:09:25 PM
I hold that C++ builder is rather pointless.

6

*edit*
trying to edit this post, can't.  :thumbsup:


Did you think that the power / speed of C++ was somehow degraded by it having a visual form designer or something

:-|

Not necessarily, just that when you have compiler generated code like that you lose a lot of information and control over how your program is running and the state of the system. These are things you generally want to know about when using C++ at a low-mid level. And if you don't need to work at that level, why are you using C++? A gui builder is more in the domain of designers anyways. And C++ is not at all a design language.

Really, it's a better paradigm to use a 3rd party library for your gui stuff if you need a C++ powered gui system.

1. You retain control over your main. Which means you retain control over the entire scope in which your program operates.
2. You dictate the scope in which the gui system operates, not the other way around. So you want the gui to only operate for a certain time slice? Go for it. You want to determine when in your program the gui runs? You can do that. Want to have a say over the gui working in a single thread or in multiple threads? Totally within your power.
3. You're not locked into one gui system. If a gui library doesn't have a feature you really need, you can switch out to another one. C++ Builder locks you into their system (and if you choose not to use it, what's the point of C++ Builder anyways?)
4. You have the option to offload the gui system to a scripting language more suited to the task, like python or lua. That way your non-tech designers can work with design-friendly languages while your tech engineers support them with C++ engine stuff. Example of this workflow: Unreal Engine.
5. You're not limited in how you want to architect your code.
#9
PC, Mac & Vintage Computers / Re: C++Builder
November 14, 2016, 04:09:25 PM
I hold that C++ builder is rather pointless. If you need rapid development with tools for potentially non-technical devs, you shouldn't be using C++. If you need precise power and low level memory access/optimizations you shouldn't be using a builder. Both halves of the tool are fine on their own, but there's really no use case for having both.
#10
The only silver lining with Pence is that officially the VP's role is only to resolve tie-breakers in the Senate. But if anything happens to Trump, it'll be Pence who we get as President.
#11
Quote from: p2 on November 10, 2016, 10:15:33 AM
it has begun...



But also:
Quote from: Putin"Russia is ready and wants to restore the full fledged relations to the United States. I repeat: we understand that this will be a difficult way but we are ready to play our part in it."

It's tragic, though I'm not surprised with the sheer emotional charging and fear mongering that went on with this campaign. What's worst is it seems the LGBT community doesn't have a whole lot to fear from Trump himself. On election night, his policies on LGBT rights (as well as Planned Parenthood) were removed. The Republican controlled house and senate might try something, but Trump seems unconcerned either way on the issue. At least on an official basis.
#12
Quote from: DJ Omnimaga on November 09, 2016, 04:57:54 PM
so hopefully he won't turn Canada and Europe into a dumping ground for deported Americans

That would be amazing, though. I'd let myself be deported at that point :P

QuoteSpoiler: Hillary Clinton crying

Clinton crying would imply she has a soul.

Jokes aside, I really am rather worried. Not really about Trump, but what people will do. I'm also worried about Pence.
#13
You don't call the KeyListener functions yourself, instead you register them with your canvas and they get called for you by the system when certain things happen.
Adding it looks something like this:

//...
frame.addKeyListener(keyControls);
//...
#14
Tbh, I really dislike how Java handles it's inputs. Asynchronous input handling means that program state could change at any point in the frame unpredictably.

Also, granted this is supposed to be a simple implementation, it won't work very well when gui's are thrown into the mix (because gui's should get priority handling of events and should be able to "consume" them to stop the event from propagating). I mention this only because it's the exact issue that stopped my progress on Walriimon ;)

I've been trying to find the time to put together a small demo of this for a while now, actually.
#15
Drawing & Animation / Re: Walrii fanart
October 24, 2016, 10:11:42 PM
Happy Birthday CW :3

Powered by EzPortal