RP and RepeatPan's mods

[01/07/14 19:55:34] [JS] ERROR: http://radiant/rp_silence/silence.js:14: Uncaught TypeError: Object # Object> has no method ‘set_call_proxy’

[01/07/14 19:59:07] [JS] ERROR: http://radiant/stonehearth/ui/game/create_camp/create_camp.js:128: Uncaught TypeError: undefined is not a function

Yupp, you’re using an invalid combination of RP and Silence. The Silence version (from the github zip) is updated, your RP likely isn’t. Try downloading r1400 - that should fix the error and remove the music in-game.

I’ll release a new set of .smods on GitHub as we speak.

Well, I guess this is as good as anything re: how to “add” factions right now.

Alternate Naming

Introduces a new naming generator. Instead of having a fixed list of first/last names, this uses snippets to generate the name. This means that some might get a really borked name, while others get an amusing name!

As part of the implementation I’ve added a possibility to give word parts a likeliness to appear. In the example faction provided, things like “Duke”, “Duchess” or “, Dark Lord of All” might appear.

Names include highlights such as

Illoving Northloch, Campton Edwell, Viina Winwine, Brometh Gwarin, Count Sean Northwine, Irton Edrider, Irper Baall, Garving Burlywell, Chopper Brightessa, Bromff Winloch, and last but not least Senen Freyin, Dark Lord of All.

For developers: How to mess around with factions (again, this is a quite popular topic I believe). It’s creating a different sort of name generator and (for now) re-directs all calls to the normal ascendancy faction to our new ascendies.

Long live the king!

The maintainer for the included names list is @phoriist, have his statement below:

2 Likes

while you continue to delight and amaze (truly!), i’m seeing a disturbing lack of names that include either Steve, Geoffers… or, more importantly, Steffers Geodamo…

you have been notified…

1 Like

I am working at expanded Ascendancy namelist for this mod and those names WILL be possible to get :wink:

1 Like

we all know that flattery will get you everywhere, and what is inevitably coming next… right?

+2 internet points to you, good sir!

I’ve heard the next version of rp_alternate_naming could contain checks that explicitly avoid names such as “Steve”, “Geoffers” or “Steffers Geodamo”. It’s just a rumour, of course, and I believe that this could be avoided if I suddenly found 20’000 internet points on my Swiss bank account.

3 Likes

I used your summon workers mod and attached it to an entity. You place it and there is a button similar to the flagpole.
Now my question is, is it possible to make it a 1 time event? So if you use the button to summon a worker then the object (bread in my case) dissapears.
Would love to see this. I tried to google some stuff about that, but my coding knowledge is non-existant and could not make anything out of it.

Should be possible. Assuming you have a reference to the entity (usually, commands have three parameters: session, request, self, of which self is the entity that the command was clicked on), you should be able to use self:get_component('stonehearth:commands'):remove_command('command_name_here'), where command_name_here is the command name defined in the command json (in my case, it would be spawn_stuff or summon_worker).

I’ve never tested it, but the code is there so theoretically it should be doable.

Edit: Woops, misread. This removes the command, not the entity. You could try radiant.terrain.remove_entity(self).

thanks, I will try. :blush:

edit:
I found the destroy entity command:

{
   "type" : "command",

   "name": "destroy_entity",
   "tooltip": "Remove forever!",
   "icon": "file(destroy_entity.png)",

   "action": "call",
   "function": "stonehearth:destroy_entity",
   "args": [
      "{{self}}"
   ]
}

And in manifest:

"destroy_entity": {
        "controller" : "file(call_handlers/entities_call_handler.lua)",
        "endpoint" : "server"
     },

No idea ho to trigger it automatically.

function EntityCallHandler:destroy_entity(session, response, entity)
  assert(entity)
  radiant.entities.destroy_entity(entity)
  return true
end
return EntityCallHandler

You want to modify the callback that I’m using to something like

function MyBreadHandlerStuff:eat_bread(session, response, self)	
  radiant.entities.destroy_entity(self)
end

I tried several things but cant get it to work. I thank you for your effort. I just keep myself at the basic stuff untill I know more of the coding stuff. And actually understand what I am doing.

1 Like

That’s useful too… :wink:

yea, I thought it would not be that hard. Since objects get created and destroyed a lot in the game.
Maybe it is not that hard. I just dont know what to add where. :blush:

Time Is Money (Friend)

I’m certainly going to enjoy any possible mod spotlight for this. It is true that I have conquered the depths of JavaScript to discover that Ember isn’t that bad actually. Kind of wish that Radiant would mixin ViewActionTargetSupport into their views (I suppose this isn’t worthy of a bug report/request right now) but otherwise it works nicely.

What it does: Take a good look at the menu screen and the in game tutorial - because it’s the last time you’ll see it. This mod simply skips through the main menu straight into the world generation and from there auto-selects the banner and the stockpile. You’ll never have to click that pesky banner again. You’ll never see it hopping either. That third screen which said something about a workbench is gone too. This mod has been designed for modders, again, or people that have done this kind of stuff way too often to care.

For developers: How to mess around with Ember, more specifically how to patch SH’s views.


Wherever you spawn the worker, you want to destroy the entity.

1 Like

well, as is typical, i’m “doing it wrong”… i cant quite seem to get this to work for me… i’ve loaded the “spawn” items file into the correct folder (along with your rp.smod), and yet nothing happens when i interact with the waypoint…

perhaps im running a previously altered stonehearth.smod file… hmm…

Logs or it didn’t happen.

hahaha… very well, when i return this evening, i’ll make a concentrated effort at this again… promise! :smile:

I’ve been very verbose with RP (and partially my mods), so if there’s something not working, chances are that either stonehearth.log or stonehearth_mod_server.log will tell us what (and why). Theoretically, it should work with modified stonehearth.smods, as long as they keep about the same structure (i.e. are merely replacements or small changes).

Sheesh, I wonder what this commit does. Especially when one would, say, have this kind of JS.

rp.add_to_start_menu(
	[
		{
			name : "Bleigh",
			hotkey: "g",
			icon: "/stonehearth/ui/game/start_menu/images/chop_trees.png",
			
			elements :
			[
				{
					name : "Chop 1",
					hotkey : "1",
					icon : "/stonehearth/ui/game/start_menu/images/chop_trees.png",
					click: function() { rp.log("chop 1 lololo"); }
				},
				
				{
					name : "Chop 2",
					hotkey: "2",
					icon: "/stonehearth/ui/game/start_menu/images/chop_trees.png",
					click: function() { rp.log("chop 2 lolo"); }
				},
				
				{
					name : "Empty Chop. :(",
					hotkey: "3",
					click: function() { rp.log("chop 3 heheh"); }
				}
			]
		},
		{
			name: "Build",
			elements : [
				{
					name : "Hellou!",
					hotkey: "h",
					click: function() { rp.log("hellou!"); }
				}
			],
		}
	]
);

I can’t imagine.

(ping @sdee: inofficially, it is now!)

1 Like