HeroEngine Forums
Welcome, Guest. Please login or Register for HeroCloud Account.

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.

Messages - EO-CaSpivey

Pages: [1] 2
1
HJRef is a good place to look, however it can be overwhelming as there are some seriously high level scripts in there.  I will keep an eye out for tutorials but if you haven't already I would watch the HSL For Programmers video series on YouTube. The go over HeroScript in great detail and can be very helpful as a reference.

2
Hmm, Im fairly certain the HJRef Chat uses some kind of auto-scroll. That may point you in the right direction.

3
I am confused as to how this is working....This is what I used to test.

Code: [Select]
val as Float  = 18.0 / 10.0
println("Floating Point Test: "+ val )
valString as String = FormatFloat(val , 2)
println("Floating Point Test String: "+ valString )
val2 as Float = stof(valString)
println("Floating Point Test After Conversion: "+ val2 )

And this is what was returned:

[hsl_debug] 4611686018427637930,3: SCRIPT[skippy]: Floating Point Test: 1.799999952
[hsl_debug] 4611686018427637930,3: SCRIPT[skippy]: Floating Point Test String: 1.80
[hsl_debug] 4611686018427637930,3: SCRIPT[skippy]: Floating Point Test After Conversion: 1.799999952

How is it getting the 1.799999952 from the string 1.80?

This is not really an issue for me, i am just confused as to how it happened.

Thanks,
Charles

4
Scripting & Programming / Re: Mini Map problem
« on: Mar 26, 13, 01:48:46 PM »
I have not done this tutorial myself but it appears in Thazager's orignal post, he uses the method HE_onRenderMiniMap() im fairly certain because this method is defined in the engine script it must be called via HE_

5
I tried all the methods I know off and all ended up with the same result, it would seem that HeroEngine's auto conversion is causing a bit of grief here....it looks like they will have to add an external function for this in the C++ source as HSL does not have this functionality and the auto conversion makes it impossible to do manually.

Sorry =(

6
This is very possible in HeroEngine, however it will require serious code modification over the basic skill system present, most of which would be very specific to your game. Therefore we can not really give you code to start with because it really depends on how you want to build it. HSL is not difficult to learn, however before tackling a large system like skills I would recommend you go through some of the basic and intermediate level tutorials to learn the basics of HeroEngine.

I recommend these tutorials to start:
http://hewiki.heroengine.com/wiki/How_to_write_a_script
http://hewiki.heroengine.com/wiki/Creating_server_scripts
http://hewiki.heroengine.com/wiki/Your_First_HSL_Script

Then move on to the more advanced:
https://community.heroengine.com/forums/index.php/topic,1895.0.html

Thats all my recommendations for learning the basics the advanced will come with time but I would recommend looking at the rest of the Wiki tutorials as well as the developer created tutorials here on the forums:
https://community.heroengine.com/forums/index.php/board,17.0.html

Given the nature of HeroEngine's flexibility unless you already have base code it will be difficult for anyone to help you as everyone's systems are different. Anyway that's just a few pointers hope it helps. Sorry I could not be more specific to your problem.

7
Scripting & Programming / Re: DOM copy to server
« on: Mar 12, 13, 01:47:29 PM »
Check to make sure that there is not already a class on server with that name, and also try removing a re-adding the class if you have not already. I have not seen an error like that before but generally 0 errors occur when nothing is returned (meaning it couldn't find the client DOM to copy). Thats my guess anyway, having never encountered the error myself.

8
It is, I defined a class EO_ClickLootBox, in which the InputMouseEvent shared function is defined, however the method launches the GUI. Here is the Exact code I currently Have, which does not work as it still says that the method does not exist. Is there a better way to do this?


Code: [Select]
shared function InputMouseEvent(args references Class _MouseEvent)
// Mouse event generated from the _InputHandlerClassMethods Script assuming it
//   has not been overridden by a game specific implementation.
//
 
  // Get the Node For which the Event was Generated
  target as NodeRef = args.MouseTarget
  thisScript as NodeRef of Class EO_ClickLootBox
 
 
  lootBox as NodeRef of Class GUIControl = CreateNodeFromPrototype("EO_LootBox")
  var isOpen = false
 
  // Type Cast the node so we can access its fields/properties
  where target is kindof HBNode
    when args.MouseEventType
      is Click
        thisScript.OpenLootBox()
      .
    .
  .
.

Method OpenLootBox()
  if me.EO_ToggleLootBox = None
      lootBox as NodeRef of Class  GUIControl = CreateNodeFromPrototype("EO_LootBox")
      lootBox.build = true
      me.EO_ToggleLootBox = lootBox
    else
      DestroyNode(me.EO_ToggleLootBox)
      me.EO_ToggleLootBox = None
   
    //tooltip destroy is is still there
    abilityTooltip as NodeRef of Class GUIControl
    abilityTooltip = FindGUIControlByName(0,"EO_InvTooltip")
    if abilityTooltip != None
      DestroyNode(abilityTooltip)
    .
  .
.

9
Its a shared function from the _InputClassMethods I assumed in needed to stay a function to be used properly. I'm not 100% yet on how HSL handles ownership and use of shared/public functions versus other languages. Ill try doing it that way to see what happens. I had already tried calling the method without me and it says there is no method by that name. Ill try writing a separate script and calling via the other method if none of the above works out.

Thank you

10
Just as a side note, I am trying to click an object that I MNAC this class to and open a GUI.

11
Exactly what it says, I am calling the mouse event function in my LootGUIClassMethods script like so:

Code: [Select]
shared function InputMouseEvent(args references Class _MouseEvent)
// Mouse event generated from the _InputHandlerClassMethods Script assuming it
//   has not been overridden by a game specific implementation.
//
 
  // Get the Node For which the Event was Generated
  target as NodeRef = args.MouseTarget
 
  // Type Cast the node so we can access its fields/properties
  where target is kindof HBNode
    when args.MouseEventType
      is Click
          me.OpenLootGUI()
      .
    .
  .
.

method OpenLootGUI
    //Do Stuff
.

However it says that me.OpenLootGUI() doesnt exsist which I can only assume is because its taking me as the _inputClassMethods script and not the LootGUIClassMethods script.

So my question is am I misunderstanding whats happening or can you not call methods from the same script in a shared function?

12
Its good to see that people still sculpt terrains in the engine, I was reliant on a world generator for awhile until I got into the freedom of sculpting a terrain from scratch. Which is easy in HeroEngine in particular with the filtering tools and overall terrain/environment system.

13
Scripting & Programming / Re: Inventory Stuff
« on: Mar 08, 12, 08:26:21 PM »
that would be really great if you could do that! thanks man :-)

Agreed! I have been tearing through whats in HJRef however I have not learned a whole lot, the systems are so complex the only thing I am having trouble understanding is the Spec Decorators I have a spec oracle system created, the other thing is the editors, specifically the HJNPC editor that has all the expanded options, I am pretty sure that is a custom coded UI but I have not found it yet.

14
Scripting & Programming / Re: NPC Data (System)
« on: Mar 07, 12, 12:26:43 PM »
Thank you so much Trigger, I did not thing to check glomming to see what classes they are using to work with the main engine classes. That helps out a lot in determining what classes to look at for examples and I never noticed the parent classes in combatant class, I had just been looking at the HJNpc classes.

Im going to attempt to get something working today hopefully with success.

15
Scripting & Programming / [Resolved] NPC Data (System)
« on: Mar 05, 12, 03:53:50 PM »
I have been looking everywhere including the HJRef but I can not find anywhere that the NPC data such as Health and Abilities are defined. I know the NPC's are created as SpecOracles and I have already gotten that part but I have no Idea where to start in order to get NPC data created. It would help to know how to change the health and mana of the monkeytok, its a good test mob, or even a dynamic character I spawn from HENPC. I have read through all of the NPC tutorials but no where does it make mention of changing health and other characteristics about characters besides cosmetic changes.

Here is the problem I have, I have created a stats system that uses stats like Strength and Vitality to adjust HP and Mana, this system is perfectly working for the commoncharacter. However the monkeytoks no have no life as they are derived from the commoncharacter class.....some how.

In the Screenshots I took damage because of the heal spell, thats a bug I will work out later. I kill the monkeytok in 1 hit because it has 0 life, it has 0 life because I can not set the Vitality stat for the mob or any npc I create for that matter because it is not stated anywhere how that is accomplished. I have been working on this all day with no results or even clues on how this is done.

Let me know if you guys know anything about this, I couldnt find anything related specifically to this on the forums anywhere.

Thanks!

Pages: [1] 2