Giter VIP home page Giter VIP logo

d2d2s's Introduction

Profile Views counter My GitHub stats Top Languages
Ping me on Discord!

What am I working on

Hi!
My name is Maciej. I'm a student on the Akademia Górniczo-Hutnicza university.

The most important things I'm currently working on:

  • giu development. GIU is a nice golang framework - wrapper of cimgui-go that is Dear ImGUI's implementation in golang.
  • cimgui-go is also one of projects I'm working with. This binding is auto-generated, so its extremely easy to keep up with the newest code from Dear ImGui. Unfortunatley generator's code still needs improvements.
  • If you're a High-School student from Poland, I'd also want to check out my website with physics exercises. Let me know what do you think about it! Also, if you're interessted in re-activating the website or contributing to it, post In a discussion here!
  • Recently I've also added a chapter for my collage course on the previously mentioned website.
  • I'v ealso launched a new website for advanced math course. See here.

d2d2s's People

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

garfield-chen

d2d2s's Issues

`d2sdifficulty`: add some api?

d2sdifficulty.Difficulty is a map-type. So I store pointer to it in main D2S structure, but the problem is, that reffering to a pointer-map is a bit... strange. it looks like `(*p.d2s.Difficulty)[d2enum.DifficultyNormal]. I suggest to add some api for this stuff or reduce this noise in some other way

possibility to create completely new data files which works with d2.

Currently, when we do:
ioutil.WriteFile("testchar.d2s", New().SetName("testchar").Encode(), 0o644)

full code here
package main

import (
	"io/ioutil"

	"github.com/gucio321/d2d2s/pkg/d2s"
)

func main() {
	data, _ := d2s.New().SetName("testchar").Encode()
	ioutil.WriteFile("testchar.d2s", data, 0o644)
}

we'll get
image

Test template

Hi there, I'd like to describe used in a project tests template.
each _test.go file should look as follows:

  1. testdata() map[*TestedType]binaryFormat method.
    this method should specify as much, as possible/necessary test cases in described map form
  2. Test_Load(t *testing.T) this method is really easy
// declare testdata
td := testdata()

// testing loop
for key, value := range td {
    // load tested structure using data (value) given
    // in some cases, it could be necessary to create bitmuncher (datautils.CreateBitMuncher(value, 0) ) and pass it as an argument to load
    s := New()
    s.Load(value)

    // then just use `assert` to check results
    assert.Equal(t, key, s, "unexpected structure loaded")
}
  1. Test_Encode(t *testing.T) is also really simple
td := testdata()
for key, value := range td {
    // encode tested structure into binary form (value)
    data := key.Encode()

    // use assert to detect differences
    assert.Equal(t, value, data, "unexpected data encoded")
}

data reader/writer

OpenDiablo2/OpenDiablo2 dependency is a wrong idea. there are 2 alternatives:

  • use internal data reader (internal/datautils)
  • use OpenDiablo2/bitstream

d2sstats: fix data size

For now, all data in Stats structure are uint64s or float64s
I think, that it could be something smaller

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.